Grab selected value RadDropDownList

2 posts, 0 answers
  1. Thijs
    Thijs avatar
    1 posts
    Member since:
    Jan 2016

    Posted 08 Jan Link to this post



    I am new with Telerik and to this forum. I'm working on a Radgrid with a dropdown box that will be populated on pre-render. This works fine and the values come in as expected. However, when I try to grab them they will not appear in newValues. If I change the RadDropDownList back to a GrindBoundColumn the function works as expected.

    Any help is appreciated! Thanks!


          <telerik:GridTemplateColumn HeaderText="Bin #" HeaderStyle-Width="260px" DataField="Bin_no" UniqueName="Mat_Bin_no">
                                                <telerik:RadDropDownList runat="server" ID="rddBin_no" Width="250px" 
                                                    DataTextField="Bin_no" DataValueField="Bin_no">



      Private Function FindMaterialData(ByVal sender As Object, ByVal e As GridBatchEditingEventArgs, sOrdNo As String, sLoc As String) As Boolean
            Dim bErrorsFound As Boolean = False
            Dim p_iWisysReturnValue As Integer = 0
            Dim iSequenceNo As String
            Dim sItemNo As String
            Dim sBin As String
            Dim sSerialLot As String
            Dim dqty As Double
            Dim dtExpDate As Date
            Dim e2 As Telerik.Web.UI.GridItemEventArgs
            Dim bIsEdited As Boolean = True
            Dim lOffset As Long = 0
            For Each row As GridDataItem In rgMaterial.Items
                Dim Command As GridBatchEditingCommand
                    Command = e.Commands.Item(row.ItemIndex - lOffset)
                    If Command.Item.DataSetIndex <> row.ItemIndex Then
                        bIsEdited = False
                        lOffset = lOffset + 1
                        bIsEdited = True
                    End If
                    bIsEdited = False
                End Try
                iSequenceNo = row("Mat_seq_no").Text
                sItemNo = row("Mat_item_no").Text
                ''Edited rows
                If bIsEdited Then
                    Dim newValues As Hashtable = Command.NewValues
                    Dim oldValues As Hashtable = Command.OldValues
                    sSerialLot = newValues("ser_lot_no")
                    sBin = newValues("bin_no")
                    dqty = newValues("QtyRemaining")
                    'Non edited rows
                    sSerialLot = row("Mat_ser_lot_no").Text
                    sBin = row("Mat_bin_no").Text
                    dqty = row("Mat_QtyRemaining").Text

                End If
                If dqty <> 0 Then
                End If
            FindMaterialData = Not bErrorsFound
        End Function

  2. Eyup
    Eyup avatar
    2942 posts

    Posted 13 Jan Link to this post

    Hello Thijs,

    Please note that Batch editing mode is different than other modes. You can find a detailed explanation in the following section:

    You can find related information for implementing Batch editing with templates in this article:

    Hope this helps.

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  3. DevCraft R3 2016 release webinar banner
Back to Top