Switching User Script

I am trying to switch users in the client via the system.security.switchuser script. I apply this script to an action performed event on a push button.

uname = event.source.parent.getComponent(“Username”).text

pwd = event.source.parent.getComponent(“Password”).text

success= system.security.switchUser(uname,pwd,event)

if not success:

event.source.parent.getComponent(“Username”).requestFocusInWindow()

this is the example code snippet from the online manual. The runtime seems to lock up when I press the button. the system console on the gateway says it is removing tags due to switching user. the client remains frozen for about 4-5 minutes then closes on its own.

any help would be greatly appreciated.

I’ve dug around in my application and I have found these 2 “invalid action adapter found on group. removing” text lines in my java console when I startup my client. I believe this may be causing the hangup on logging out / switching users in my client. I am running version 7.8. I have tested my switch user and logout on an empty application and it preforms almost instantly. I have attached a picture of the java console.

did you ever figure it out