Procedure editor commands

Thanks Carl,

That worked great!

Jasper

-----Original Message-----
From: vantage@yahoogroups.com [mailto:vantage@yahoogroups.com]On Behalf Of Carl Peterson
Sent: Friday, March 28, 2008 8:28 AM
To: vantage@yahoogroups.com
Subject: RE: [Vantage] Re: Procedure editor commands



Jasper:

The parameters cannot contain spaces or the program will abort.

Listed below is information from Progress on the -param statement. The
passed parameters need to be parsed in the receiving program. This
technique can be used to execute your Vantage 6.1 reporter files.

Good luck,

Carl Peterson

1-734-453-3101
Plymouth, Michigan


ID: 19124
Title: "How To Pass Parameters From The Command Line ( -param )"

Created: 09/13/1999
Last Modified: 01/25/2008

Status: Verified

Goals:
. How to use the -param Session Parameter with a list of entries?
. Session Parameter -param and entry list
. Using the -param parameter to refer to a list of values
. Passing a single character string with -param
. Passing a parameter containing spaces with -param
. Converting the character parameter to another data type with -param
. How to pass parameters from the command line (using -param ) to 4GL
. This technique can be used to pass parameters to a Progress application
that needs to behave differently based on some few parameters, or batch
programs that needs parameters.
. How to use -param?
. Can a startup procedure have parameters?
. How to deal with -param value in the code?
. What is the -param startup option?
. How to pass parameters from the command line ( -param )

Facts:
. All Supported Operating Systems
. Progress 8.x
. Progress 9.x
. OpenEdge 10.x




Fixes:
This Solution describes how to pass parameters to Progress from the command
line to a 4GL program.
This technique can be used to pass parameters to a Progress application that
needs to behave differently based on some few parameters, or batch programs
that needs parameters.

The -param parameter can be used to pass a character string to a Progress
session.
The SESSION:PARAMETER attribute can be used to access this character string.

This character string can be converted to another data type or parser as
required by the application.

The -param parameter can be used with any Progress client, examples:
- prowin32 -p pp.p -param test
- _progres -p pp.p -param test
- pro -p pp.p -param test
- mpro -p pp.p -param test
- bpro -p pp.p -param test
- mbpro -p pp.p -param test

Example of usages:

1) Passing a single character string:

- prowin32 -p pp.p -param test

- Test program (pp1.p)
DISPLAY "The parameter is:" SKIP SESSION:PARAMETER FORMAT "X(70)".
PAUSE.
QUIT.

2) Passing a parameter containing spaces:

- prowin32 -p pp1.p -param "test abc"

- Test program (pp.p)
DISPLAY "The parameter is:" SKIP SESSION:PARAMETER FORMAT "X(70)".
PAUSE.
QUIT.

3) Converting the character parameter to another data type

- prowin32 -p pp1.p -param 1024

- Test program (pp.p)
DISPLAY "The result of the parameter + 70 is:" SKIP
INTEGER(SESSION:PARAMETER) + 70.
PAUSE.
QUIT.

4) Using the -param parameter to refer to a list of values

- prowin32 -p pp1.p -param abc,xyz,123,789

- Test program (pp.p)
DEF VAR c AS CHAR.
DEF VAR i AS INT.

c = SESSION:PARAMETER.
DISPLAY "The parameter is:" SKIP
c FORMAT "X(70)" SKIP
"The number of entries is:" NUM-ENTRIES(c).
REPEAT i = 1 TO NUM-ENTRIES(c):
DISPLAY "Entry: " I " is " ENTRY(I, c).
END.
PAUSE.
QUIT.

Notes:
The client parameter -param can also be used to specify one or more files to
load into the Procedure Editor buffers when starting Progress.
Therefore, if the -param value does not correspond to a file or you do not
want the Procedure Editor to load, you can use the QUIT statement so the
program will finish without opening the Procedure Editor.
References to Written Documentation:
OpenEdge Deployment: Startup Command and Parameter Reference, "Parameter
(-param)" entry
OpenEdge Development: ABL Reference, "PARAMETER attribute" entry



From: vantage@yahoogroups.com<mailto:vantage%40yahoogroups.com> [mailto: vantage@yahoogroups.com<mailto:vantage%40yahoogroups.com>] On Behalf Of
locper99
Sent: Thursday, March 27, 2008 2:42 PM
To: vantage@yahoogroups.com<mailto:vantage%40yahoogroups.com>
Subject: [Vantage] Re: Procedure editor commands

Michael, What format does the parameters have to be?

After my statement, I put this in:

-param Loc, 17000, 10

These paramaters are the Company, Job number, and Operation.

I get an error stating that it can't identify 17000. No matter what
I do, it can't identify any thing after the first paramter.

Any suggestions?

Thanks,
Jasper

--- In vantage@yahoogroups.com<mailto:vantage%40yahoogroups.com> <mailto:vantage%40yahoogroups.com> , "Podlin,
Michael"
<michael.podlin@...> wrote:
>
> you can use -param in the command line to pass variables to the .p
procedure.
>
> -----Original Message-----
> From: vantage@yahoogroups.com<mailto:vantage%40yahoogroups.com> <mailto:vantage%40yahoogroups.com>
[mailto: vantage@yahoogroups.com<mailto:vantage%40yahoogroups.com> <mailto:vantage%40yahoogroups.com> ]On
Behalf Of Jasper Recto
> Sent: Tuesday, March 25, 2008 12:35 PM
> To: Vantage Groups (E-mail)
> Subject: [Vantage] Procedure editor commands
>
>
>
> A while back ago, somebody gave me this command to lauchr report
builder reports using .p files from a script.
>
> "V:\PRGS91D\bin\prowin32.exe V:\MFGSYS61\db\mfgsys.db -ininame
V:\MFGSYS61\mfgsys.ini -pf V:\MFGSYS61\db\mfgsys.pf -N TCP -H loc-
vntg -S 6100 -ld MFGSYS -p v:\Report Procedures\Production\OpenJobs.p"
>
> The .p file would have any report filter embedded in it. Does
anybody now if it's possible to pass the report filter in the command
line itself?
>
> Thanks,
>
> Jasper
>
> [Non-text portions of this message have been removed]
>
>
>
>
>
>
>
> [Non-text portions of this message have been removed]
>


[Non-text portions of this message have been removed]







[Non-text portions of this message have been removed]
A while back ago, somebody gave me this command to lauchr report builder reports using .p files from a script.

"V:\PRGS91D\bin\prowin32.exe V:\MFGSYS61\db\mfgsys.db -ininame V:\MFGSYS61\mfgsys.ini -pf V:\MFGSYS61\db\mfgsys.pf -N TCP -H loc-vntg -S 6100 -ld MFGSYS -p v:\Report Procedures\Production\OpenJobs.p"

The .p file would have any report filter embedded in it. Does anybody now if it's possible to pass the report filter in the command line itself?

Thanks,

Jasper



[Non-text portions of this message have been removed]
you can use -param in the command line to pass variables to the .p procedure.

-----Original Message-----
From: vantage@yahoogroups.com [mailto:vantage@yahoogroups.com]On Behalf Of Jasper Recto
Sent: Tuesday, March 25, 2008 12:35 PM
To: Vantage Groups (E-mail)
Subject: [Vantage] Procedure editor commands



A while back ago, somebody gave me this command to lauchr report builder reports using .p files from a script.

"V:\PRGS91D\bin\prowin32.exe V:\MFGSYS61\db\mfgsys.db -ininame V:\MFGSYS61\mfgsys.ini -pf V:\MFGSYS61\db\mfgsys.pf -N TCP -H loc-vntg -S 6100 -ld MFGSYS -p v:\Report Procedures\Production\OpenJobs.p"

The .p file would have any report filter embedded in it. Does anybody now if it's possible to pass the report filter in the command line itself?

Thanks,

Jasper

[Non-text portions of this message have been removed]







[Non-text portions of this message have been removed]
Michael, What format does the parameters have to be?

After my statement, I put this in:

-param Loc, 17000, 10

These paramaters are the Company, Job number, and Operation.

I get an error stating that it can't identify 17000. No matter what
I do, it can't identify any thing after the first paramter.

Any suggestions?

Thanks,
Jasper


--- In vantage@yahoogroups.com, "Podlin, Michael"
<michael.podlin@...> wrote:
>
> you can use -param in the command line to pass variables to the .p
procedure.
>
> -----Original Message-----
> From: vantage@yahoogroups.com [mailto:vantage@yahoogroups.com]On
Behalf Of Jasper Recto
> Sent: Tuesday, March 25, 2008 12:35 PM
> To: Vantage Groups (E-mail)
> Subject: [Vantage] Procedure editor commands
>
>
>
> A while back ago, somebody gave me this command to lauchr report
builder reports using .p files from a script.
>
> "V:\PRGS91D\bin\prowin32.exe V:\MFGSYS61\db\mfgsys.db -ininame
V:\MFGSYS61\mfgsys.ini -pf V:\MFGSYS61\db\mfgsys.pf -N TCP -H loc-
vntg -S 6100 -ld MFGSYS -p v:\Report Procedures\Production\OpenJobs.p"
>
> The .p file would have any report filter embedded in it. Does
anybody now if it's possible to pass the report filter in the command
line itself?
>
> Thanks,
>
> Jasper
>
> [Non-text portions of this message have been removed]
>
>
>
>
>
>
>
> [Non-text portions of this message have been removed]
>
Jasper:

The parameters cannot contain spaces or the program will abort.

Listed below is information from Progress on the -param statement. The
passed parameters need to be parsed in the receiving program. This
technique can be used to execute your Vantage 6.1 reporter files.

Good luck,

Carl Peterson

1-734-453-3101
Plymouth, Michigan


ID: 19124
Title: "How To Pass Parameters From The Command Line ( -param )"

Created: 09/13/1999
Last Modified: 01/25/2008

Status: Verified



Goals:
. How to use the -param Session Parameter with a list of entries?
. Session Parameter -param and entry list
. Using the -param parameter to refer to a list of values
. Passing a single character string with -param
. Passing a parameter containing spaces with -param
. Converting the character parameter to another data type with -param
. How to pass parameters from the command line (using -param ) to 4GL
. This technique can be used to pass parameters to a Progress application
that needs to behave differently based on some few parameters, or batch
programs that needs parameters.
. How to use -param?
. Can a startup procedure have parameters?
. How to deal with -param value in the code?
. What is the -param startup option?
. How to pass parameters from the command line ( -param )



Facts:
. All Supported Operating Systems
. Progress 8.x
. Progress 9.x
. OpenEdge 10.x






Fixes:
This Solution describes how to pass parameters to Progress from the command
line to a 4GL program.
This technique can be used to pass parameters to a Progress application that
needs to behave differently based on some few parameters, or batch programs
that needs parameters.

The -param parameter can be used to pass a character string to a Progress
session.
The SESSION:PARAMETER attribute can be used to access this character string.

This character string can be converted to another data type or parser as
required by the application.


The -param parameter can be used with any Progress client, examples:
- prowin32 -p pp.p -param test
- _progres -p pp.p -param test
- pro -p pp.p -param test
- mpro -p pp.p -param test
- bpro -p pp.p -param test
- mbpro -p pp.p -param test

Example of usages:

1) Passing a single character string:

- prowin32 -p pp.p -param test

- Test program (pp1.p)
DISPLAY "The parameter is:" SKIP SESSION:PARAMETER FORMAT "X(70)".
PAUSE.
QUIT.

2) Passing a parameter containing spaces:

- prowin32 -p pp1.p -param "test abc"

- Test program (pp.p)
DISPLAY "The parameter is:" SKIP SESSION:PARAMETER FORMAT "X(70)".
PAUSE.
QUIT.

3) Converting the character parameter to another data type

- prowin32 -p pp1.p -param 1024

- Test program (pp.p)
DISPLAY "The result of the parameter + 70 is:" SKIP
INTEGER(SESSION:PARAMETER) + 70.
PAUSE.
QUIT.

4) Using the -param parameter to refer to a list of values

- prowin32 -p pp1.p -param abc,xyz,123,789

- Test program (pp.p)
DEF VAR c AS CHAR.
DEF VAR i AS INT.

c = SESSION:PARAMETER.
DISPLAY "The parameter is:" SKIP
c FORMAT "X(70)" SKIP
"The number of entries is:" NUM-ENTRIES(c).
REPEAT i = 1 TO NUM-ENTRIES(c):
DISPLAY "Entry: " I " is " ENTRY(I, c).
END.
PAUSE.
QUIT.



Notes:
The client parameter -param can also be used to specify one or more files to
load into the Procedure Editor buffers when starting Progress.
Therefore, if the -param value does not correspond to a file or you do not
want the Procedure Editor to load, you can use the QUIT statement so the
program will finish without opening the Procedure Editor.
References to Written Documentation:
OpenEdge Deployment: Startup Command and Parameter Reference, "Parameter
(-param)" entry
OpenEdge Development: ABL Reference, "PARAMETER attribute" entry



From: vantage@yahoogroups.com [mailto:vantage@yahoogroups.com] On Behalf Of
locper99
Sent: Thursday, March 27, 2008 2:42 PM
To: vantage@yahoogroups.com
Subject: [Vantage] Re: Procedure editor commands

Michael, What format does the parameters have to be?

After my statement, I put this in:

-param Loc, 17000, 10

These paramaters are the Company, Job number, and Operation.

I get an error stating that it can't identify 17000. No matter what
I do, it can't identify any thing after the first paramter.

Any suggestions?

Thanks,
Jasper

--- In vantage@yahoogroups.com <mailto:vantage%40yahoogroups.com> , "Podlin,
Michael"
<michael.podlin@...> wrote:
>
> you can use -param in the command line to pass variables to the .p
procedure.
>
> -----Original Message-----
> From: vantage@yahoogroups.com <mailto:vantage%40yahoogroups.com>
[mailto:vantage@yahoogroups.com <mailto:vantage%40yahoogroups.com> ]On
Behalf Of Jasper Recto
> Sent: Tuesday, March 25, 2008 12:35 PM
> To: Vantage Groups (E-mail)
> Subject: [Vantage] Procedure editor commands
>
>
>
> A while back ago, somebody gave me this command to lauchr report
builder reports using .p files from a script.
>
> "V:\PRGS91D\bin\prowin32.exe V:\MFGSYS61\db\mfgsys.db -ininame
V:\MFGSYS61\mfgsys.ini -pf V:\MFGSYS61\db\mfgsys.pf -N TCP -H loc-
vntg -S 6100 -ld MFGSYS -p v:\Report Procedures\Production\OpenJobs.p"
>
> The .p file would have any report filter embedded in it. Does
anybody now if it's possible to pass the report filter in the command
line itself?
>
> Thanks,
>
> Jasper
>
> [Non-text portions of this message have been removed]
>
>
>
>
>
>
>
> [Non-text portions of this message have been removed]
>



[Non-text portions of this message have been removed]