Fred67
27th April 2004, 11:46
Hello,
I have to test the search field during the def.find option.
What I want to do :
For Example, where are in the maintain Item session.
Items A and C exists, not B. If we are on item A and make a search on B, Baan skips to item C. I would like to abort this skip action : if B does not exist, baan aborts the searchs and stays on A.
Then I Have to test the input during the search but I didn't find anyway to make this. When debbuging the input field doesn't reach the "B" value. I tried to place somme messages in different sections like before.check, but no results .Is it and internal value ?
Could anyone help me.
Thanks for All.
croezen
27th April 2004, 13:56
Would it be an option to use the select option in stead of the search option?
Fred67
27th April 2004, 14:02
No, but it could be
lbencic
27th April 2004, 16:27
I have had this problem before - probably can search and find the thread. I can't seem to find the values that the user enters in that little 'find' window, so they can't be used to compare anything when they return.
Maybe someone know's that and can post.
I didn't get further, was not worth the effort for my problem, but if you need maybe in the 'def.find / before.choice' section, you can instead zoom out to your own little session, capture and export the values they enter, return to your main session. You would then have to make the value current yourself, or cancel if it does not exist.
Fred67
27th April 2004, 17:39
Thanks for your reply.
I had a so Idee, to use a little window or a function like "input".
I will try such a solution.
lbencic
27th April 2004, 19:12
ok. I also did search on that and found some more info I forgot about. If you are talking about a type 3 form, you can control the Find action somewhat using break.view:
Break View thread (http://www.baanboard.com/baanboard/showthread.php?s=&threadid=14776&highlight=break.view)
Fred67
28th April 2004, 10:06
No it's a type 1 form (tssma1101m000)
The purpose of this developpement is to avoid errors after search, to not change an unwanted record.
akshaymadane
29th April 2004, 10:47
U could try the following:
1.In the after.input of item set a temporary field say temp.item = item
2. Now in the after.read, check whether temp.item = item.
if yes then item exists.
if no then use skip.io() to make the session stay on item A.
3. using the same temp variable, u can perform any checks u want on the item field.
en@frrom
30th April 2004, 16:01
I have played around with this, and found that the best way to get this done, is by adding in the before.choice of choice.def.find an execute(find.data), and make sure that the predefined variable 'break.view' is not set in the program to 'true' [default = false].
Good luck!
En.
Fred67
3rd May 2004, 10:17
thanks for all these answers.
I will try this.
Regards
Fred