![]() ![]() So ultimately, I want to take as much of the timing out of the script as I can so that it doesnt keep blowing up.This took me a while to figure out so I guess I should share how I got this to work. The problem I am having is that although all of that works, we have certain sites that due to latency, it messes the timing in the script up. My script also gets information and stores it into an excel file and copies the versions and running configs. I am pretty sure you cant and would have to actually write the script in WSH which would call securecrt and a script and then you could use the select all/copy and have the WSH script open up a notepad and paste it in.īasically, I have already accomplished all the automatic learning and logging in to the devices. I am not sure if you can transfer the control from CRT to notepad to be able to paste the data into it. I cannot think of a way to get that into a text file. What I meant was after you select all and copy as seen below: I cannot think of a way to get that information into a text file I also dont have to worry about error correcting or script latency issues, or link latency issues. If I can read back into the buffer (maybe by using a negative row count) then I can easily copy my running config into a text. Now I know I have some lines above the screen in the scrollback buffer because I cleared the screen and buffer before I issued the show run command. So what I am looking for is a way to do the following: do a 'show run' and then space through to the end of the config.ħ -^ above the screen in scrollback buffer So now you have to look for the last line read, 4, to see where you left off. Then you hit space again and this time you dont get a full screen: You readin the following starting at the top: The other one that comes to mind is if you have a config that isnt an even amount of pages then when you read the screen, you get duplicate lines unless you put a lot of error checking in.Įxample: - = edges of the screen, # = lines on the screen. We have timing issues within the script due to high latency links. Thats fine and dandy but it does have its problems. ![]() Basically the what I do it now is to do a 'show run', wait for the '-More-' or '#' to show up then start at the top and read one line at a time into a text file. ![]() What I am trying to work out and what I am looking for is a more efficient way of copying run configs. Sorry I'm a bit tired right now so I hope I can explain this without confusing you more. What is your objective after accessing the information in the scrollback buffer? ![]() If you clear the screen and scrollback before connecting to each device, would the MENU_SELECT_ALL and MENU_COPY work for you? Here are the function calls:Ĭrt.Screen.SendSpecial "MENU_CLEAR_SCREEN"Ĭrt.Screen.SendSpecial "MENU_CLEAR_SCROLLBACK"Ĭrt.Screen.SendSpecial "MENU_CLEAR_SCREEN_AND_SCROLLBACK" There is a way to clear the scrollback buffer and screen. For e-mail notification should the feature be implemented, please l et us know. If we add this capability in a future version we will post a follow up message. However, I've added your forum posts to our request database. There's currently not a way within SecureCRT of determining how many lines are in the scrollback buffer, and there's not a way to select only some of the lines in the scrollback buffer. There might be a solution that will work for you, but I'd like to address your question first. I was thinking along the lines of if you had 5000 lines of text in the scrollback buffer and you want to get lines 3000 to 2000 in the buffer ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |