Jump to content


Photo
- - - - -

Control Arrow Key


18 replies to this topic

#1 siobi

siobi

    Member

  • Members
  • PipPip
  • 48 posts
  • Gender:Male

Posted 23 September 2005 - 05:25 AM

dear all,
How to control or.... disable up and down arrow key in proiv?

#2 Kelvin Rapley

Kelvin Rapley

    Member

  • Members
  • PipPip
  • 40 posts
  • Gender:Male
  • Location:BIRMINGHAM, ENGLAND

Posted 23 September 2005 - 06:49 AM

You can control the use of arrow keys to some extent by interrogating the last function key pressed in field logic:

If @FNKEY = 5 [UP ARROW, or 4 DOWN ARROW]

Then you can field jump

You can also capture the function key pressed in general check logic (custom validation logic in VIP) by using

CHECK-INPUT

it has to be on the first line of the logic followed by function key interrogation

Kelvin.

#3 Chris Pepper

Chris Pepper

    ProIV Guru

  • Members
  • PipPipPipPipPip
  • 369 posts
  • Gender:Male
  • Location:United Kingdom

Posted 23 September 2005 - 06:55 AM

Usual questions...

Which version of ProIV?
Do you mean green screen or GUI? I assume green screen??
Is it all uses of the up and down arrows (e.g. on paging screens to go down the list of records, or on non-paging screens to go between fields on the screen) on all screens or only some uses in some cases?

#4 Shaun Rudland

Shaun Rudland

    Expert

  • Members
  • PipPipPipPip
  • 165 posts
  • Location:Queensland, Australia

Posted 23 September 2005 - 11:17 PM

I thought that holiday was supposed to make you less grumpy Chris B)
PRO-IV free for 385 Days B)

#5 Chris Pepper

Chris Pepper

    ProIV Guru

  • Members
  • PipPipPipPipPip
  • 369 posts
  • Gender:Male
  • Location:United Kingdom

Posted 24 September 2005 - 08:06 AM

That's just my age!

I'm a pussycat really!

#6 siobi

siobi

    Member

  • Members
  • PipPip
  • 48 posts
  • Gender:Male

Posted 27 September 2005 - 07:42 AM

thanks for reply,

it is a paging screen.

user had to open an window in order to process some information and the window will return a flag and the program will update the flag result (return from the window) to the paging screen display only.

everything works fine if user open window, process and return to paging and press enter key to continue to next field, then the display only field will shown the latest result passed from the window.

but when user open the window and process, then return to the paging screen, it is only up to window logic, then at that point, user use arrow key down , it will by pass the after logic and the displayed field will be skip !!!

If i would try the CHECK-INPUT command at the after logic, it doesnt process at all!!
help!!!

I had to disable arrow key!!! so when user press arrow down, nothing happend and user had to force to hit the "enter " key to proceed... then only it will continue to the next field ...


any idea?

#7 Wim Soutendijk

Wim Soutendijk

    ProIV Guru

  • Members
  • PipPipPipPipPip
  • 211 posts
  • Gender:Male
  • Location:Netherlands

Posted 27 September 2005 - 08:32 AM

I am not sure, but you could try setting the force write flag on that paging screen.
In Entry logic of the paging screen use the logic Paging.Forcewrite()
Where Paging is the tag name of the paging screen

#8 Rob Donovan

Rob Donovan

    rob@proivrc.com

  • Admin
  • 1,640 posts
  • Gender:Male
  • Location:Spain

Posted 27 September 2005 - 08:34 AM

Hi,

This is because ProIV is trying to be efficient... it thinks that you havent updated any data because you are on the first field in a paging screen. Therefore ProIV skips any after field logic and also the write to any files.

You can override this with the ForceWrite() property, if you are using version ProIV 5.5r300 or above.

The format is .ForceWrite() and it must be issued before the paging screen is entered, in Logic Entry. However, on the version of ProIV I'm currently using (5.5r345) the ForceWrite() seems to only work in Function Entry Logic, and no where else.

Example: Cycle1.ForceWrite()

This just means that the paging screen will process all 'after field logic' and write the files, even if the user just pages down through the paging screen. Its a little bit of an overhead, but it should not effect you too much.

You will have to have a play around with it and see where you need to put the ForceWrite to get it to work.

HTHs,

Rob D.

#9 Rob Donovan

Rob Donovan

    rob@proivrc.com

  • Admin
  • 1,640 posts
  • Gender:Male
  • Location:Spain

Posted 27 September 2005 - 08:35 AM

Opps, you beat me to it Wim B)

Rob.

#10 siobi

siobi

    Member

  • Members
  • PipPip
  • 48 posts
  • Gender:Male

Posted 28 September 2005 - 01:51 AM

dear,
I'm using proiv 4.6

#11 Chris Mackenzie

Chris Mackenzie

    ProIV Guru

  • Members
  • PipPipPipPipPip
  • 368 posts
  • Gender:Male
  • Location:Bristol, United Kingdom

Posted 28 September 2005 - 08:35 AM

Couple of things you might try then:

DISABLE(&#NORTNF) or &#@NO-CR before the field so it will not require
user to press rtn to carry on and it should update your field.

Or check the prev function key in LGC-BEF where user
ends up after pressing the arrow key and force a
refresh from there (somehow!).

Edited by Chris Mackenzie, 28 September 2005 - 08:36 AM.

The content and views expressed in this message are those
of the poster and do not represent those of any organisation.

#12 Rob Donovan

Rob Donovan

    rob@proivrc.com

  • Admin
  • 1,640 posts
  • Gender:Male
  • Location:Spain

Posted 28 September 2005 - 12:18 PM

Ok, if your on 4.6 then you could try this....

In the Def Logic of the window LS, put in the following line....

$SAVE-INPUT = $INPUT

And in the Exit Logic of the window LS, put the following lines....

IF $SAVE-INPUT = "" THEN
  $INPUT = <WindowFieldName>
ELSE
  $INPUT = $SAVE-INPUT
ENDIF

Change WindowFieldName to the name of the variable that you are windowing on.

Setting $INPUT in the exit of the window LS, forces the cursor on to the next field, and therfor your After Field Logic and the write to the file will occur.

If your window field is a numeric, then replace the var $SAVE-INPUT to #SAVE-INPUT and $INPUT to #INPUT.

Rob D.

#13 siobi

siobi

    Member

  • Members
  • PipPip
  • 48 posts
  • Gender:Male

Posted 30 September 2005 - 04:30 AM

thanks for the reply...

Dear,

&#@NO-CR works fine for check box, but not window field... it will not auto update field and force to continue to the field logic after...


regarding the $input, I had tried, but the result still the same... it will not run the logic after as well...

weird....

If I hit enter button instead of arrow down, then it will process the logic after, but if i tried arrow down key, it will still not process the logic after.

#14 George Macken

George Macken

    ProIV Guru

  • Members
  • PipPipPipPipPip
  • 248 posts
  • Gender:Male
  • Location:Co. Wicklow, Ireland

Posted 30 September 2005 - 08:29 AM

Hi

Maybe re-design the screens - the field you are windowing from in the paging screen - could you make this a Mandarory Input Field, in lgc before initialise the field, this way a value has to be entered and the gen chk and lgc aft forced.

Maybe the field could be populated by a value returned from the window, or maybe the user has to enter the value - a Y or N for example.

If on the paging line there is a value displayed which is only populated after returning from the window then surely the user will see that the value has not been displayed and return to the line and repeat the process and hitting return to make it appear. Sort of training the User to the fact that the Arrows dont work as you'd like on this page.

hope this helps

other suggestions here referred to solutions in 5.5 etc., - we recently moved a major application 2000 functions without any real development hard-ship - of course the users system tested the complete application on 5.5. and no problems raised realted to the upgrade.

Rgds

George

#15 Chris Mackenzie

Chris Mackenzie

    ProIV Guru

  • Members
  • PipPipPipPipPip
  • 368 posts
  • Gender:Male
  • Location:Bristol, United Kingdom

Posted 30 September 2005 - 03:36 PM

Ok, I fiddled around and I used Rob's suggestion (which I've seen
before but forgot about...) in combination

use window logic to call the window like this:

GLOBAL_LSCALL(SELWINNM,0001)
$INPUT = $outputvar



and put this into gen-chk logic:


EXIT

that made it move for me but I don't have exactly the same version as you.



hth

Edited by Chris Mackenzie, 30 September 2005 - 03:38 PM.

The content and views expressed in this message are those
of the poster and do not represent those of any organisation.



Reply to this topic



  


0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users