manish2111
19th January 2009, 19:09
Any one who can help me.....plzz
I have two table lvmhn114 and lvmhn113
Two session lvmhn1114m000 and lvmhn1113m000
After opening lvmhn1114m000 session i enter some field in which index is
lvmhn114.gpno, lvmhn114.date, lvmhn114.suno

1. Afterfilling all fields there is one button on the same session which calls another session after clicking on the button this session opens lvmhn1113m000. In this session I want the same data what i entered in previous session i.e. lvmhn114.gpno, lvmhn114.date, lvmhn114.suno. My second session is of TYPE 3 and First Session is of TYPE 1 (lvmhn1114m000).

2. If data is available in 2nd session i.e. lvmhn1113m000 then users should not be able to delete the data from 1st session i.e lvmhn1114m000. If they want to delete then first he should delete data from 2nd session then after he can delete the data from 1st session.

3. If any user is updating the data in second session for say Gate Pass No. 1 then at that time no other users should update the same record.

plzzzzzzz help me and give me the exact code so that i can get the output i m trying it from so many days but not able to solve all three problem. If any one can help me out. Thanks in advance.

ARijke
20th January 2009, 10:10
Just giving some code will not be possible.
1 try the import() function in the init.form section and if the correct fields are set use execute(find.data).
2 This could be handled by a table references or you can programm the query in the before.choice of the choice.mark.delete. If it is not allowed you can use choice.again()
3 An application lock can be used: functions appl.set() and appl.delete()

If you are not familiar with these standard functions please read the manual.

regards, Adriaan

manish2111
20th January 2009, 20:53
Hi all
any one who can give me exact code to find the soln.
I tired all way but not getting. I have given my full requirement based on that if any one can help me ????

mark_h
20th January 2009, 22:58
I doubt if you will get anyone to provide the exact code - nobody knows exactly what you are doing. Just like Adriaan said to get data from the main session to the second session use export in the first session and import in the second session. Get this to work first. Once you have the data shared you can go to the next step. If you have problems with this part start another thread on export/import. There are already plenty of threads on it so please do some searching before posting.

Then depending how you want the application locks to work you have to decide where to set them, when to clean them up. So for example in the second session when you import the data your could set a lock based off one of the fields - but you first check to see if the lock already exists, if it does you do not set the lock. In this case give a message and just do a return.

manish2111
21st January 2009, 06:21
Hello Everybody
thanks for ur support...
but finall I got the solution on my own..... and after getting the soln I personally found it was not so tough....

once again thanks to all to give me support, see u on next forum for getting the soln...