How to use value from drop down list as a value in another objects script Follow
I have done a lot of VBA scripting in the past and have a general understanding of how things should work, but I am having a hell of a time getting even 1 label created in Bartender. I was given this project after not having coded anything in years and I have muddled a few things together but have run into a problem I have been unable to overcome.
I am designing a label with a couple data entry fields on it. The first field is a drop down list which pulls its values from a old access database. This works, and I can select the field, and the selection appears on the label at print preview. The second field is a quantity field. This is where I am stuck. I have a script put together on this field that will pull the quantity based on the "selection" value however my selection value is static (selection = "PM1001-1"). It works and pulls the quantity for that part and displays it on the label. However I cannot for the LIFE of me figure out how to have selection equal to the drop down list selected value!
I have tried several things:
selection=Format.Objects("DropListPart").Value - script error-Operation not supported for this object type
I also tried to set the chosen value to a named data source but don't know how to use them really. What I did was in the drop down list script I put in the line
Format.NamedSubStrings("DropDownList").Value = value (value is the variable which populates the list)
I then went into the script for the quantity box and added
and I got the error Either BOF or EOF is true. The current record has been deleted. Requested operation requires a current record
Any help would be greatly appreciated. This feels like it should be super simply and I'm just missing the proper syntax to load the value of the dropdown into the variable in the other script.
Please sign in to leave a comment.