This is a migrated thread and some comments may be shown as answers.

Behavior? : Several Tables at One Level

3 Answers 61 Views
Grid
This is a migrated thread and some comments may be shown as answers.
MarkInTexas
Top achievements
Rank 1
MarkInTexas asked on 11 Jul 2008, 11:04 PM
In regards to this article : http://www.telerik.com/help/aspnet/grid/grdseveraltablesatlevel.html

I could not get 2 details grids to be at the same level and to be vertically aligned, first details grid, second details grid.

I am wondering by setting HorizontalAlign to Right or Left in the first details grid causes the second details grid to be Horizontally Aligned with the first Details grid.

This behavior does not seem right to me but is the expected behavior? Seems like setting this value should not effect any subsequent details grids at the same level.

Thanks,
Mark.

3 Answers, 1 is accepted

Sort by
0
Princy
Top achievements
Rank 2
answered on 14 Jul 2008, 05:12 AM
Hi Mark,

Have you gone through the following help article?
Aligning columns in each level of hierarchical grid

Thanks
Princy.
0
MarkInTexas
Top achievements
Rank 1
answered on 14 Jul 2008, 01:15 PM
Princy,
Thanks for the reply. Yes. I have read everything I could find related to DetailViews.

Let me try to explain the issue better.

Here is what I would like to achieve, 1 Master Table with 2 Detail Views at the same level just like the example linked in my first post.

MasterTableView
    DetailView1
    DetailView2

If I use the HorizontalAlignment Property and set it to Left or Right then I end up with this:

MasterTableView
    DetailView1DetailView2

**Notice how DetailView2 appears immediately right after DetailView1 ?

I was able to resolve this issue by using HorizontalAlign=Justify.

My question is: Is this expected behavior when using the HorizontalAlign="Right" or "Left" in the details viiew? Should the SECOND DetailView appear immediately after the FIRST Details View. I would think that HorizontalAlign would align the DetailsView Grid LEFT or RIGHT but not effect the next DetailsView at the same level.

<MasterTableView DataSourceID="AccessDataSource1" DataKeyNames="CustomerID, ProductID"  
                   Width="100%" HorizontalAlign="Right"
    <DetailTables> 
            <rad:GridTableView DataKeyNames="OrderID" runat="server" HorizontalAlign="Right"
        ... 
        </rad:GridTableView> 
            <rad:GridTableView DataKeyNames="ProductID" runat="server" HorizontalAlign="Right"
        ... 
        </rad:GridTableView> 
                     
    </DetailTables> 
</MasterTableView> 
 


Does that make more sense?

0
Shinu
Top achievements
Rank 2
answered on 15 Jul 2008, 11:41 AM
Hi,

Can you try with the following approach and see whether it is working?

ASPX:
<DetailTables > 
       <telerik:GridTableView DataSourceID="SqlDataSource3" CssClass="Class1"  > 
       <Columns> 
       <telerik:GridBoundColumn DataField="Project_ID" ></telerik:GridBoundColumn> 
       <telerik:GridBoundColumn DataField="Project_Name"></telerik:GridBoundColumn> 
       </Columns> 
       </telerik:GridTableView> 
        
 <telerik:GridTableView DataSourceID="SqlDataSource3"  CssClass="Class1" >        
     <Columns> 
     <telerik:GridBoundColumn DataField="NoOfMembers"></telerik:GridBoundColumn> 
     <telerik:GridBoundColumn DataField="Description"></telerik:GridBoundColumn> 
     </Columns> 
       </telerik:GridTableView> 

 
 <style type="text/css"
     .Class1 
    {   
        margin-left: 200px !important; 
    } 
    </style> 
 


Thanks
Shinu.
Tags
Grid
Asked by
MarkInTexas
Top achievements
Rank 1
Answers by
Princy
Top achievements
Rank 2
MarkInTexas
Top achievements
Rank 1
Shinu
Top achievements
Rank 2
Share this question
or