Home » Developer & Programmer » Forms » exit (form 6i,windows xp)
exit [message #431080] Sat, 14 November 2009 09:15 Go to next message
hisham99
Messages: 86
Registered: October 2008
Location: united arab emirates
Member
my problem is some time user will open a form application and keep it open without doing any thing for long time so if i try to make any operation like (query, update insert delete )this message will appear (could not reserve record(2 tries).keep trying)
my question is can i make a program if user open an application
for more than one minute without make any operatin,system will exit him from that aplication automatically
(i can use the timer but i dont know how )
can any one show me the code please

Re: exit [message #431081 is a reply to message #431080] Sat, 14 November 2009 09:29 Go to previous messageGo to next message
javed.khan
Messages: 340
Registered: November 2006
Location: Banglore
Senior Member

Dear as one more thread is there about the same topic...I was going thru that and thinking if we can make something like that. Go through the again what you have asked for ... "Any Operation" obiously you have to check then each and every event for timers if you are going to use a timer. e.g. If your form have 3 Text boxes and 2 Buttons you have to check each and every box for one minute and run one timer followed by the event seems like not a good idea. Take your route cause all you have to do is "Overide a DeadLock"


If you have DBA rights try use the v$LOCKED_OBJECT, it will also show who the blocker is:

SELECT LPAD(' ',DECODE(l.xidusn,0,3,0)) || l.oracle_username "User Name",
o.owner, o.object_name, o.object_type
FROM v$locked_object l, dba_objects o
WHERE l.object_id = o.object_id
ORDER BY o.object_id, 1 desc



Check if your transactional table on which you want to do some manipulations is in this list of locked tables and give a yellow card to the user.


Jak
Re: exit [message #431088 is a reply to message #431081] Sat, 14 November 2009 12:10 Go to previous messageGo to next message
hisham99
Messages: 86
Registered: October 2008
Location: united arab emirates
Member
thanks for your replay and patient
i open aform and execute a query ,and the i run your code ,it work fine but ,it seems to me any one will open a form his username will appear directly not after some times
if you can guides me ,
i want to write a code on each forms in my program so it will terminate the user who open a form for long time without doing any operation automaticaly without dba interfer

Re: exit [message #431093 is a reply to message #431088] Sat, 14 November 2009 23:54 Go to previous message
javed.khan
Messages: 340
Registered: November 2006
Location: Banglore
Senior Member

Hisham,
Writing a query on every movement and keystroke is a cumbersome job if you want Last DDL Activity then you can use All_Object Table for checking the last DDL executed and start the timer counting from that time everytime whenever your counter reaches in a complete time frame you have assigned then say Expire or Terminate whatever you want to do with your form.


Check it out

SQL> select object_name, TO_CHAR(LAST_DDL_TIME,
'YYYYMMDD HH24:MI:SS') last_ddl

         
 from all_objects



It will give you the last DDL time .


Jak

[Updated on: Sat, 14 November 2009 23:56]

Report message to a moderator

Previous Topic: email from form6i
Next Topic: Dynamically add checkboxes and radio buttons
Goto Forum:
  


Current Time: Fri Dec 09 08:11:17 CST 2016

Total time taken to generate the page: 0.08269 seconds