Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

scrolling back for a capture

Status
Not open for further replies.

tedzap

Programmer
Aug 12, 2006
31
US
Is there any way to scroll back and capture what has been written previously to the screen? This is what I have a user do when they encounter a problem: scroll back and capture/email what led up to the condition.

 
Are you looking to capture what occurs after an error code? Or looking to be able to scroll back and capture what happened prior to an error code?

You could use the When Target in ASPECT to start capturing data after a specific bit of text appears.

Otherwise, you can adjust the size of your scroll back buffer in your Terminal Options setup, by increasing the number of scroll back pages.
 
When an error message occurs I would like the script to scroll back several pages, capturing things that led up to the error. Does this make sense?

I see how the When Target could trigger the script to start it's thing, but how to automate the scrolling back (and capture)?

 
I'm not certain that it's possible (I could be wrong) to use ASPECT to pull data directly out of the scrollback buffer.

Is it feasible to capture the entire session, and if no error's occur, erase the temporary capture file. And if an error does occur, then save the file and forward on?

This would give you more control. I don't recall ever seeing any reference to automate the scrollback buffer.
 
I guess I am reluctant to capture the entire session, afraid that it would get too large and impact the workstation performance. The frequency is also very low, but I will consider this.

Under the EDIT menu, there is the option of saving the scrollback buffer to various places, or even sending it to MAPI mail. Is there no way to automate this type of menu command?

thanks
 
I may have answered my own question here. I think this might work.


set capture filename "scrollback.txt"
capture on
menuselect PWMENU 220 ; copies scrollback to capture file
capture off



 
Good find. I didn't consider that. You could set the terminal options to the number of pages you wanted to capture, and avoid collecting too much information (avoiding excessive transmit times.)

Code:
terminal sbpages integer

Determines the number of pages stored by the Scrollback Buffer. Valid values range from 0 to 1300. This command corresponds to the Scrollback pages: field in the Setup, Data, Terminal Options dialog. fetch returns the current number of Scrollback pages.
 
oops, I had a typo. it should have been menu item 219 instead of 220.
 
Been out with strep today, but one other thing instead of using a capture file, is to use the sbsave command and just write the scrollback buffer directly to a file without having to name, open, and close a capture file.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top