: Chauhan, Savita [EMAIL PROTECTED]
To: u2-users@listserver.u2ug.org
Sent: Thursday, February 03, 2005 9:09 AM
Subject: RE: [U2] [AD] UniBasic Program with arguments
That's a good idea if the program doesn't have return arguments.
-Original Message-
From: [EMAIL PROTECTED]
[mailto
Constant.
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Mark Johnson
Sent: Wednesday, February 02, 2005 8:18 AM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] [AD] UniBasic Program with arguments
Here it is, pretty quickly.
Create a Databasic Program, I
: Re: [U2] [AD] UniBasic Program with arguments
Well,
actually you can, sort of :
LIST VOC SAMPLE 1 EVAL SUBR('your.subroutine', arg1 , arg2 )
Then we can argue forever if this is really running from TCl
or what. ;^)
And IIRC this has been mentioned on the list before.
-- mats
] On Behalf Of Mats Carlid
Sent: 03 February 2005 10:22
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] [AD] UniBasic Program with arguments
Well,
actually you can, sort of :
LIST VOC SAMPLE 1 EVAL SUBR('your.subroutine', arg1 , arg2 )
Then we can argue forever if this is really running from TCl
Clever but not quite there...
That would only work if the subroutine used arg 1 as a return argument.
the orig. post was to run subroutine from command line ???
exactly what does the user expect this subroutine to do ???
This e-mail, including attachments, may include confidential and/or
@listserver.u2ug.org
Subject: RE: [U2] [AD] UniBasic Program with arguments
Thanks all you guys for all your replies.
This list has come to my rescue so many times. I have so much more to
learn.
I realized that I can run my program (with args) only as one of the
following (without any external utitlity) :
1
This is actually pretty simple in UniData - UniBasic. The call to
'SYSTEM(17)' tells you whether you're running from the command line or
as a called routine. Here's a program I wrote along these lines.
SUBROUTINE GET.UDT.OPTION(RES, OPTNO)
* GET.UDT.OPTION - Get the value of one specific
Here it is, pretty quickly.
Create a Databasic Program, I call mine PRINT (losing regard for PRINT being
there). That is a simple program that takes the @COMMAND or PROCREAD or
TCLREAD line you just typed as the first line in a Basic program, throw an
END at the end, compile and run itself.
In short - you can't.
That is, you need to call it from another program... something like...
0001: CALL XYZ (ARG1, ARG2)
0002: END
Depending upon how you have written this routine it may be possible to
call it from a Dictionary item also but that is for another e-mail.
Cheers
Trevor Ockenden
Trevor: You gave up too easily. See my posts on PRINT that I've been using
for over 20 years.
My 1 cent
- Original Message -
From: Trevor Ockenden [EMAIL PROTECTED]
To: u2-users@listserver.u2ug.org
Sent: Wednesday, February 02, 2005 10:51 PM
Subject: RE: [U2] [AD] UniBasic Program
@listserver.u2ug.org
Subject: RE: [U2] [AD] UniBasic Program with arguments
Thanks all you guys for all your replies.
This list has come to my rescue so many times. I have so much more to
learn.
I realized that I can run my program (with args) only as one of the
following (without any external utitlity) :
1
You'll have to write a wrapper that translates the two command line
parameters into subroutine arguments.
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Chauhan,
Savita
Sent: Tuesday, February 01, 2005 3:48 PM
To: u2-users@listserver.u2ug.org
Subject:
You can not run it directly from the command prompt. There were a
number of options that were given in this list not that long ago that
would let you test external subroutines but they all require some kind
of priming process.
BobW
-Original Message-
From: [EMAIL PROTECTED]
Hi, Savita. I presume you mean running the program from TCL (:), the U2
command prompt.
In UniData there are two built-in variables, synonyms actually, named
@SENTENCE and @COMMAND. These contain the raw command line used to
invoke your subroutine.
I usually TRIM this (to eliminate multiple
Of Cliff Bennett
Sent: Tuesday, February 01, 2005 4:05 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] [AD] UniBasic Program with arguments
Hi, Savita. I presume you mean running the program from TCL (:), the
U2
command prompt.
In UniData there are two built-in variables, synonyms
15 matches
Mail list logo