Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
192 views
Our FileExplorer looks for a folder called /uploaded-files/. Is there a way to auto-create this folder if it doesn't exist?
Chris Miller
Top achievements
Rank 1
 answered on 05 Apr 2010
2 answers
245 views
Hello,

I have a RadComboBox with a multi-checkbox setup. It is working fine but when try loop through the items and see if anything has been selected it is showing FALSE even when I have definitely selected some items.

My code is as follows:

foreach (RadComboBoxItem rcbi in cmbAccessories.Items) 
{ 
     if (rcbi.Selected) 
     { 
         //insert value in database 
     } 
} 


<telerik:RadComboBox ID="cmbAccessories" Width="200px"  
                                OnClientDropDownOpening="OnClientDropDownOpening"  
                                EmptyMessage="...Select Accessories"  
                                OnClientDropDownClosing="OnClientDropDownClosing"  
                                OnClientSelectedIndexChanging="OnClientSelectedIndexChanging"  
                                OnClientBlur="OnClientBlur" DataTextField="Name" DataValueField="AccessoryID"  
                                ValidationGroup="valItem" HighlightTemplatedItems="false"  
                                AllowCustomText="True" Runat="server" ShowDropDownOnTextboxClick="False"  
                                EnableTextSelection="False"> 
                                <ItemTemplate> 
                                    <asp:CheckBox ID="chkBox" Text='<%#Eval("Name") %>' onclick="checkboxClick();" runat="server" /> 
                                </ItemTemplate>                                 
                                <FooterTemplate> 
                                    <div style="width:100%;" align="center"><asp:Label ID="lblCloseMe" Text="CLOSE [X]" onclick="CloseMe();" style="cursor:pointer;" runat="server" /></div> 
                                </FooterTemplate> 
                            </telerik:RadComboBox> 


darenkov
Top achievements
Rank 1
 answered on 05 Apr 2010
1 answer
195 views
Hi,

I have a grid with many GridBoundColumns and one GridTemplateColumn. The GridTemplateColumn has a ItemTemplate which is generated dynamically from code-behind. I have a place holder in the ItemTemplate in which a table is added programmatically.
<ItemTemplate>
                            <asp:placeholder id="DetailPlaceHolder" runat="server"></asp:placeholder>
</ItemTemplate>

The table for each row in the Radgrid is added to the placeholder in the OnItemDataBound event. The grid displays the data in the perfect manner as desired.However, my export functions are not including the dynamically generated tables. All the export functions ExportToExcel, ExportToCSV, ExportToWord donot include the dynamically generated table in the GridTemplateColumn. I can get the excel and word to work by making the ExportOnlyData="false", but then also my ExportToCSV is not working. Can anyone please tell me how to solve this problem ??
Daniel
Telerik team
 answered on 05 Apr 2010
1 answer
152 views
I would like to be able to drag a row in the grid by having the user click on an image or image button in the grid row.  Basically I have an image with the work "Drag" in it that the user would click to drag the row to a new position in the grid.  Any ideas on how to implement this?
Pavlina
Telerik team
 answered on 05 Apr 2010
3 answers
85 views
Hello,

I have a user control that is put into a template grid column, the problem is that i am getting the table inside the user control styled with [.RadGrid_Simple .rgRow TD], am not sure if there is a work around to avoid this cascade. but i think it should not even existed.

please let me know if you have a suggestion for a workaround.

Dimo
Telerik team
 answered on 05 Apr 2010
1 answer
57 views
hi,
i have a problem with rad rotator in ie7 when i set my page style to RTL ;
when i set it the rotator not shown
please help me to resolve this problem
Fiko
Telerik team
 answered on 05 Apr 2010
10 answers
297 views
Under certain circumstances I may wish to remove the ability for a user to add a new item to the grid.

e.g.

User adds clicks:
            <CommandItemSettings
                  AddNewRecordText="Click here to add new item"

After clicking save\update and certain conditions are met I wish to block the user from being able to add any more items. Ideally I would like to set AddNewRecordText = ""
AddNewRecordImageUrl = "spacer.gif" to hide it

Is there a property I can set to say AddNew.Enabled = false or something similar.

This is a hierarchical grid and I do not wish to prevent the user from continuing to add items to the detail grid. Only the Master should be disabled.

Dimo
Telerik team
 answered on 05 Apr 2010
1 answer
79 views
I am watching your webinar on grid optimization, and one of the recommended techniques is to disable viewstate on all read only grids.
I have several grids that are read only, but that use:
<telerik:GridButtonColumn ButtonType="ImageButton" ImageUrl="~/images/icon_page_magnify.gif" HeaderText="Select" UniqueName="Select" CommandName="Select" /> 
and an OnItemCommand, which is causing an invalid postback problem.
I realize this is a limitation in .Net, but is there some other way to create a grid navigation activity that sets a session variable and redirects to a different page that would allow me to keep the viewstate off?

I am just trying to find some other way to achieve this result while still being able to leave the viewstate off.

The onItemCommand is this:
            if (e.CommandName.ToUpper() == "SELECT")  
            {  
                Session["A"] = e.Item.OwnerTableView.DataKeyValues[e.Item.ItemIndex]["A"];  
                Response.Redirect("~/Item/");  
            }  
 

Or maybe I don't need a session variable, how else could i send the user to another page with an id without using the query string???


Pavlina
Telerik team
 answered on 05 Apr 2010
1 answer
82 views
Hi,

I try to use this example (http://www.telerik.com/ArticleFileDownload.aspx?I=bdmh&G=bahm) 

In my case, because I'm french, we use some spécials latin chars like (éàç).

Radfileexplorer display this chars with no problem. But there is a function somewhere who return invalid chard in "physicalPathToFile"


Thanks
Fiko
Telerik team
 answered on 05 Apr 2010
2 answers
180 views
Hi,
I have a query (CTE) that returns the parent child relationship in a dataset and I can bind to an ASP.Net treeview but I want to be able to bind to a RadTreeView. Can anyone help me with the conversion?
Here's my code to bind to a treeview:
 Private Sub InitializeControls()  
 
        '==Get some info from the logged in user  
        Dim oContact As New Contact(UserInstance.ContactID)  
        '== Labels  
        lblDownline.Text = "My Distributor Downline" 
 
        LoadDataSet()  
        '== If it's the root node, SponsorID will be zero so use their contactid  
        Dim parentID As Integer = 0  
        If oContact.SponsorID = 0 Then 
            parentID = UserInstance.ContactID  
        Else 
            parentID = oContact.SponsorID  
        End If 
 
        BuildTree(TreeView1.Nodes, parentID)  
 
    End Sub 
 
    Private Sub LoadDataSet()  
        '==ds is declared at the page level  
        Dim oContacts As New ContactCollection  
        ds = oContacts.GetDownline(UserInstance.ContactID, 8) '==returns a dataset...later would like to return a collection  
 
    End Sub 
 
Private Sub BuildTree(ByVal nodes As TreeNodeCollection, ByVal IntParent As Int32)  
        Dim thisID As Int32  
        Dim thisName As String 
        Dim children As DataRow() = ds.Tables(0).Select("SponsorID='" & IntParent & "'")  
 
        If children.Length = 0 Then 
            Return 
        End If 
        Dim newNode As TreeNode  
        For Each child As DataRow In children  
            thisID = Convert.ToInt32(child.ItemArray(0))  
            thisName = Convert.ToString(child.ItemArray(2))  
            newNode = New TreeNode(thisName, thisID.ToString)  
            nodes.Add(newNode)  
            newNode.ToggleExpandState()  
            BuildTree(newNode.ChildNodes, thisID)  
 
        Next 
    End Sub 

Does anyone know how to do this with a RadTreeView? I almost had it working but the newNode doesn't have a ChildNodes collection.

Thanks
Rob Venable
Top achievements
Rank 1
 answered on 05 Apr 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?