Harlem 98

Harlem 98

  • 2k
  • 161
  • 5.4k

Passing value to user control cantaining edit form

Dec 13 2021 6:21 PM

Hello community.

I'm trying to perform an insert operation, through a user control containing an edit form in a grid, which is filtered by user ID, which is, by his own, FK of my table. My problem is that, i need to keep that filtering value of the parent form, in my user control's edit form.

I want to do something like `userID.SelectedValue` to bind the value in the edit form, but obviously i can't, because is not part of my class. What should i do to pass the value to be able to bind it?

//Filtering of the value “IDRecursoHumano” in parent control
    <telerik:RadComboBox ID="rdpInvestigador" (…)

    //insert method in child class

    (..) //some other code
    model.userIDchild = Convert.ToInt32(userIDparent.SelectedValue);

 


Answers (1)