Service Manager / Service Center Practitioners Forum
Showing results for 
Search instead for 
Do you mean 

Write to a text/log file

SOLVED
Go to Solution
Advisor

Write to a text/log file

Has anyone ever tried writing a message into a text file in SM7.11?  I don't want to send the messages into the sm.log file.  I want to use my own log file in the server.

 

Would appreciate any ideas on this one.

 

Regards.

 

 

4 REPLIES
Frequent Advisor

Re: Write to a text/log file

Hi P, Use javascript to achieve this. As rtecall("log") print message in sm.log file only.
Honored Contributor

Re: Write to a text/log file

As Abhijit stated, Service Manager provides a JavaScript global method named writeFile (see Help Server). The documentation states it writes data to the local file system. It is important to note that SM supports server-side JavaScript only so the "local file system" is the server (not the user's client machine).

Advisor

Re: Write to a text/log file

Neat! Thanks guys. Thanks for that very useful info.
Highlighted
Frequent Advisor

Re: Write to a text/log file

Appreciate KUDOS.