0
Not a bug

5.4.9675.5750 - Host / Session.Host Variables not working

Georg Leitner 3 years ago updated 3 years ago 5

when using the Host Variable for Filtering Session Groups (we only have Access Sessions) or Subgroup Expressions, it is not working.


Also when i have a trigger like this:


Event Filter: Event.EventType = 'Connected'

Subjet: [SC] User '{Session.Host}' has connected to '{Session.Name}'



i only get a empty Session Host back: [SC] User '' has connected to 'ALPHA'

ConnectWise Control Version:
Server Affected:
Host Client Affected:
Guest Client Affected:

Answer

Answer
Not a bug

Since access sessions don't have a host attached to them the way support sessions do, the Host variable will not work the way you want in access session group filtering. If you want to create a session group that contains sessions based on a user's display name, you can do this with a custom property and the $USERNAME variable.


For example, suppose I want the session group "My Sessions" to contain all sessions where the session's CustomProperty2 value contains the currently logged in user's display name.


I can use the following access session filter to achieve this:


CustomProperty2 LIKE '*' + $USERNAME +'*'


Suppose I have a user with display name "Frank". When Frank logs into the host page, the "My Sessions" group will contain all access sessions with a CustomProperty2 value containing the string "Frank".


Similarly, if you would like to include the name of the participant that's connecting to an access session as a host in the email subject, your session event trigger definition should look something like this:


Event Filter: Event.EventType = 'Connected' AND Connection.ProcessType = 'Host' AND Session.SessionType = 'Access'


Subject: [SC] User '{Connection.ParticipantName}' has connected to '{Session.Name}'


The Connection.ParticipantName will contain the display name of the user making the connection to the access session.

i have checked, and it also applies to the newest 6.1 stable

Answer
Not a bug

Since access sessions don't have a host attached to them the way support sessions do, the Host variable will not work the way you want in access session group filtering. If you want to create a session group that contains sessions based on a user's display name, you can do this with a custom property and the $USERNAME variable.


For example, suppose I want the session group "My Sessions" to contain all sessions where the session's CustomProperty2 value contains the currently logged in user's display name.


I can use the following access session filter to achieve this:


CustomProperty2 LIKE '*' + $USERNAME +'*'


Suppose I have a user with display name "Frank". When Frank logs into the host page, the "My Sessions" group will contain all access sessions with a CustomProperty2 value containing the string "Frank".


Similarly, if you would like to include the name of the participant that's connecting to an access session as a host in the email subject, your session event trigger definition should look something like this:


Event Filter: Event.EventType = 'Connected' AND Connection.ProcessType = 'Host' AND Session.SessionType = 'Access'


Subject: [SC] User '{Connection.ParticipantName}' has connected to '{Session.Name}'


The Connection.ParticipantName will contain the display name of the user making the connection to the access session.

Hi Ben,


thanks for the information. The trigger works fine now.


for the access sessions. i wanted to have subgroups appearing with the Full Name of the connected Host User. So i have a clear view, of whom is connected to which access sessions. the information is there, i don't want to additionally configure CustomProperties.

currently i have it running with the $username, but the username is cryptic, where as the fullname would be better. e.g. atviedagl - Georg Leitner DA

so now i have a list of some atvieda... but it would be nice to have it stating Georg Leitner DA, as the information is there. i can see it:




should i create a feature request? is it sufficient to link to this site?


georg

Georg,


You could define an access session group to pick out sessions where at least one host is connected, and use the ConnectedParticipantNames variable to dynamically generate the subgroups:



Cheers,

Ben

Ben,

thanks for the information, i tested it in our test 6.1 and production 5.4 and it is only working in 6.1. never the less, this is not a problem, as we will soon update to 6.1 where it should work.


Thanks Ben for the support!

Georg