ThingWorx properties can be updated from a Vuforia Studio experience.
Below is a simple example:
- Create a test Thing and a test property for the Thing in ThingWorx :
- Create a service for the Thing with text input parameter(Test) and add the below code to update the TestProperty value:
- Click Done and Save the Thing
- In Vuforia Studio, Add a Text Input widget and a Button widget in 2D canvas
- Add the service of the Thing in the External data Panel
- Now, bind the Text property of the ‘Text Input’ widget to the Test Parameter of the service as shown below:
- Bind the Click event of the Button widget to the Service to update the value of Thing property in ThingWorx
- Test the experience by clicking Preview. Enter text in the Text Input widget and click the button. The Thing property should then be updated.
If you are creating a public experience, ensure that run time permissions for the es-public-access user have been assigned to the properties, events and services of the entity.
- From ThingWorx composer, open the entity whose data must be accessed by a public experience
- Click the Permissions icon in the last column of the row containing the entity
- Click Run Time under Permissions
- Under All Properties, Events, Services, use the search box to find and add the es-public-access user
- Click green dot under the appropriate permissions columns
- Click Save
See the Vuforia Studio Help Center for more information on granting user permissions in ThingWorx for Vuforia Studio.