Page 1 of 1 1
Topic Options
#212110 - 2016-11-15 02:28 PM open a simpel dialog in the user session
mbrecht Offline
Fresh Scripter

Registered: 2003-03-14
Posts: 17
Loc: Jockgrim, Germany, EU
With msg.exe i can send a dialog box with some text to the users on the system from a script that's run in the local system context. But there are no way to give the user the choice to response "Ok" OR "Cancel".

Any ideas to solve the problem?

Top
#212111 - 2016-11-15 03:00 PM Re: open a simpel dialog in the user session [Re: mbrecht]
Mart Moderator Offline
KiX Supporter
*****

Registered: 2002-03-27
Posts: 4673
Loc: The Netherlands
Something like this works for me.

 Code:
;Show messagebox("Message", "Title", Style). Style is a combination of Yes and No (4) and Questionmark (32).
$click = MessageBox("Are you OK?", "Question", 36)

;Clicking Yes returns 6 and No returns 7.
If $click = "6"
	;Show message on screen.
	? "You clicked Yes"
Else
	;Show message on screen.
	? "You clicked No"
EndIf

Sleep 5
_________________________
Mart

- Chuck Norris once sold ebay to ebay on ebay.

Top
#212118 - 2016-11-15 06:11 PM Re: open a simpel dialog in the user session [Re: Mart]
mbrecht Offline
Fresh Scripter

Registered: 2003-03-14
Posts: 17
Loc: Jockgrim, Germany, EU
Sorry, but this don't work. The user on the console or inside a remote desktop session don't see this message box because the script run in the SYSTEM context not in the user context.
Top
Page 1 of 1 1


Moderator:  Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart 
Hop to:
Shout Box

Who's Online
0 registered and 837 anonymous users online.
Newest Members
M_Moore, BeeEm, min_seow, Audio, Hoschi
17883 Registered Users

Generated in 0.154 seconds in which 0.132 seconds were spent on a total of 13 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org