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

Important breaking changes in Q3.09 needing help to migrate

2 Answers 78 Views
Dock
This is a migrated thread and some comments may be shown as answers.
CSurieux
Top achievements
Rank 2
CSurieux asked on 06 Nov 2009, 10:47 AM
Hello,

My code running since long time through various version is totally broken by Q3.2009 version.

Main problem is an exception in RadWebControl.LoadPostData: Invalid Json primitive.
Something has been changed in the way RadDock save its data, i am using a code common from forum to save the Dock position, something like this:

/// Called by DockLayout just after Init  
        protected void RadDockLayout1_LoadDockLayout(object sender, DockLayoutEventArgs e)  
        {           foreach (DockState state in CurrentDockStates)  
            {  
                                e.Positions[state.UniqueName]   =   state.DockZoneID;  
                e.Indices[state.UniqueName]     =   state.Index;  
            }  

and

/// Called by DockLayout just after PreRender  
        protected void RadDockLayout1_SaveDockLayout(object sender, DockLayoutEventArgs e)  
        {  
            //Save the dock state in the session. This will enable us   
            // to recreate the dock in the next Page_Init.   
            List<DockState> lst     =   RadDockLayout1.GetRegisteredDocksState();  
            CurrentDockStates       = lst;  
        } 

Second problem is that the grid I was installing in a dock to take its full width seems now greater that the available space and it generate scrollers ! Very ugly !!!

The code which was working without scrollers

<telerik:RadDockLayout runat="server" ID="RadDockLayout1">  
<telerik:RadDock ID="GridDock" Title="SELECTED" Top="150px" Left="70%"   
    style=" margin-left:auto; margin-right:auto; min-width:305px;min-height:200px;" DefaultCommands='PinUnpin' Pinned="false" DockMode="Floating" 
        runat="server" > 
        <Commands> 
        <telerik:DockPinUnpinCommand  AutoPostBack="true" /> 
        </Commands> 
        <ContentTemplate> 
        <telerik:RadGrid ID="RadGrid2" runat="server" GridLines="None" AutoGenerateColumns="False" style=" border-left-width:0; border-right-width:0; border-top-width:0; border-bottom-width:1; border-bottom-style: solid; width:303px;min-height:200px;" > 
        <MasterTableView> 
            <ExpandCollapseColumn Visible="False" Resizable="False">  
                <HeaderStyle Width="20px" /> 
            </ExpandCollapseColumn> 
            <RowIndicatorColumn Visible="False">  
                <HeaderStyle Width="20px" /> 
            </RowIndicatorColumn> 
            <Columns> 
                <telerik:GridBoundColumn DataField="Name" HeaderText="NAME" 
                    ItemStyle-Width='200px' UniqueName="Name">  
                </telerik:GridBoundColumn> 
                <telerik:GridBoundColumn DataField="Parameter" HeaderText="PARAMETER" 
                    ItemStyle-Width='200px' UniqueName="Parameter">  
                </telerik:GridBoundColumn> 
            </Columns> 
        </MasterTableView> 
        </telerik:RadGrid> 
        </ContentTemplate> 
    </telerik:RadDock>   
</telerik:RadDockLayout> 
 


Thanks for urgent help.

CS

2 Answers, 1 is accepted

Sort by
0
CSurieux
Top achievements
Rank 2
answered on 06 Nov 2009, 11:35 AM
More...

When collapsed the RadDock now show a funny bottom border made of a serie of helf-circles and under this I get something strange certainly part of the radgrid header but with vertical separators...
Theme Vista, Web20 I have no more tested but seems general.
funny but broken a lot.

CS
0
Petio Petkov
Telerik team
answered on 06 Nov 2009, 04:10 PM
Hi Christian,

With the 2009/Q3 release we introduced a new rendering of RadDock for ASP.NET AJAX control. To remove the scroll bar which appears you should set a bigger min-width to the RadDock control, e.g.
<telerik:RadDockLayout runat="server" ID="RadDockLayout1">
          <telerik:RadDock ID="GridDock" Title="SELECTED" Top="150px" Left="70%" 
          Style="margin-left: auto;
              margin-right: auto; min-width: 320px; min-height: 200px;" DefaultCommands='PinUnpin'
              Pinned="false" DockMode="Floating" runat="server">
              <Commands>
                  <telerik:DockPinUnpinCommand AutoPostBack="true" />
              </Commands>
              <ContentTemplate>
                  <telerik:RadGrid ID="RadGrid2" runat="server" GridLines="None" AutoGenerateColumns="False"
                      Style="border-left-width: 0; 
                      border-right-width: 0;
                      border-top-width: 0; border-bottom-width: 1;
                      border-bottom-style: solid; width: 303px; min-height: 200px;">
                      <MasterTableView>
                          <ExpandCollapseColumn Visible="False" Resizable="False">
                              <HeaderStyle Width="20px" />
                          </ExpandCollapseColumn>
                          <RowIndicatorColumn Visible="False">
                              <HeaderStyle Width="20px" />
                          </RowIndicatorColumn>
                          <Columns>
                              <telerik:GridBoundColumn DataField="Name" HeaderText="NAME" ItemStyle-Width='200px'
                                  UniqueName="Name">
                              </telerik:GridBoundColumn>
                              <telerik:GridBoundColumn DataField="Parameter" HeaderText="PARAMETER" ItemStyle-Width='200px'
                                  UniqueName="Parameter">
                              </telerik:GridBoundColumn>
                          </Columns>
                      </MasterTableView>
                  </telerik:RadGrid>
              </ContentTemplate>
          </telerik:RadDock>
      </telerik:RadDockLayout>
Please open a new support thread and send us a project where we can observe the  problem with the "invalid JSON primitive". Once we receive it, we will do our best to help you.

All the best,
Petio Petkov
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
Dock
Asked by
CSurieux
Top achievements
Rank 2
Answers by
CSurieux
Top achievements
Rank 2
Petio Petkov
Telerik team
Share this question
or