Showing results for 
Search instead for 
Do you mean 
Reply

Writing to a text file instead of the listing window.

How do you write to a text file instead of the listing window using

 

Session.Information.DisplayObjectsDetails(NXObject[] objects)

?

5 REPLIES

Re: Writing to a text file instead of the listing window.

The following article has an explanation.

 

http://nxjournaling.com/content/write-text-file

Re: Writing to a text file instead of the listing window.

Thank you.

Re: Writing to a text file instead of the listing window.

To quickly document the answer here in case the external link goes stale and/or for searchability, use ListingWindow.SelectDevice() to direct the contents of the listing window to the window, a text file or both

Re: Writing to a text file instead of the listing window.

The main thing to remember when using the listing window to write to a file is that you need to "flush the buffer" by changing the output device to something else after writing your information. Otherwise, the information may not be written to file.

Re: Writing to a text file instead of the listing window.

What info can you get from DisplayObjectDetails that you can't get from other API functions? Digging through a mass of text to find the info you need seems pretty painful.
山田
yamada