Telerik Forums
UI for ASP.NET AJAX Forum
9 answers
198 views
Hello, I'm using the newest version of RadControls for ASP.NET, and I've got a problem with launching the edit mode for RadGrid - it works like a charm for one instance of RadGrid, but for another - which is hierarchical - it doesn't. I am able to set edit mode manually - by EditColumn only.

My hierarchical grid looks is created in following way:

<telerik:RadGrid runat="server"
    ID="Grid"
    EnableAJAX="True"
    AllowMultiRowEdit = "True"
    EditMode="InPlace"
    OnItemDataBound="Grid_ItemDataBound"
    OnDetailTableDataBind="Grid_DetailTableDataBind"
    OnPreRender="Grid_PreRender"
    OnUpdateCommand="Grid_ItemUpdate"
    OnItemCreated="Grid_ItemCreated"
    DataSourceID="SqlDataSource1"
    AutoGenerateColumns="false">
      
    <MasterTableView DataKeyNames="MASTER_ID" >
     
     <DetailTables>
                            <telerik:GridTableView                           
                             EditMode="InPlace"
                            Name="Child" AutoGenerateColumns="False" Width="100%"
                              DataKeyNames="CHILD_ID" runat="server">
 
                                <Columns>                                  
                                 <telerik:GridEditCommandColumn /> 
                                   
                                <telerik:GridBoundColumn  DataField="CHILD_ID" HeaderText="CHILD_ID" ReadOnly="True"
                   SortExpression="CHILD_ID" UniqueName="CHILD_ID">
                                </telerik:GridBoundColumn>       
                                 
                                    
                                <telerik:GridBoundColumn  DataField="CHILD_Text" HeaderText="CHILD_Text" ReadOnly="False"
                   SortExpression="CHILD_Text" UniqueName="CHILD_Text">
                                </telerik:GridBoundColumn>                        
 
                   
                                </Columns>
                                </telerik:GridTableView>
                                 
    </DetailTables>                          
     
    <Columns>   
 
    <telerik:GridBoundColumn  DataField="CHILD_ID" HeaderText="CHILD_ID" ReadOnly="True"
                   SortExpression="CHILD_ID" UniqueName="CHILD_ID">
                                </telerik:GridBoundColumn>
                                 
    <telerik:GridBoundColumn  DataField="MASTER_ID" HeaderText="MASTER_ID" ReadOnly="True"
                   SortExpression="MASTER_ID" UniqueName="MASTER_ID">
                                </telerik:GridBoundColumn>     
                
                           
    </Columns>   
     
    </MasterTableView>
    
    </telerik:RadGrid>

And function, which is trying to turn on edit mode, looks like:

private void Grid_PreRender(object sender, System.EventArgs e)
{
 
if (!IsPostBack)
{
 
 foreach(GridItem item in Grid.MasterTableView.Items)
 {
  if (item is GridEditableItem)
  {
   GridEditableItem editableItem= item as GridDataItem;
   editableItem.Edit = true;
  }
 }
 Grid.Rebind();
}
 
}

Any help would be appreciated.
Daniel
Top achievements
Rank 2
 answered on 13 Jun 2011
2 answers
133 views
I have a template column in a RadGrid that has a RadMaskedTextBox in it.

When the user selects a row, the entire row is changed color except for these RadMaskedTextBoxes.

I want to change their background color to red when the user selects the row.

I trigger an event to do this with the following in the ClientSettings section of the RadGrid HTML.

 

<ClientEvents OnRowSelected="OnRowSelected" />

The javascript event handler is:

function OnRowSelected(sender, eventArgs) {
    var MasterTable;
    var aryAllRows;
    var rowOneRow;
    var txtItemUPC;
    MasterTable = sender.get_masterTableView();
    aryAllRows = MasterTable.get_dataItems();
    rowOneRow = aryAllRows[eventArgs.get_itemIndexHierarchical()];
    txtItemUPC = rowOneRow.findControl('txtItemUPC');
    txtItemUPC.get_styles().EnabledStyle[0] += "background-color: Red";
}

I can check txtItemUPC.get_value() to see that txtItemUPC is correctly set to the RadMaskedTextBox.

The value of txtItemUPC.get_styles().EnabledStyle[0] is changed by the above code.  However, the RadMaskedTextBox doesn't display any differently.

As a test, I set txtItemUPC.get_styles().EnabledStyle[0] to a garbage value and not receive any error messages.

Can you point out what I am doing wrong?  Note that there is no set_styles option, I believe.

John
Top achievements
Rank 1
 answered on 13 Jun 2011
3 answers
132 views
Hi,
Im new to asp.net and I am struggling on how to access the Advanced Form save event to send an email after every new appointment.  Any examples on how to accomplish this would be great.  I would also like to grab the values from the advanced form and include them in the email.

Thank you,
Gus
Gus
Top achievements
Rank 1
 answered on 13 Jun 2011
4 answers
226 views
I am partially populating a large tree and enabling load on demand and tri-state checkboxes.  At the time of partial population of the tree, I know which load-on-demand nodes have checked children, but I can find no way to communicate this to the tree object.  Node.CheckedState is read-only.  If I can't do this, checkboxes are potentially inaccurate until the entire tree has been expanded, which eliminates the value of load-on-demand.

Am I missing something?  Is there a work-around for this?  If not, please consider adding this capability in a future release.
Nikolay Tsenkov
Telerik team
 answered on 13 Jun 2011
3 answers
98 views
I have a user control inside a grid for editing. Everything works as expected except one thing.

I have an "Update" event on a toolbar in the control. The event checks the database for duplicate data. iIf another record exists it cancels the update. I'd like to leave the control open but the "Update" event goes up to the grid and it closes.

In classic RadControls you could do
e.cancel(true);
on the toolbar event.... is there a simple way to accomplish the same effect?
Peter
Telerik team
 answered on 13 Jun 2011
2 answers
88 views
I have a two docks in a horizontal zone.

When Dock_1 undocks I force Dock_0 to resize to 100% of the width of the zone.  
This restricts the floating dock from resizing larger.  Is this by design? 

One workaround is to size Dock_0 narrower and than the floating Dock_1 can be resized larger. 

Is there a proper technique to allow my floating dock to resize at will while Dock_0 occupies 100% of the zone?


Joel
Top achievements
Rank 1
 answered on 13 Jun 2011
1 answer
250 views
Hi ,
I am Facing One issue in My Rad grid, In that First  i ll will click the add button it show the fields in add mode and Edit button i shows the edit fiedls in edit mode but add form fields is not beging hided , Vice versa also.
If click add i want to show only add form field else if click edit button edit fields only i have to show.
Can any one tel how to hide and show the add / edit Mode..
Jayesh Goyani
Top achievements
Rank 2
 answered on 13 Jun 2011
12 answers
248 views
Hi
How do you display multiple appointments, in the same timeslot, side by side in the timeline view.  I want to display the appointments following each other in the time slot with the widths set appropriatley based on start/end time within the time slot (not set at 100% of the timeslot or at a default width)
Thanks

Peter
Telerik team
 answered on 13 Jun 2011
3 answers
405 views
Hi guy,

I have a good question for you. I have a main window (win0) that call a window (wind1) that call another window (win2). In the win2, I have a grid and I call another window (win0_1), but this window was declared in the radWindowManager of the win0. My problem is that when I close my win0_1, I want to make a Rebind on the grid on the win2, but I don't know how to do this. In fact, I'm using dataSet for the grid and when I closed the win0_1, data are add to the dataSet of the grid, so I just have to refresh my grid and the data will appears. I think about calling a javaScript function that is in the win2, but how to access to the radWindow of a child of a child of a window ?. 
Thank you,

David Lefaivre-Boucher
David
Top achievements
Rank 1
 answered on 13 Jun 2011
3 answers
66 views
Hi Everyone,

I followed the following example and did a module at my work.I was able to do everything very well.I have no clue it suddenly gave me an error saying that There is an error in the innertext of the HTML.

http://demos.telerik.com/aspnet-ajax/ajax/examples/manager/dynamicajaxsettings/defaultcs.aspx?product=grid
I checked every tag ....
Nothing is working
When I click on add new employee link button in the above eg it is not showing the divexternalform.
Any one have any idea y the INNER TEXT Error comes up.

Please help me.

I tried to change the div tag to asp:Panel tag still it is doing nothin but refereshing the page.



Thanks,
Sravanthi



sravanthi
Top achievements
Rank 1
 answered on 13 Jun 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?