VanDyke Software Forums

VanDyke Software Forums (
-   Scripting (
-   -   Reloading the session list (

ogun 11-08-2016 07:03 AM

Reloading the session list

We've written a script that we've used for some years now that fetches a session list from an external host and then creates sessions from there.
The scripts first deletes a folder "Shared" in the session directory on the client and then creates new sessions from the list by cloning the default session and saving.

We then run the script as a login script when connecting to our jump host.
The issue is that after the sessions are created, new session do not show up until you restarts SecureCRT. Is there any API call that I can use to tell scrt to reload the session database?

jdev 11-08-2016 10:48 AM

There isn't a direct API for refreshing the session manager's contents.

You can refresh it manually by closing and re-opening your Session Manager (not just auto-hiding it).

Perhaps this snippet of code might work, but I think it would require a script tab that is connected to a remote host.



ogun 11-11-2016 10:11 AM

Many thanks, that did the trick.

I will try and post my code on github later to share with everybody.

Maureen 12-05-2016 12:05 PM

The scripting API has been modified so that the Session Manager is automatically refreshed when a new session is added through a script. This support is available in SecureCRT 8.1, which is in beta testing. If you'd like to try it, please send email to me at


All times are GMT -6. The time now is 03:30 AM.