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

Community Tip - Need to share some code when posting a question or reply? Make sure to use the "Insert code sample" menu option. Learn more! X

How to clear content in Autocomplete widget

vi1
15-Moonstone
15-Moonstone

How to clear content in Autocomplete widget

Hi,

 

I am using Thingworx 8.5.1 version.  I am trying to clear selected search content. Can any one help me how to clear search content from Autocomplete widget?.

 

Thanks&Regards,

Latha

5 REPLIES 5
VladimirN
24-Ruby II
(To:vi1)

 Hi Latha,

 

A similar question was already earlier - "Clear all content in autocomplete widget": https://community.ptc.com/t5/ThingWorx-Developers/Clear-all-content-in-autocomplete-widget/td-p/607094 

vi1
15-Moonstone
15-Moonstone
(To:VladimirN)

Hi,

 

Looks like there is no response for similar question.

 

Regards,

Latha

VladimirN
24-Ruby II
(To:vi1)

bchaudhary
17-Peridot
(To:vi1)

Hi Latha,

 

I have checked the possibility of clearing the entered text on button click using auto complete widget .The issue is auto complete widget is designed for holding a set of values and matching the entered content with set of values to show the suggestions .

There is no direct property/event in the widget which can directly clear the entered text. Even there is no possibility of resetting the entered text on button click .There is changedText property which takes the entered text but it’s an outgoing property (->) and so there is no way of setting the text to null on a click .

The only way it will be feasible is to have an incoming property called “ResetToDefaultValue” as we have it in text box .So you can take a reference of text box widget code and try to customize your auto complete widget for adding “ResetToDefaultValue” property .

 

You can customize it as per your need. Kindly check the below attached article:

https://www.ptc.com/en/support/article/CS201191

 

Regards

Bhawna

vi1
15-Moonstone
15-Moonstone
(To:bchaudhary)

Thank you.

 

I will try to develop custom widget.

 

Regards,

Latha

Announcements


Top Tags