Anil Issac
Member
- Joined
- Apr 28, 2007
- Messages
- 5
- Programming Experience
- 3-5
I am working on a plugin based application and I have a navigation architecture in my base module. I am storing the form information in cache (like a view state). Now I will explain my question with an example below;
Can you please suggest a solution how I can retrive the parameter value of the object?
VB.NET:
'Instance of a form (in plugin module) with a Param, ;Passing ParamValue=10
Dim obj As Object = New Form2(10)
'Now I want to retain the value of parameter from the object 'obj
Dim t As Type = obj.GetType()
Dim ctrInfo As ConstructorInfo()
ctrInfo = t.GetConstructors()
For Each c As ConstructorInfo In ctrInfo
'Here I am getting total number of Params passed
MsgBox(c.GetParameters().Length)
Dim pif As ParameterInfo() = c.GetParameters()
'Here I am getting the type of parameter
For Each p As ParameterInfo In pif
MsgBox(p.Position & " Type: " & p.ParameterType.ToString & " parameter name: " & p.Name)
'Now my question is how I will get the value assigned to that parameter ie ParamValue =10
Next
Next
Last edited by a moderator: