Welcome to the VanDyke Software Forums

Join the discussion today!


Go Back   VanDyke Software Forums > General

Reply
 
Thread Tools Display Modes
  #1  
Old 02-26-2013, 03:46 PM
joneill joneill is offline
Registered User
 
Join Date: Oct 2011
Posts: 8
SecureCRT Closure events

Hi All,

Not sure if this is in the correct section or not, so apologies in advance.

I have written some software that automates the login process to certain network devices (username/passwords/hostnames etc) via the VB Scripting in SecureCRT. This works fine and I have incorporated an "exit" function, so when the user finishes their work, they can correctly log out of the device they're using.

Unfortunately, if the user simply closes SecureCRT, the logout is no longer clean and occasionally we get stuck sessions.

Is there a closure event in SecureCRT that I can force a logout script if a user simply hits the "x" to close the application? Or should this be done by scripting?

Thanks
Joel
Reply With Quote
  #2  
Old 02-26-2013, 04:43 PM
bgagnon bgagnon is offline
VanDyke Technical Support
 
Join Date: Oct 2008
Posts: 4,596
Hello Joel,

You can prevent users from closing SecureCRT via the "red x" by changing the following entry in the Global.ini file.

The Global.ini file is stored in the configuration folder. The location of your installation's Configuration folder is found in the General category of SecureCRT's Global Options.

Please note:
Close SecureCRT before editing the Global.ini file.


Change:
D:"Disable Close"=00000000
to
D:"Disable Close"=00000001
__________________
Thanks,
--Brenda

VanDyke Software
Technical Support
support@vandyke.com
(505) 332-5730
Reply With Quote
  #3  
Old 02-27-2013, 01:59 PM
joneill joneill is offline
Registered User
 
Join Date: Oct 2011
Posts: 8
Thanks for the response, however I'm not trying to stop them from closing the application, rather, ensure a script or closure event is run when they do.
Reply With Quote
  #4  
Old 02-27-2013, 02:48 PM
rtb rtb is offline
VanDyke Technical Support
 
Join Date: Aug 2008
Posts: 4,306
Hi Joel,

The option that Brenda suggested is not a way to stop the application from being closed. It is a way to stop the application from being closed while there is an active connection. Once the user has disconnected from the remote host, then they should be able to close SecureCRT normally.

Does this help to clarify the option?

If so, does this option meet your needs?
__________________
--Todd

VanDyke Software
Technical Support
support@vandyke.com
505-332-5730
Reply With Quote
  #5  
Old 02-27-2013, 03:47 PM
joneill joneill is offline
Registered User
 
Join Date: Oct 2011
Posts: 8
Thanks for the response Todd - it does clarify what was meant, but still does not do what I'm looking for.

Essentially, the user could hit the "Disconnect" button, which still forcibly closes the connection.

What I'm looking for is upon disconnect/closure etc, either "Send x command prior to closing" or "run x script prior to closing"
Reply With Quote
  #6  
Old 02-27-2013, 03:58 PM
rtb rtb is offline
VanDyke Technical Support
 
Join Date: Aug 2008
Posts: 4,306
Hi Joel,

With the option enabled, a user can't close SecureCRT with an active connection or disconnect the active connection unless they run a command in the terminal window or use a script to send the command to the terminal window.

If you haven't tested this, I would suggest doing so to see if it meets your needs.

Is the behavior I have described what you want, or do you actually want the end user to get prompted if they try to close SecureCRT or disconnect with an active connection?

I ask because with the option enabled, they simply can't disconnect or close, but there is no feedback.
__________________
--Todd

VanDyke Software
Technical Support
support@vandyke.com
505-332-5730
Reply With Quote
  #7  
Old 02-27-2013, 04:39 PM
joneill joneill is offline
Registered User
 
Join Date: Oct 2011
Posts: 8
Hi Todd,

I haven't tested the change because that's not what I'm looking for.

- I want people to be able to close SecureCRT in the ways they have been used to previously
- I don't want people to notice any changes in the way it works, especially changes that do not provide any user feedback

I want this to happen automatically, in the background, with no user intervention, or requiring the user to manually run something, select something, choose something etc.

Like I requested in my original post - does SecureCRT run any "closure events" or allow scripts to be automatically run on closure? I want the user to be able to close the program, and the program automatically run a set command/script so I can control what happens at closure.

Thank you.
Reply With Quote
  #8  
Old 02-28-2013, 09:10 AM
rtb rtb is offline
VanDyke Technical Support
 
Join Date: Aug 2008
Posts: 4,306
Hi Joel,

Thanks for the additional clarification. The answer to your question is no. SecureCRT does not have an option to specifically meet your need.

I have created a feature request to add this type of functionality. Should a future release of SecureCRT allow one to run a logout script or force a program closure event, we will post to this thread.

If you would like to be notified directly, please complete and submit the form at the following location:
Submit Feature Request
__________________
--Todd

VanDyke Software
Technical Support
support@vandyke.com
505-332-5730
Reply With Quote
  #9  
Old 02-28-2013, 03:45 PM
joneill joneill is offline
Registered User
 
Join Date: Oct 2011
Posts: 8
Hi Todd,

Thanks for the response - I'll have to think of something else then.

Thanks for the feature request - I'll look again in the coming months.

Regards,
Joel
Reply With Quote
  #10  
Old 03-01-2013, 08:15 AM
rtb rtb is offline
VanDyke Technical Support
 
Join Date: Aug 2008
Posts: 4,306
You are welcome Joel.

In the meantime (which is of indeterminate length), the option to force a user to cleanly exit a system does exist.
__________________
--Todd

VanDyke Software
Technical Support
support@vandyke.com
505-332-5730
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -6. The time now is 06:51 AM.