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

Community Tip - Help us improve the PTC Community by taking this short Community Survey! X

write to a local file

hruke
1-Visitor

write to a local file

Hi,

Is there any API function to write data on local file.

Ex:

I want to write 'Hello Word' in the file located on my machine through Script.

ACCEPTED SOLUTION

Accepted Solutions
jgorsline
12-Amethyst
(To:hruke)

Hanumant,

You can write to a local file using the standard Java IO bean.

For example:


var fw = new java.io.FileWriter("<filename>");
fw.write("Hello World \n");
fw.close();

View solution in original post

2 REPLIES 2
jgorsline
12-Amethyst
(To:hruke)

Hanumant,

You can write to a local file using the standard Java IO bean.

For example:


var fw = new java.io.FileWriter("<filename>");
fw.write("Hello World \n");
fw.close();

Hello Hanumant,

Did Jeremy's response resolve this issue for you?  If so, could you click on the25153012_3loy.pnglink in his post?  This lets everyone know you found a useful solution to your issue, and is visible from those browsing threads but not browsing into them--for instance for users searching for questions similar to yours.

If Jeremy's response was not helpful, can you please let us know why it was not, and what problems you encountered, so that we can try to help you resolve this issue.

Thanks,

Kael


Kind Regards,
Kael Lizak

Senior Technical Support Engineer
PTC Integrity Lifecycle Manager
Announcements


Top Tags