| TIP: Click on subject to list as thread! | ANSI |
| echo: | |
|---|---|
| to: | |
| from: | |
| date: | |
| subject: | Re: Beggar Needs Program |
From: "Gary Britt"
I played around with your script and made these modifications so it would
take two arguments. The first is the message text and the second is the
window title text. Remember I have no idea what I'm doing but this works
and formats the message box more to my liking (wink).
>>>Say.vbs<<<<
set args = wscript.arguments
if args.count > 0 then
msgbox args(0) + " ", vbinformation, args(1)
end if
>>>Say.vbs<<<<
And I dug this out of some .js file that comes with windows (yours is more
elegant). This will run outside of a browser:
>>>>>>Say.js<<<<<<<
var vbOKCancel = 0 // Use 1 here To get two buttons OK, Cancel; 2 gives you
three buttons, Abort, Retry, Ignore; 3 gives you three buttons, Yes, No,
Cancel;
var vbInformation = 64;
var vbCancel = 2;
var L_Welcome_MsgBox_Message_Text = "Put Message Text Here";
var L_Welcome_MsgBox_Title_Text = "Put Title Of Pop-up Window Here";
//
// Call Message Box Function
//
Welcome();
////////////////////////////////////////////////////////////////////////////
//////
//
// Message Box Function
//
function Welcome() {
var WSHShell = WScript.CreateObject("WScript.Shell");
var intDoIt;
intDoIt = WSHShell.Popup(L_Welcome_MsgBox_Message_Text,
0,
L_Welcome_MsgBox_Title_Text,
vbOKCancel + vbInformation );
if (intDoIt == vbCancel) {
WScript.Quit();
}
}
>>>>>>Say.js<<<<<<<
"Gregg N" wrote in message
news:43120fde$1{at}w3.nls.net...
> Frank Haber wrote:
>
> > Very nice, but I have this (possibly wrong) idea that I need to keep
> > the call chain as simple as possible. No browser=simpler.
>
> You can also use the attached vbscript to pop up a message box. Just run
> it from a command line the way you would msg.exe. The only difference
> from the msg.exe program is that if the message contains spaces, it must
> be enclosed in quotation marks.
>
> It should run under w2k and XP. I don't remember if 98 comes with
> vbscript support.
>
> Gregg
>
>
----------------------------------------------------------------------------
----
> set args = wscript.arguments
>
> if args.count > 0 then
> msgbox args(0), vbinformation, "Message"
> end if
>
--- BBBS/NT v4.01 Flag-5
* Origin: Barktopia BBS Site http://HarborWebs.com:8081 (1:379/45)SEEN-BY: 633/267 270 5030/786 @PATH: 379/45 1 106/2000 633/267 |
|
| SOURCE: echomail via fidonet.ozzmosis.com | |
Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.