Adding items to list boxes in native Dynamics GP forms using visual studio add-in

List boxes, Drop down lists, Combo Boxes can be added using modifier to Dynamics GP forms, but they are not supported for .NET access from visual studio addins.

List boxes

Combo box

For example, adding list items to list boxes and combo boxes in native GP forms is not supported via .NET,  Dexterity modifications must be used if this is the requirement.

Work around

When faced with this problem it can be better to force the user into a .NET form for the selection. This can be achieved by hiding or disabling (make read-only) the original list or combo box, placing an “update” button next to it or in place of it. Clicking that button then opens a .NET form that has a combo box or whatever control in it, thus allows the population and selection.  This is not a nice UI interaction for the user but is the best option I have found. This will not always be appropriate but best I can suggest.

If you want to live on the edge (and use unsupported techniques) read these:

David's talks about the general subject of list boxes and drop downs, gives you some background.

All About List Box button Drop lists and drop down lists

My (now quite old post), I add an item using VBA, but these days I'd do this by referencing the .NET Continuum COM library to allow .NET code in the Dynamics GP Visual Studio addin to pass SanScript through to the GP, the technique is shown in the third link, although applied to a different problem.

Copy Address Button implemented using VBA

more resources:

How to make the GP company login text boxes longer

Add Item to the List Box on an existing GP screen through VS Tools for GP

Add comment

Loading