View Single Post
Old 09-17-2020, 09:57 AM
Rhudi's Avatar
Rhudi Rhudi is offline
Registered User
Join Date: Jul 2013
Location: Greenville, SC
Posts: 90
ad-hoc session 'Custom log data'?

Is it possible to set "Custom log data" ('On each line') using VB?

I know how to create a log file (and even append if needed).

Currently, I do things like this (variables are set appropriately):
crt.Session.LogFileName =  UserProf & "\SecureCRT Logs\" & UserName & "\%Y-%M-%D.%h.%m - " & strShortHostName & " -- (" & UserName & ").log"
crt.Session.Log True
In other code that works, I can create/write a file that has my "Connect Banner" (Which is a bit more detailed than what is provided in logfile options).
Then, close that file and use it as a LogFileName with 'append'.
When I'm done, I close the LogFile, then open 'ForAppending' to write my custom disconnect footer.

The only option I'd really like is to be able to set through VB is "On each line".