Drop down list on a form in a drawing

Drop down list on a form in a drawing

donaldleigh
Advocate Advocate
360 Views
2 Replies
Message 1 of 3

Drop down list on a form in a drawing

donaldleigh
Advocate
Advocate

Evening all

 

I would like to have a form that when used in the drawing environment, has a drop down list to pick from

 

I have created this when used in a part or assembly but in the drawing environment you don't have have any parameters. Is there a way to do this without parameters.

 

Donald

Inventor 2022

0 Likes
361 Views
2 Replies
Replies (2)
Message 2 of 3

A.Acheson
Mentor
Mentor

A few questions. What information is being placed into the form and where is it being sourced from? The model in the view, the drawing itself? If you can screen shot what information you have now and want to recreate that will help. 

If this solved a problem, please click (accept) as solution.‌‌‌‌
Or if this helped you, please, click (like)‌‌
Regards
Alan
0 Likes
Message 3 of 3

WCrihfield
Mentor
Mentor

Hi @donaldleigh.  I have some of the same questions that @A.Acheson asked, but I may be able to answer the last question, to some degree.  When you are using a regular iLogic Form, you are pretty much limited to using a multi-value user parameter as the source of any drop-down lists you put in them.  If you are using either a VBA UserForm or a regular Windows Form, you can specify the list contents within the code for the form itself.  However, if your list of available options for your drop-down list is set (constant), there is another much simpler way to display a list of options, and have the user select one of those options.  In an iLogic rule, you can use a List type object for holding the options, then show them for interaction with an InputListBox() method, which will return the selected option.

Here is a very simple iLogic rule demonstrating this:

Dim oListOfOptions As New List(Of String)
oListOfOptions.Add("Option 1")
oListOfOptions.Add("Option 2")
oListOfOptions.Add("Option 3")
oListOfOptions.Add("Option 4")

Dim oChoice As String = InputListBox("Choose Option", oListOfOptions, "", "Options List", "List Of Options")
If oChoice = "" Then
	MsgBox("You did not choose anything.", , "")
Else
	MsgBox("You chose:  " & oChoice, , "")
End If

If this solved your problem, or answered your question, please click ACCEPT SOLUTION.
Or, if this helped you, please click (LIKE or KUDOS) 👍.

Wesley Crihfield

EESignature

(Not an Autodesk Employee)

0 Likes