Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
237 views
I have a radgrid using the automatic operations (insert/update/delete).  I have two columns in the grid called "ModifiedBy" and "DateCreated" When in edit mode and after the update button is clicked, I need to update the values of those columns for the selected item with the current logged in user and current date.  I know how to get the logged in user and date but I'm not clear on how to  bind that data back to the database.

How can this be done in the code-behind using vb.net?  I've tried to use e.Item.OwnerTableView.PerformUpdate() but I'm not sure how to do it.  Is there a better way to accomplish this?  Any help would be greatly appreciated.

 

Ryan Eaves
Top achievements
Rank 1
 answered on 17 Feb 2011
8 answers
915 views

I have a form with 3 text boxes.  Under this is a RadGrid that is dynamically created, each row represents an entity(ie. User) and each column represents a Permission (Create, Edit, Read, Delete).  Each cell is populated with a user control that tracks the permission setting for each item in the matrix (User:Create =  value1, User:Edit = value2, User:Read = value3, User:Delete = value4)

The entire grid forms part of the edit form, so every row of the grid is in "edit" mode all the time, but I am not using the EditMode of RadGrid.  Rows are not edited/saved individually.  The user may load the matrix, change values in row 1, column 2, row 3 column 4, etc.  and then click the save button.

How can I on postback loop through rows and columns and extract the new values for the matrix?


            foreach (GridDataItem gridRow in this.uxRadGridEntityPermissions.MasterTableView.Items)
            {
TableCell cell = gridRow["permissionColumnName1"]; // returns the cell
TableCell cell = gridRow["permissionColumnName2"]; // returns the cell
TableCell cell = gridRow["permissionColumnName3"]; // throws exception - index out of range
TableCell cell = gridRow["permissionColumnName4"]; // throws exception - index out of range

TableCell cell = gridRow["permissionColumnName1"]; // returns the cell




TableCell cell = gridRow["permissionColumnName1"]; // returns the cell
}

The above code works in the Init event (all cells can be retrieved) but in the button Click event, only the first 2 cells can be retrieved?
Chris @ Intrinsic
Top achievements
Rank 1
 answered on 17 Feb 2011
0 answers
122 views
hello

    i have created a nodetemplate for a comments system. (this is part of my code)
    my problem is that the text inside the div or in any element is not acting regulary like when its
    not in a nodetemplate.
    the text inside the div is not selectable, i cant select text in it and like copy or somthing like that.
    why its acting like that?
    <telerik:RadTreeView runat="server" ID="RadTreeView1" Skin="Vista">    
        <NodeTemplate>        
        <div style="width:400px;" dir="rtl">
            <div id="CommentTopSection" runat="server" style="cursor: pointer; font-size: 12px; width:100%;
                color: Black; font-family: Arial; text-align: right;">
                  
                <asp:Label ID="lbl_CommentID" runat="server" Text='<%# Eval("CommentID") %>' Visible="False"></asp:Label>
                <asp:Label ID="lbl_CommentNumer" runat="server" Text='<%# Eval("CommentIncerment") %>'></asp:Label>
                <asp:Label ID="lbl_CommentTitle" runat="server" Text='<%# Eval("CommentTitle") %>'></asp:Label>
                <br />
                  
                <span style="font-size: 12px; color: Gray; font-family: arial;"><%# Eval("Name") %> , <%# Eval("CommentDate") %>
                </span>
            </div>
            <div id="CommentExpand" runat="server"
                 style="padding-bottom:5px; font-family:Arial; font-size:12px; color:Black; text-align:right; visibility: hidden; height: 0px; width: 400px; border: 1px 1px 0px 1px solid #C0C0C0; background-color: #F1F5FA">
                <br />
                  
                <%# Eval("CommentContent") %>
                      
                <br /> <br />
                  
                <span id="span_AddNewComment" runat="server" style="padding-left:10px; cursor:pointer; font-family:Arial; font-size:12px; font-weight:bold; text-decoration:underline; color:Black;"> ????? ???? </span>      
                <span id="span_AddParentComment" runat="server" style="cursor:pointer;  font-family:Arial; font-size:12px; font-weight:bold; text-decoration:underline; color:Black;"> ????? ?????? </span>                
        </NodeTemplate>
        <DataBindings>
            <telerik:RadTreeNodeBinding Expanded="True" />
        </DataBindings>
    </telerik:RadTreeView>

 

 

 

 

 

 

 

 

 

roy
Top achievements
Rank 1
 asked on 16 Feb 2011
2 answers
138 views
I have a CommandItemTemplate contain RadToolBar which also contain RadComboBox, what i need to do here is to dynamically set value for the RadComboBox when page is loaded and in button click event. This is the code I have in Page_Load/Button_Click event:  
GridItem commandItem = RadGrid1.MasterTableView.GetItems(GridItemType.CommandItem)[0];
                RadToolBar radtoolbar = (RadToolBar)commandItem.FindControl("RadToolBar1");
                RadToolBarItem comboitem = radtoolbar.FindItemByText("RadToolBarButton1");
                RadComboBox rcb = (RadComboBox)comboitem.FindControl("RadComboBox1");
 I kept getting "Index was outside the bounds of the array" but I have only one Item (RadToolBar) in CommandItemTemplate. I saw samples that do it in ItemCreate event, but I need my control to interact with button click, how can I do it?

Thanks  in advance!

Shannon
Shannnon
Top achievements
Rank 1
 answered on 16 Feb 2011
0 answers
70 views
Hi guys,
I have a tabstrip and a multipage and want to be able to have individual tabs clicked which show their individual relevant pages. Then, if you click on a single page tab, it shows only that one page.But when I go to design view it shows me all pages no matter what tab I am clicking.

<

 

div id="TabForms">

 

 

<telerik:RadTabStrip ID="RadTabStrip1" runat="server" MultiPageID="RadMultiPage1" SelectedIndex="0" EnableEmbeddedSkins="False">

 

 

<Tabs>

 

 

<telerik:RadTab Text="Header Info">

 

 

</telerik:RadTab>

 

 

<telerik:RadTab Text="Section - 1" >

 

 

</telerik:RadTab>

 

 

<telerik:RadTab Text="Section - 2 &amp; 3" >

 

 

</telerik:RadTab>

 

 

 

<telerik:RadTab Text="Section - 4">

 

 

</telerik:RadTab>

 

 

 

</Tabs>

 

 

</telerik:RadTabStrip>

 

 

<telerik:RadMultiPage ID="RadMultiPage1" runat="server" SelectedIndex="0" >

 

 

<telerik:RadPageView ID="RadPageView1" runat="server">

 

Thanks so much for help.

Vasya Ivanov
Top achievements
Rank 1
 asked on 16 Feb 2011
2 answers
197 views
I have an inline edit form and everything is working great except I need to have it with more than one column ( like in the demo ). I have attached a screen shot of what I want to do. I have tried setting ColumnNumber to 2 but that has not worked.

Thanks!
Clark
Top achievements
Rank 1
 answered on 16 Feb 2011
2 answers
205 views
Hello,

I'm trying to setup a modal window to display a form, then after completing the form I need to update a control on the current page from the data that was added to database.

Here's the code I'm using:

 

<telerik:RadComboBox ID="cboIndustrie" ToolTip="Industrie d'appartenance de l'entreprise." Width="200" AllowCustomText="false" runat="server"
</telerik:RadComboBox
  
<asp:LinkButton Text="[Ajouter une industrie]" runat="server" CausesValidation="false" ID="lnkIndustrie"
OnClientClick="window.radopen(null, 'windowIndustrie'); return false;" OnClick="lnkIndustrie_Click"></asp:LinkButton
  
<telerik:RadWindowManager ID="windowManager" runat="server"
<Windows
<telerik:RadWindow ID="windowIndustrie" Title="Nouvelle industrie" ShowContentDuringLoad="false" 
Width="400px" Height="200px" Behaviors="Default" runat="server" EnableShadow="true" Modal="true" 
NavigateUrl="AddIndustrie.aspx" VisibleStatusbar="false" /> 
</Windows
</telerik:RadWindowManager
  
<telerik:RadAjaxManager ID="ajaxManager" runat="server"
<AjaxSettings
<telerik:AjaxSetting AjaxControlID="lnkIndustrie"
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="cboIndustrie" /> 
</UpdatedControls
</telerik:AjaxSetting
</AjaxSettings
</telerik:RadAjaxManager

 

The general execution process is working fine, but if I remove "return false;" after calling window.radopen() the page will reload while users are filling my form. So, I need to find a way to hold execution while windowIndustrie is open.

As a work around, I tried to add an invisible button that would be fired with OnClientClose event of my window, but I can't get it working...

Thanks,
Frédéric
AXOR
Top achievements
Rank 1
 answered on 16 Feb 2011
6 answers
177 views
Using Telerik RADControls for ASP.NET AJAX Q2 2010 SP2.

1) Inputting an integer larger than 70 billion in any filter expression (roughly, hold down any number key for a few seconds, you will see).  This can be reproduced on the live demo here: http://demos.telerik.com/aspnet-ajax/filter/examples/firstlook/defaultcs.aspx  The demo page redirects to a page not found, but in a VS project in debug mode, it will return a javascript error where it basically says "Value too large for System.Int32".  Is there a solution for this via javascript or C#?  Basically cap the number of digits user can enter for an integer type filter expression.

2) I need to remove the following items from a filter expression: "NotEqualTo", "GreaterThan", "LessThan", "GreaterThanOrEqualTo", "LessThanOrEqualTo", "Between" and "NotBetween" but ONLY for string columns, these are still needed for integer columns.
Brett
Top achievements
Rank 1
 answered on 16 Feb 2011
3 answers
131 views
I have a very nice multi-select radcombobox solution that uses a RadListBox inside of the first RadComboBoxItem's ItemTemplate that allows for keyboard support and extra properties to return the values of the selected.  There is also a footer template that is added in non-production environments to show the developer/tester the values of the checked items.

However, the testers have noticed that when the server control is right above the status bar like in the attached "scrunched.png" the control only expands up the height of one row when the dropdown is clicked on.  If you close the dropdown and expand it upwards again it expands to full height, like in the attached "justright.png"...

This is only for IE7/IE8.  Firefox 3.6.3 and Chrome 8.0.552 work fine.  Well, I say they work fine only because they don't care about screen boundaries so those browsers expand the dropdown, um, downwards, not upwards like IE "tries" to do...  Not the optimal situation for UI friendliness, but at least they don't create more problems by trying to be "friendly".

Any suggestions?
Thanks!!
Thad
Top achievements
Rank 2
 answered on 16 Feb 2011
1 answer
118 views
Hi,
Is it possible to put an image instead of Axislabel in radchart ?
Thank you very much...
Evgenia
Telerik team
 answered on 16 Feb 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?