[BR_forum] 4.2 and Next

General development discussion.

Moderators: Susan Smith, admin, Gabriel

Post Reply
Stephen Koger

[BR_forum] 4.2 and Next

Post by Stephen Koger »

I pulled the following from the 4.2 Release notes off the FTP Site. This being a new feature in 4.2 that I find VERY interesting. Problem is there are no working examples. Anybody got a working example? INTERROGATING THE NEXT 2D CONTROL

It is desirable to know where a user clicked when he or she clicks on a GRID or LIST that is hot ( has an FKEY assigned to it ). One needs to know where to place the cursor when the clicked location is significant.

The keyword NEXT can be used in the same manner as CUR in that the next (clicked on) cursor position within a 2D control can be identified. e.g. :

I realize this is an example.. but.. for example is next_pos a variable? Is it a Keyword? Will it contain a value… should it contain a value?

00100 INPUT FIELDS "row,col,GRID 10/60, SUB, NEXT, NOWAIT": next_pos


NXTROW is a system function that identifies the character position or cell row associated with the next cursor position (e.g. where the mouse pointer was last
clicked). If the next cursor position is in a 2D control, then NXTROW specifies the row of the cell within the 2D control. If not it specifies the first character position of the next control to receive focus. NXTCOL specifies the column of the respective position.

With respect to these functions, the next cursor position can be the result of keyboard or mouse activity. If the next position results from keyboard activity then NXTROW has the same value as CURROW when Enter is pressed or control was returned in response to a leading attribute such as X (return control upon exit). When the mouse is used to return control to a program, the next cursor position is the pointer location that is double clicked or hot location that is single clicked.

One key concept here is that just as one must keep track of what type of control was last accessed, by means other than CURROW and CURCOL, similarly one must determine the type of control to be next accessed by means other than NXTROW and NXTCOL. This can be done with the system function NXTFLD in conjunction with hotkey event (fkey) numbers.

CURCOL/NXTCOL have a slight change in functionality in this release. Previously they specified the column (relative to the window) of the cursor position. Now they specify the first position of the respective control. OPTION 59 has been added to make CURCOL (not NXTCOL) work the old way.

Need a working example of this “^user_entry” as I am not sure what this is really telling me.. Like doug says.. I am from Missouri… Show ME!

A new leading attribute "^user_entry", returns control to the program upon the cursor entering a field. This does not apply to fields given initial focus by INPUT processing, such as with CURFLD or the first field of a FIELDS operation.
Gabriel
Posts: 412
Joined: Sun Aug 10, 2008 7:37 am
Location: Arlington, TX
Contact:

[BR_forum] 4.2 and Next

Post by Gabriel »

Your first question:
 
next_pos is a variable. You are inputting to it using the INPUT command. It will contain a value after the input.

^user_entry looks like it works just like the "E" attribute.
 
Gabriel
 

 
On Tue, May 12, 2009 at 1:24 PM, Stephen Koger <steve.koger@m-a-c-s.com (steve.koger@m-a-c-s.com)> wrote:
I pulled the following from the 4.2 Release notes off the FTP Site.  This being a new feature in 4.2 that I find VERY interesting.  Problem is there are no working examples. Anybody got a working example?       INTERROGATING THE NEXT 2D CONTROL
 
It is desirable to know where a user clicked when he or she clicks on a GRID or LIST that is hot ( has an FKEY assigned to it ). One needs to know where to place the cursor when the clicked location is significant.
 
The keyword NEXT can be used in the same manner as CUR in that the next (clicked on) cursor position within a 2D control can be identified. e.g. :
 
I realize this is an example.. but.. for example is next_pos a variable? Is it a Keyword?  Will it contain a value… should it contain a value?  
 
00100 INPUT FIELDS "row,col,GRID 10/60, SUB, NEXT, NOWAIT": next_pos
 
 
NXTROW is a system function that identifies the character position or cell row associated with the next cursor position (e.g. where the mouse pointer was last
clicked). If the next cursor position is in a 2D control, then NXTROW specifies the row of the cell within the 2D control. If not it specifies the first character position of the next control to receive focus. NXTCOL specifies the column of the respective position.
 
With respect to these functions, the next cursor position can be the result of keyboard or mouse activity. If the next position results from keyboard activity then NXTROW has the same value as CURROW when Enter is pressed or control was returned in response to a leading attribute such as X (return control upon exit). When the mouse is used to return control to a program, the next cursor position is the pointer location that is double clicked or hot location that is single clicked.
 
One key concept here is that just as one must keep track of what type of control was last accessed, by means other than CURROW and CURCOL,  similarly one must determine the type of control to be next accessed by means other than NXTROW and NXTCOL. This can be done with the system function NXTFLD in conjunction with hotkey event (fkey) numbers.
 
CURCOL/NXTCOL have a slight change in functionality in this release. Previously they specified the column (relative to the window) of the cursor position. Now they specify the first position of the respective control. OPTION 59 has been added to make CURCOL (not NXTCOL) work the old way.
 
Need a working example of this “^user_entry”  as I am not sure what this is really telling me.. Like doug says..  I am from Missouri…  Show ME!
 
A new leading attribute "^user_entry", returns control to the program upon the cursor entering a field. This does not apply to fields given initial focus by INPUT processing, such as with CURFLD or the first field of a FIELDS operation.
 
 


_______________________________________________
BR_forum mailing list
BR_forum@ads.net (BR_forum@ads.net)
http://ads.net/mailman/listinfo/br_forum_ads.net
gordon
Posts: 358
Joined: Fri Apr 24, 2009 6:02 pm

[BR_forum] 4.2 and Next

Post by gordon »

^user_entry gives program control upon the user entering a field. Note that it does not give program control when a program puts a field into focus.

gordon



On Wed, May 13, 2009 at 11:21 AM, Gabriel Bakker <gabriel.bakker@gmail.com (gabriel.bakker@gmail.com)> wrote:
Your first question:
 
next_pos is a variable. You are inputting to it using the INPUT command. It will contain a value after the input.

^user_entry looks like it works just like the "E" attribute.
 
Gabriel
 

 

On Tue, May 12, 2009 at 1:24 PM, Stephen Koger <steve.koger@m-a-c-s.com (steve.koger@m-a-c-s.com)> wrote:

I pulled the following from the 4.2 Release notes off the FTP Site.  This being a new feature in 4.2 that I find VERY interesting.  Problem is there are no working examples. Anybody got a working example?       INTERROGATING THE NEXT 2D CONTROL
 
It is desirable to know where a user clicked when he or she clicks on a GRID or LIST that is hot ( has an FKEY assigned to it ). One needs to know where to place the cursor when the clicked location is significant.
 
The keyword NEXT can be used in the same manner as CUR in that the next (clicked on) cursor position within a 2D control can be identified. e.g. :
 
I realize this is an example.. but.. for example is next_pos a variable? Is it a Keyword?  Will it contain a value… should it contain a value?  
 
00100 INPUT FIELDS "row,col,GRID 10/60, SUB, NEXT, NOWAIT": next_pos
 
 
NXTROW is a system function that identifies the character position or cell row associated with the next cursor position (e.g. where the mouse pointer was last
clicked). If the next cursor position is in a 2D control, then NXTROW specifies the row of the cell within the 2D control. If not it specifies the first character position of the next control to receive focus. NXTCOL specifies the column of the respective position.
 
With respect to these functions, the next cursor position can be the result of keyboard or mouse activity. If the next position results from keyboard activity then NXTROW has the same value as CURROW when Enter is pressed or control was returned in response to a leading attribute such as X (return control upon exit). When the mouse is used to return control to a program, the next cursor position is the pointer location that is double clicked or hot location that is single clicked.
 
One key concept here is that just as one must keep track of what type of control was last accessed, by means other than CURROW and CURCOL,  similarly one must determine the type of control to be next accessed by means other than NXTROW and NXTCOL. This can be done with the system function NXTFLD in conjunction with hotkey event (fkey) numbers.
 
CURCOL/NXTCOL have a slight change in functionality in this release. Previously they specified the column (relative to the window) of the cursor position. Now they specify the first position of the respective control. OPTION 59 has been added to make CURCOL (not NXTCOL) work the old way.
 
Need a working example of this “^user_entry”  as I am not sure what this is really telling me.. Like doug says..  I am from Missouri…  Show ME!
 
A new leading attribute "^user_entry", returns control to the program upon the cursor entering a field. This does not apply to fields given initial focus by INPUT processing, such as with CURFLD or the first field of a FIELDS operation.
 
 




_______________________________________________
BR_forum mailing list
BR_forum@ads.net (BR_forum@ads.net)
http://ads.net/mailman/listinfo/br_forum_ads.net

_______________________________________________
BR_forum mailing list
BR_forum@ads.net (BR_forum@ads.net)
http://ads.net/mailman/listinfo/br_forum_ads.net
Post Reply