Telerik Forums
UI for ASP.NET AJAX Forum
4 answers
95 views
Hi All

I have a RadGrid as follows:

<telerik:RadGrid ID="trgStudAttend" runat="server" AllowSorting="True" 
    AutoGenerateColumns="False" GridLines="None" Skin="Windows7" 
    CellSpacing="0" AllowMultiRowEdit="True">
    <ClientSettings EnableRowHoverStyle="true" />
    <MasterTableView DataKeyNames="atdID" EditMode="InPlace">
        <Columns>
            <telerik:GridBoundColumn DataField="atdID" HeaderText="ID" Visible="false" 
                UniqueName="atdID">
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="studDisplayName" HeaderText="Name"
                UniqueName="studDisplayName" ReadOnly="True">
            </telerik:GridBoundColumn>
            <telerik:GridDropDownColumn DataSourceID="sdsTimeOfDayCodes" HeaderText="Time of Day" 
                ListTextField="comb" ListValueField="todcCode" UniqueName="todcCode" DataField="atdTimeOfDayCode">
            </telerik:GridDropDownColumn>
            <telerik:GridDropDownColumn DataSourceID="sdsReasonCodes" HeaderText="Reason" 
                ListTextField="comb" ListValueField="rfacCode" UniqueName="rfacCode" DataField="atdReasonCode">
            </telerik:GridDropDownColumn>
            <telerik:GridBoundColumn DataField="atdComment" HeaderText="Comment"
                UniqueName="atdComment">
            </telerik:GridBoundColumn>
        </Columns>
    </MasterTableView>
</telerik:RadGrid>

At post back, every item is in edit mode.

I also have a button on my page (trbSave). When clicked, I want to loop through each row in my RadGrid, and determine what the selected value is for my drop down columns. I am trying this so far without any luck:

' Declarations
Dim sqlString As String = ""
Dim sqlCom As SqlCommand
Dim todcDDL As RadComboBox
' Loop through each student in the radgrid, and save the selected values to the details database
For Each i As GridDataItem In trgStudAttend.EditItems
    todcDDL = i.FindControl("todcCode")
Next

i.FindControl("todcCode") always returns 'nothing'. Does anyone know how I can reference that drop downlist and get its currently selected value?

Shane
Elliott
Top achievements
Rank 2
 answered on 29 Apr 2011
4 answers
141 views
Hi,

We are using the RadEditor on our sharepoint portal.

When the user tries to add a word to the dictionary a pop-up appears with the following error message: "Spell Checker Handler  Server Error: 403 FORBIDDEN".

I presume that adding a word to the dictionary updates one of the *.tdf file. Is there specific security settings to be assigned to those files ?
Rumen
Telerik team
 answered on 29 Apr 2011
3 answers
40 views
Does the ASP.Net Ajax grid have options for data binding like the grid in MVC? If not, is it to be expected in an upcoming release?

With the grid in MVC, you have the option of doing the following types of binding:
  • Server
  • Ajax/JSON
  • Web Services 
Mira
Telerik team
 answered on 29 Apr 2011
8 answers
179 views
How Can I Change The popup Designed Manually .
mohamed
Top achievements
Rank 1
 answered on 29 Apr 2011
3 answers
154 views
Hi -

I have a page with two RadGrids. Each grid has drag and drop enabled. I use the row-drag capability to re-order items within each grid. The RowDrop event is used on the server side to re-order. It works great.  However, I dont want to be able to drag a row from one grid onto the other grid. Is there a way to prevent draging rows from one grid and dropping them on the other on the client?  If not, is there a way to determine what the "source" grid was in the RowDrop event on the server. The GridDragDropEventArgs class has a DestinationGrid property in it but no SourceGrid property. Is there a way to determine the source grid so I can just ignore any drops from other grids?

Thanks for your help... Russ
Sameers
Top achievements
Rank 1
 answered on 29 Apr 2011
1 answer
62 views
Hi, we're using RenderSelectedPageOnly and AutoPostback to load on demand several page views. But now every time we change the selected tab an AJAX request is made (because of the AutoPostback), even though the tab had already been loaded.

We would like to load on demand the selected tab only if it's the first time the user selects that tab. Otherwise the tab change should behave without the AJAX request, just like it would with RenderSelectedPageOnly=false

Is there a way to achieve this behavior?

Best regards,
Santiago.
Cori
Top achievements
Rank 2
 answered on 29 Apr 2011
7 answers
128 views
Hi,

is it possible to create the context menus dynamically in the client side? And further more is it possible to created them based on some appointment properties? 

I'm looking the documentation but it doesn't say anything regarding that.

regards,

jose
Veronica
Telerik team
 answered on 29 Apr 2011
4 answers
72 views
Hi,

I am using the Radfilter in my vb.net(2008) project.I am using the RadTreeview as the radcomboboxItem in the datafield editor.I mange to build the control dynamically.But when I add new rows for the filter,previously selected value is set to empty.

Please help on this issue..
Public Overrides Sub InitializeEditor(ByVal container As System.Web.UI.Control)
        _combo = New RadComboBox()
        _combo.ID = "MyCombo"
        _combo.Width = 200
        _combo.Height = 180
  
  
        'For the Treeview
        Dim treeItem As New ItemTemplateTreeView(CreateDataSource())
        _combo.ItemTemplate = treeItem
        Dim item As New RadComboBoxItem()
        _combo.Items.Add(item)
        _combo.OnClientDropDownOpened = "OnClientDropDownOpenedHandler"
               container.Controls.Add(_combo)
  
    End Sub
  
  
Public Overrides Function ExtractValues() As System.Collections.ArrayList
        Dim list As ArrayList = New ArrayList()
        list.Add(DirectCast(_combo.Items(0).FindControl("myTreeview"), RadTreeView).SelectedValue)
        Return list
    End Function
  
Public Overrides Sub SetEditorValues(ByVal values As System.Collections.ArrayList)
          
        If Not values Is Nothing And values.Count > 0 Then
            If values(0) Is Nothing Then
                Return
            End If
            'Dim item As RadComboBoxItem = _combo.FindItemByValue(values(0).ToString())
            Dim item As RadTreeNode = DirectCast(_combo.Items(0).FindControl("myTreeview"), RadTreeView).FindNodeByValue(values(0).ToString())
            'If Not item Is Nothing Then
                item.Selected = True
                _combo.Items(0).Text = item.Text
            '   _combo.Items(0).Value = item.Value
            End If
             
        End If
    End Sub
  
Protected Function CreateDataSource() As DataTable
        Dim dataTable As New DataTable()
        dataTable.Columns.Add(New DataColumn("Key", GetType(String)))
        dataTable.Columns.Add(New DataColumn("Name", GetType(String)))
        dataTable.Columns.Add(New DataColumn("ParentId", GetType(String)))
  
        Dim AnalysItems As AnalysListItemList = TryCast(DataSource, AnalysListItemList )
  
        For Each item As CategoryValueListItem In AnalysItems
            Dim dr As DataRow = dataTable.NewRow()
            dr("Key") = item.Key
            dr("Name") = item.Name
            If item.Category = item.Key Then
                dr("ParentId") = DBNull.Value
            Else
                dr("ParentId") = item.Category            End If
            dataTable.Rows.Add(dr)
        Next
        Return dataTable
    End Function
  
Public Class ItemTemplateTreeView
    Implements ITemplate
  
    Private dataTable As DataTable
    Public Sub New(ByVal _dataTable As DataTable)
        '
        ' TODO: Add constructor logic here
        '
        Me.dataTable = _dataTable
    End Sub
    Public Sub InstantiateIn(ByVal container As Control) Implements ITemplate.InstantiateIn
        Dim div As New HtmlGenericControl("div")
        div.ID = "div1"
        div.Attributes.Add("onclick", "StopPropagation(event);")
  
        Dim tree As New RadTreeView()
        Dim item As RadComboBoxItem = DirectCast(container, RadComboBoxItem)
  
        tree.ID = "myTreeView"
        tree.OnClientNodeClicking = "nodeClicking"
        tree.DataTextField = "Name"
        tree.DataFieldID = "Key"
        tree.DataValueField = "Key"
        tree.DataFieldParentID = "ParentId"
        tree.DataSource = dataTable
        tree.DataBind()
  
        div.Controls.Add(tree)
        container.Controls.Add(div)
  
  
    End Sub
  
End Class
Radoslav
Telerik team
 answered on 29 Apr 2011
1 answer
51 views

Hi


I use this on my application , everything is a goof on local,but when i upload project on my hosting space ,many time i got out of memory error in this page . i like it .please help,
is exist any better solution ?
thanks .
Radoslav
Telerik team
 answered on 29 Apr 2011
1 answer
36 views
Ok, so I have a Toolbar which is Width="100%"

The Left side of the toolbar needs Next\Previous buttons, while Right Aligned there needs to be a templated RadCombo container

How can I do this with the control?....is it an option?
Kate
Telerik team
 answered on 29 Apr 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Anislav
Top achievements
Rank 6
Silver
Bronze
Bronze
Jianxian
Top achievements
Rank 1
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Jim
Top achievements
Rank 2
Iron
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Anislav
Top achievements
Rank 6
Silver
Bronze
Bronze
Jianxian
Top achievements
Rank 1
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Jim
Top achievements
Rank 2
Iron
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?