Developer forum

Forum » Development » DropDwon

Reply
Hi,
I’m a newbie in the DynamicWeb module development, I’m changing a payment gateway (developed by other programmer) and in the back office I need to add a dropdown. At this point, the dropdown appears in the back office but I don’t know how to populate it.

Here is the code where I create the dropDown

 

<AddInParameter(

 

"DW Payed Status ID"), AddInParameterEditor(GetType(Editors.DropDownParameterEditor), "")> _Public Property PayedStatusID() As String

 

Get

 

 

Return _STATUSIDEnd Get

 

_STATUSID = Value

 

Set(ByVal Value As String)End Set

 

End Property

Replies

 
Reply
Hi Humberto 

All you need to do is to make your class implement the interface IDropDownOptions and implement the method IDropDownOptions.GetOptions(string name)

The 'name' parameter passed to the method is the name of your AddinParameterEditor (in your case "DW Payed Status ID"). This matters if you have multiple dropdowns in your gateway provider.

The return value of the GetOptions method is a Hashtable with keys and values just like the keys and values in your dropdown.

 - Lasse

 
Reply
Thanks!!

 

You must be logged in to post in the forum