DriveWorks Tech Tip: How to make a Greyed-Out Transition Button [VIDEO]

Article by Jim Peltier, CSWE updated March 4, 2015

Article

Making forms in DriveWorks is nice and easy, but getting the user to fill them out completely is….. also easy! I bet you thought I was going to say it was a different story, didn’t you? Well, you can prevent them from proceeding by making the transition button greyed out.

In this example, I’ve created a form with 4 checkboxes. My design intent is that the user must check all the boxes in order to proceed. However, by default, the Proceed button is always available. Let’s see how it’s done:

As you can see, I can setup a rule for the availability of the button. If the rule solves as FALSE, then the button is greyed out. I’ve bypassed this using a variable (called “CheckAllTheBoxes”) but this is simply to make troubleshooting and editing the project easier. I could also have put my massive nested IF statement in that place instead of in the variable. Since I didn’t show it in the video, the variable’s rule is as follows:

=IF(CheckReturn,IF(AllReturn,IF(TheReturn,IF(BoxesReturn,TRUE,FALSE),FALSE),FALSE),FALSE)

I could shorten that to exclude FALSE so many times, but I like seeing what I’m getting and it makes it easier to show. Other examples would be IF(ComboBoxReturn=””,FALSE,TRUE) or IF(TextBoxReturn=””,FALSE,TRUE). Note the reversal of the TRUE/FALSE on these. Because the blank means the field has not been completed, it is not what we want. In my above example, when I say IF(BoxesReturn,TRUE,FALSE) it’s short for IF(BoxesReturn=TRUE,TRUE,FALSE)

As far as where I used that variable, I went to the Specification Flow and found the State in question. Then I clicked Edit. Once in the Edit State dialogue window, I right-clicked on the Transition and chose Edit Conditions from the resulting menu. In the Conditions Editor window, I was able to drag and drop the Check Value condition from the Toolbox window into the Conditions window. I then edited the Value field for this to read =IF(DWVariableCheckAllTheBoxes,TRUE,FALSE).

I could have also simplified this to =DWVariableCheckAllTheBoxes since it is also a boolean (true/false) variable.

Obviously your application will be different, but I hope this simplified example has shown you what is needed to make a transition button greyed-out in DriveWorks.

Related Links

Get Certified SOLIDWORKS Services from Javelin

Javelin Experts can help you to:

Jim Peltier, CSWE

Jim has been using SolidWorks since 2001, and has spent most of that time working in the design of industrial automated manufacturing equipment. He has been working as an Applications Expert at Javelin Technologies in Oakville, Ontario since July 2012 and is a Certified SolidWorks Expert (CSWE).