Have One Drop-Down Based Off The Selection From Another In Print Prompt 追蹤

0
Avatar
Legacy Poster

I'm trying to make some product labels, and I'm running into an issue. It appears that the print dialogue populates the drop downs based on the default data.

 

I have 3 selections:

1. Text Entry for Serial number  

2. Drop down for Product Base

3. Drop down for Product Model 

 

while the different categories share some models, but some categories have unique models. And I want to eliminate the possibility of an input error, and avoid listing all possible models. 

 

I need 3 to change its selections based on what is currently selected in 2. 

 

My first attempt was making a Case/Switch based on the linked substring for 2, but that is where I ran into my problem. I also tried looking at 2's object name instead of the substring, but that didn't work either. I think I need some way to have a continuous refresh, or have a refresh any time the selection in 2 is changed. 

 

Any ideas?

 

As an example:

There are 3 Bases: A, B and C

Base A has the following models: 1, 2, 3, 4, 6

Base B has the following models: 1, 3, 4, 5, 6

Base C has the following models: 6, 7

1 意見

0
Avatar
Legacy Poster
評論操作 永久連結

Hello,

 

I encountered a similair problem with selecting a table based on what database is selected. The problem is that there is no way to "refresh" a dropdown box when a selection has been made in another form element within Bartender.

However, Bartender 2016 supports multiple forms which would be presented to the user in an order. This would solve al your problems with some vbscripting behind it.

 

My work around involved making a .hta file which would be opened on the OnOpen event. This file contained a script which would search for al the available databases in a directory and populate a dropdown box with this data where the user can select a database. The selection would be written down in an external .txt file and then finally Bartender would read the value of that txt file and list al the tables on the form in a dropdownbox from that specific database.

I don't know how skilled you are in scripting but search for hta file and it may provide you with some information on how to accomplish this, althought my advice is to either upgrade or drop the case.

登入寫評論。