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

Community Tip - Visit the PTCooler (the community lounge) to get to know your fellow community members and check out some of Dale's Friday Humor posts! X

Need service for moving file from local directory to Thingworx Repository

SR_9679028
9-Granite

Need service for moving file from local directory to Thingworx Repository

How to move the file from local directory to Thingworx repository folder using service.

9 REPLIES 9
PaiChung
22-Sapphire I
(To:SR_9679028)

There is the FileUpload Widget, also potentially REST API post and the Thingworx Agent you can explore for this.

Instead of file upload widget and RestApi is there any code or snippets available.

PaiChung
22-Sapphire I
(To:SR_9679028)

I do not have any, sorry.

slangley
23-Emerald II
(To:SR_9679028)

Hi @SR_9679028.

 

Can you provide more regarding the use case?  Do you expect to have multiple users using it?  Just creating a service might not be the best approach.

 

Regards.

 

--Sharon

Actually, we are trying to import a .csv file using the file upload widget. In that .csv file, there will be a link to the image like (D:\Pictures\image.png). after I imported the.csv file the image specified in the link should be copied to the system repository. This is the process.

I don't have an end-to-end example, but here is how I'd approach the task...

 

There is the Thingworx/FileRepositoryUploader endpoint which, probably can be used. This is the one used by the FileUploader widget, as far as I understand.

You can check the JS code in the \webapps\Thingworx\Runtime\mashup-common-widgets-runtime.js

It was a big code. actually, can't even find where the function is available.

slangley
23-Emerald II
(To:SR_9679028)

Hi @SR_9679028.

 

If the previous response provided a solution for you, please mark it as the Accepted Solution for the benefit of others in the community.

 

Regards.

 

--Sharon

slangley
23-Emerald II
(To:slangley)

Hi @SR_9679028.

 

Have you found a solution to meet your specific needs?  If so, we would be happy for you to share with others in the community.

 

Regards.

 

--Sharon

Top Tags