[jawsscripts] Using Virtual Viewer right after DlgSelectItemInList

Hi folks,
I'm trying to give the user the choice of selecting an item using 
DlgSelectItemInList and then displaying the related details in Virtual Viewer.
The problem is that once I add the text to the user buffer and try to activate, 
it shows up for a second and the gets closed.
If I put several pauses after adding text and before activating the buffer, 
virtual viewer shows up and stays.
Dependency on pauses is what I would like to avoid.
Any advice would be highly appreciated.
(The sample code comes below)
 
Thanks,
 
Kamil
 
Let result = DlgSelectItemInList("Word1|Word2", "Glossary", TRUE, 1)
If result == 1 Then
UserBufferClear()
UserBufferAddText("blah blah blah")
UserBufferAddText("blah blah blah")
Pause() Pause() Pause() Pause() Pause() 
UserBufferActivate()
EndIf
 
 
_________________________________________________________________
News, entertainment and everything you care about at Live.com. Get it now!
http://www.live.com/getstarted.aspx

__________ 
View the list's information and change your settings at 
http://www.freelists.org/list/jawsscripts

Other related posts: