View previous topic :: View next topic
|
Author |
Message |
lohithegde
New User
Joined: 18 May 2008 Posts: 31 Location: Chennai
|
|
|
|
I want to open an PDS in View and browse and Edit mode....but I'm able to open in only one mode
"ISPEXEC EDIT DATASET('OurID.PDS')"
but above command only open dataset in edit mode...we can't open the members in view/browse mode. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Try ISPEXEC BROWSE - EDIT means edit. |
|
Back to top |
|
|
lohithegde
New User
Joined: 18 May 2008 Posts: 31 Location: Chennai
|
|
|
|
do u mean ADDRESS ISPEXEC "BROWSE - EDIT DATASET('ID.PDS')"
but it is giving the rerror
Invalid keyword
'-' is not a valid keyword for this service.
My reqirement is to open a PDS in all opening modes (EDIT/BROWSE/View) |
|
Back to top |
|
|
PeD
Active User
Joined: 26 Nov 2005 Posts: 459 Location: Belgium
|
|
|
|
No
ADDRESS
"ISPFEXEC BROWSE DATASET(pds(member))"
or
"ISPFEXEC VIEW DATASET(pds(member))" |
|
Back to top |
|
|
lohithegde
New User
Joined: 18 May 2008 Posts: 31 Location: Chennai
|
|
|
|
ADDRESS
"ISPFEXEC BROWSE DATASET(pds)"
or
Address
"ISPFEXEC VIEW DATASET(pds)"
above method only open a dataset in Edit or Browse mode...Let us say If we open a dtaset in browse mode...it can not be viewed...
My reqirement is I want to open Just like 3.4 option like it can viewed or Browse or edited depending on the B/E/V what we specify infront of the PDS member
EX:
VIEW YOURID.PDS
Command ===>
Name
V/B/E________ PDSMEM |
|
Back to top |
|
|
PeD
Active User
Joined: 26 Nov 2005 Posts: 459 Location: Belgium
|
|
|
|
Quote: |
ADDRESS
"ISPFEXEC BROWSE DATASET(pds)"
or
Address
"ISPFEXEC VIEW DATASET(pds)"
above method only open a dataset in Edit or Browse mode...Let us say If we open a dtaset in browse mode...it can not be viewed...
|
open in Browse or View mode, not , as you said, Edit or Browse mode !!!
Execpt this, I don't understand your requirement now. Sorry |
|
Back to top |
|
|
lohithegde
New User
Joined: 18 May 2008 Posts: 31 Location: Chennai
|
|
|
|
Oh Sorry Brother....
Let us say I opened the dataset using Following Rexx code
ADDRESS
"ISPFEXEC BROWSE DATASET(pds)"
Output will be
BROWSE MYID.PDS Row 00001 of 00002
Command ===> Scroll ===> CSR
Name Prompt Size Created Changed ID
. MEM1
. Mem2
If you Put V infront of Member then we will get
BROWSE MYID.PDS Invalid select codeCommand ===> Scroll ===> CSR
Name Prompt Size Created Changed ID
V MEM1
. Mem2
My reqirement is If we put V it should open in View mode...if we put B it should open in browse mode...if E -->edit mode
But Normal REXX code will open in either in view or in browse or in EDIT
I want All should work
Thanks |
|
Back to top |
|
|
ofer71
Global Moderator
Joined: 27 Dec 2005 Posts: 2358 Location: Israel
|
|
|
|
You can open a dataset only in one mode at a time.
You can code something like this:
Code: |
/* REXX */
ARG DSNAME MODE .
SELECT
WHEN MODE = 'B' THEN
ADDRESS ISPEXEC "BROWSE DATASET(&DSNAME)"
WHEN MODE = 'V' THEN
ADDRESS ISPEXEC "VIEW DATASET(&DSNAME)"
WHEN MODE = 'E' THEN
ADDRESS ISPEXEC "EDIT DATASET(&DSNAME)"
OTHERWISE
NOP
END
EXIT |
O. |
|
Back to top |
|
|
PeD
Active User
Joined: 26 Nov 2005 Posts: 459 Location: Belgium
|
|
|
|
OK I see what you want ( as Ofer71 said ).
Why do you have to change your mind between the two commands?
You start browsing , stay browsing....
Is there a specific need to change?
Cheers
Pierre |
|
Back to top |
|
|
ofer71
Global Moderator
Joined: 27 Dec 2005 Posts: 2358 Location: Israel
|
|
|
|
Regarding switching - remember that BROWSE/VIEW/EDIT are also an ISPF Edit-Macro commands (in addition to the above ISPF Services), so you can issue them from within an edit-macro (ISREDIT),thus switching between modes.
O. |
|
Back to top |
|
|
lohithegde
New User
Joined: 18 May 2008 Posts: 31 Location: Chennai
|
|
|
|
Hi
I want to Develop a REXX tool it will overome a drawbacks of 3.4 option
Requirement:
1 It should show last 10 Viewed/browsed/Edited dataset
2 It should have all features of 3.4 option Like
i/p in 3.4 :-YOURID.**.*
o/p :-all datasets
My reqirement is If we put V it should open in View mode...if we put B it should open in browse mode...if E -->edit mode
please anybody knows let me now |
|
Back to top |
|
|
ofer71
Global Moderator
Joined: 27 Dec 2005 Posts: 2358 Location: Israel
|
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10872 Location: italy
|
|
|
|
I just checked... from option 3.4
after selecting in ANY(browse,view,edit) mode a dataset
You can use any from any member command ( even delete )only if You have activated
Code: |
Enhanced member list for Edit, View, and Browse |
Quote: |
... It should show last 10 Viewed/browsed/Edited dataset |
ever heard about DSLIST, REFLIST and friends |
|
Back to top |
|
|
Pedro
Global Moderator
Joined: 01 Sep 2006 Posts: 2546 Location: Silicon Valley
|
|
|
|
I think the poster wants the member list service.
Code: |
/*REXX*/
DSN = 'PEDRO.JCL.CNTL'
Address ISPEXEC
"LMINIT DATAID(DID) DATASET('"DSN"') ENQ(SHRW)"
"LMOPEN DATAID("did")"
"MEMLIST DATAID("did") CONFIRM(YES)"
"LMFREE DATAID("did")" |
Which provides a member list and where you can issue B, E, or V line commands (or other line commands). |
|
Back to top |
|
|
Pedro
Global Moderator
Joined: 01 Sep 2006 Posts: 2546 Location: Silicon Valley
|
|
|
|
Regarding:
Quote: |
I want to Develop a REXX tool it will overome a drawbacks of 3.4 option
Requirement:
1 It should show last 10 Viewed/browsed/Edited dataset |
Try ISPF option 11 - the 'ISPF workplace'. It is very much like ISPF 3.4, but the name rules are slightly different and you can recall the last 30 names. And you can create your own list of names, so you can save many more names than the 10 you want.
-or- perhaps what you want is to change one of your keys to be NRETRIEV when you are in the ISPF 'edit entry panel' (where you provide name of dataset). Press the key repeatedly and it will retrieve the previously used names. Also works from View and from option 3.4 |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Quote: |
Try ISPF option 11 - the 'ISPF workplace'. |
Might this be some add-on product? |
|
Back to top |
|
|
Pedro
Global Moderator
Joined: 01 Sep 2006 Posts: 2546 Location: Silicon Valley
|
|
|
|
Surprise! You thought you knew everything about ISPF and then you find there is a whole other option! It has been there for several releases.
The ISPF Workplace is documented in ISPF User's Guide, vol 2.
If your ISPF panel does not have it, try ISPFWORK in the command line or make your own:
Code: |
/*rexx */
Addres ISPEXEC "SELECT PGM(ISRUDA) PARM(ISRWORK) SCRNAME(WORK)" |
|
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello Pedro,
Quote: |
You thought you knew everything about ISPF |
Not really, i use it fairly often, but am no expert.
Quote: |
and then you find there is a whole other option! |
Seems like our system support people left it off the menu. ISPFWORK brings it up, though.
Something new to look into, thanks
d |
|
Back to top |
|
|
genesis786
Active User
Joined: 28 Sep 2005 Posts: 210 Location: St Katherine's Dock London
|
|
|
|
hi Pedro.. sorry, continuing in the old topic...
is there a way we can invoke a macro after MEMLIST, e.g. to sort the list with userid... etc... |
|
Back to top |
|
|
Pedro
Global Moderator
Joined: 01 Sep 2006 Posts: 2546 Location: Silicon Valley
|
|
|
|
Not really a macro, but with some trickery, you can issue one sort command.
Novices, please avert your eyes.
1. rexx program. Notice the 'mysort' variable. and the use of CONTROL service, and also the use of a customized panel.
Code: |
/*REXX*/
DSN = 'PEDRO.JCL.CNTL'
Mem = 'ADR*'
Address ISPEXEC
"LMINIT DATAID(DID) DATASET('"DSN"') ENQ(SHRW)"
"LMOPEN DATAID("did")"
mysort = 'SORT CREATED'
"CONTROL NONDISPL ENTER"
"MEMLIST DATAID("did") CONFIRM(YES) MEMBER("Mem") PANEL(PSVUDSM)"
"LMFREE DATAID("did")" |
2. a customized panel, based on ISRUDSM panel of ISPF.
add as first part of )init section, set the zcmd variable:
Code: |
)INIT
IF (&MYSORT NE &Z)
&ZCMD = &MYSORT |
and add as last line of )PROC, blank out the variable
So this is what happens:
* member list is displayed (not really) with your sort command at top
* because of previous CONTROL NONDISPL ENTER command, the sort is processed before you see the member list.
* when you finally see the list, your sort command has been processed. |
|
Back to top |
|
|
genesis786
Active User
Joined: 28 Sep 2005 Posts: 210 Location: St Katherine's Dock London
|
|
|
|
great! thanks.. |
|
Back to top |
|
|
|