MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Find Macro returns 4!

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF
View previous topic :: View next topic  
Author Message
sendhil
Beginner


Joined: 06 Sep 2006
Posts: 17
Topics: 6

PostPosted: Mon Sep 18, 2006 7:11 am    Post subject: Find Macro returns 4! Reply with quote

Hi,
I am trying to use the Find command in my edit macro.
"F '*' .ZCSR .ZCSR 7"

The line .ZCSR is pointing to has a '*' in the 7th column.But still the above command returns 4.
I tried running the above command directly on the input file.The cursor is hiliting on the '*' which means that its able to process the command.

Any inputs?

Regards
Sendhil.
Back to top
View user's profile Send private message Send e-mail
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Mon Sep 18, 2006 7:15 am    Post subject: Reply with quote

sendhil,

Is your input file a variable block file ? If so you need to add the RDW(4 bytes) also.

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
sendhil
Beginner


Joined: 06 Sep 2006
Posts: 17
Topics: 6

PostPosted: Mon Sep 18, 2006 7:34 am    Post subject: Reply with quote

kolusu,
I didnt get you.Where to add the 4 bytes?Could u please elaborate?

Thanks
Sendhil.
Back to top
View user's profile Send private message Send e-mail
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Mon Sep 18, 2006 7:41 am    Post subject: Reply with quote

sendhil,

If your input file is a VB file then you need to look for the string in the 11th byte i.e 7 + 4 bytes of rdw

Code:

"F '*' .ZCSR .ZCSR 11"


Hope this helps...

Cheers

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
sendhil
Beginner


Joined: 06 Sep 2006
Posts: 17
Topics: 6

PostPosted: Mon Sep 18, 2006 7:53 am    Post subject: Reply with quote

kolusu,
Nope its not a VB file.Any other workaround?


Regards
Sendhil.
Back to top
View user's profile Send private message Send e-mail
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Mon Sep 18, 2006 8:04 am    Post subject: Reply with quote

Quote:

Nope its not a VB file.Any other workaround?


Put an S besides the file name and tell us the RECFM of the file

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
semigeezer
Supermod


Joined: 03 Jan 2003
Posts: 1014
Topics: 13
Location: Atlantis

PostPosted: Mon Sep 18, 2006 12:02 pm    Post subject: Reply with quote

VB doesn't matter. ISPF does not read the RDW as data. THe problem is more likely that you have line numbers on the left side and ISPF edit macros adjust for that by removing the line number columns when calculating column #s. Try column 1 if you have sequence #s in 1-6
Back to top
View user's profile Send private message Visit poster's website
sendhil
Beginner


Joined: 06 Sep 2006
Posts: 17
Topics: 6

PostPosted: Wed Sep 20, 2006 7:58 am    Post subject: Reply with quote

semigeezer,
No. It is not actually having line numbers also.It is a COBOL program And the purpose of hte logic is to insert few lines after a given line.But While inserting I need to replace a Text with the immediately Preceding section name.To find the section name,I am parsing the file using "F P'
Back to top
View user's profile Send private message Send e-mail
semigeezer
Supermod


Joined: 03 Jan 2003
Posts: 1014
Topics: 13
Location: Atlantis

PostPosted: Wed Sep 20, 2006 8:26 am    Post subject: Reply with quote

What does the PROFILE command show?
Back to top
View user's profile Send private message Visit poster's website
sendhil
Beginner


Joined: 06 Sep 2006
Posts: 17
Topics: 6

PostPosted: Wed Sep 20, 2006 8:38 am    Post subject: Reply with quote

Code:

....RECOVERY OFF WARN....NUMBER OFF..............
CAPS OFF....HEX OFF....NULLS OFF....TABS OFF........................
AUTOSAVE ON....AUTONUM OFF....AUTOLIST OFF....STATS ON..............
PROFILE UNLOCK....IMACRO NONE....PACK OFF....NOTE ON................
HILITE REXX CURSOR FIND.............................................
Back to top
View user's profile Send private message Send e-mail
semigeezer
Supermod


Joined: 03 Jan 2003
Posts: 1014
Topics: 13
Location: Atlantis

PostPosted: Wed Sep 20, 2006 12:30 pm    Post subject: Reply with quote

I think it is because the cursor is after col 7. Try changing
"F '*' .ZCSR .LINE 7"
to
"F '*' .ZCSR .LINE 7 FIRST"


that will insure that scanning starts at the beginning of the line.
Back to top
View user's profile Send private message Visit poster's website
sendhil
Beginner


Joined: 06 Sep 2006
Posts: 17
Topics: 6

PostPosted: Wed Sep 20, 2006 11:42 pm    Post subject: Reply with quote

semigeezer,
Thanks a Lot .It worked.


Regards
Sendhil.
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group