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 

Cursor Positioning

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> CICS and Middleware
View previous topic :: View next topic  
Author Message
Avishek
Beginner


Joined: 02 Dec 2002
Posts: 3
Topics: 1
Location: Calcutta,India

PostPosted: Mon Dec 02, 2002 5:43 am    Post subject: Cursor Positioning Reply with quote

Hello Everyone,

Can somebody help me out with the code or explanation of Cursor Positioning? I know that we need to do so using EIBCPOSN. However, the book I am following does not go very deep into the topic.
Thanks in advance.

Regards
_________________
Avishek Saha
India
Back to top
View user's profile Send private message Yahoo Messenger MSN Messenger
kolusu
Site Admin
Site Admin


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

PostPosted: Mon Dec 02, 2002 5:51 am    Post subject: Reply with quote

Avishek,

Positioning the cursor

Hope this helps...

cheers

kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Avishek
Beginner


Joined: 02 Dec 2002
Posts: 3
Topics: 1
Location: Calcutta,India

PostPosted: Mon Dec 02, 2002 6:21 am    Post subject: Reply with quote

Hello Kolusu,

Thank You for the reply but I guess I was not able to frame the question properly. What i want is to pick the current Cursor Position from the screen and not to place the Cursor in a particular field.

Thanks.
_________________
Avishek Saha
India
Back to top
View user's profile Send private message Yahoo Messenger MSN Messenger
sujayath
Beginner


Joined: 02 Dec 2002
Posts: 1
Topics: 0
Location: India

PostPosted: Mon Dec 02, 2002 7:08 am    Post subject: Reply with quote

Hi,

You could use EIBCPOSN to find out the latest cursor position. It returns a single number relative to position zero on the screen (row 1, column 1), in the same way that you specify the CURSOR parameter on a SEND MAP command.

Or you could use DFHCURSR Like

WHEN <FIELD1>F = DFHCURSR
PERFORM PARA-1
WHEN <FIELD2>F = DFHCURSR
PERFORM PARA-2

You can also use

WHEN <FIELD1>F = X'02'
PERFORM PARA-1
WHEN <FIELD2>F = X'02'
PERFORM PARA-2
Back to top
View user's profile Send private message Send e-mail
Manas Biswal
Intermediate


Joined: 29 Nov 2002
Posts: 382
Topics: 27
Location: Chennai, India

PostPosted: Mon Dec 02, 2002 8:34 am    Post subject: Reply with quote

Hi Avishek,

EIBCPOSN contains the cursor position in the following form:-

EIBCPOSN = (Row-1)*80 + (Column - 1)

Now, let us suppose that the cursor is present at 11th row and 10th column.
So, EIBCPOSN will contain the value 10*80+9 = 809.

Conversly, suppose you have to find out the row number from EIBCPOSN(which is usually the case), dividing it by 80 and rounding it off to the next greater integer should do the trick.
809/80 = 10.1 rounded off to 11
So, 11 is the row number on which the cursor was located prior to the RECEIVE.

Hope it makes things somewhat clearer.

Regards,
Manas
Back to top
View user's profile Send private message Send e-mail Yahoo Messenger
Avishek
Beginner


Joined: 02 Dec 2002
Posts: 3
Topics: 1
Location: Calcutta,India

PostPosted: Tue Dec 03, 2002 5:27 am    Post subject: Reply with quote

Hello,

Thank You Sujayath and Manas. Your views will surely help.

Regards
_________________
Avishek Saha
India
Back to top
View user's profile Send private message Yahoo Messenger MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> CICS and Middleware 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