cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Your Friends List is a way to easily have access to the community members that you interact with the most! X

How to disable and enable button by selecting multi-selected dropdown widget in thingworx.

Hrishab108
7-Bedrock

How to disable and enable button by selecting multi-selected dropdown widget in thingworx.

I want to validate the button when I select the multi-selected dropdown values, the button should be enabled, and vice versa.

 

1 ACCEPTED SOLUTION

Accepted Solutions

Hi @Hrishab108 

 

You can create a service to validate multiple selected rows and based on that you can enable and disable the button

 

Create service with infotable input 

var result = true;
// selectedValue : InfoTable Input
// If Infotable contains multiple rows
if(selectedValue && selectedValue.length > 1)
{
    // enable button
    result = false;
}

 

Mashup Binding should look like this :

Velkumar_0-1684496207623.png

 

Mashup will look like this :

 

Velkumar_1-1684496259741.png

 

Velkumar_2-1684496284875.png

 

Velkumar_3-1684496303075.png

 

When multiple value selected button will enable

 

/VR

 

 

View solution in original post

3 REPLIES 3

Hi @Hrishab108 

 

You can create a service to validate multiple selected rows and based on that you can enable and disable the button

 

Create service with infotable input 

var result = true;
// selectedValue : InfoTable Input
// If Infotable contains multiple rows
if(selectedValue && selectedValue.length > 1)
{
    // enable button
    result = false;
}

 

Mashup Binding should look like this :

Velkumar_0-1684496207623.png

 

Mashup will look like this :

 

Velkumar_1-1684496259741.png

 

Velkumar_2-1684496284875.png

 

Velkumar_3-1684496303075.png

 

When multiple value selected button will enable

 

/VR

 

 

nmutter
14-Alexandrite
(To:Velkumar)

Instead of the extra service https://github.com/doubleSlashde/InfotableInspectorWidgetTWX could be used to get Selected-RowCount in Frontend and evaluate button "disabled"-state via expression. But needs the extra extension - depending on how often it is needed the extension may be useful.

Thanks, @Velkumar 
I appreciate your time.

Top Tags