Logon procedure in Oracle Forms 4.5

Logon procedure in Oracle Forms 4.5

Post by Horace Kwon » Fri, 15 Nov 1996 04:00:00



I have a problem when overriding the default logon screen by using my own
logon screen. Please see the following code:

/* on-logon trigger */
if :logon.bypass_logon is not null then

  if not form_success then
    raise form_trigger_failure;
  end if;
end if;
/* end of on-logon trigger */

/* when-new-form-instance trigger */
:logon.bypass_logon := 'F';
:global.logon_failure := 0;
show_my_logon_screen;
/* end of when-new_form_instance trigger */

/* when-button-pressed trigger for the OK button in the my_logon_screen */
execute_trigger('ON-LOGON');
if form_success then
  hide_my_logon_screen;
  message('You logon successfully');
  continue ....
elsif :global.logon_failure = 2 then
  exit_form(no_validate);
else
  :global.logon_failure := :global.logon_failure + 1;
  message('Incorrect username or password. Please try again');
  remain in my_logon_screen;
end if;
/* end of when-button-pressed trigger */

Note that the above code work alright in forms 4.0. But when I ported the
code to run in forms 4.5, problems come. If I type a wrong username or
password, then I am remain in my_logon_screen. Afterwards, I type a right
one and I am virtually logon successfully. Unfortunately, if the program
run to a sentence that request data from database, Application error saying
: F45RUN caused a General Protection Fault in module PLR1171W.DLL at
0003:CF58.

However, if I can type the correct username and password the first time,
everything works alright.

Do any of you know what's happening?

Best Regards,
Horace Kwong

 
 
 

Logon procedure in Oracle Forms 4.5

Post by Lewis Cunningh » Mon, 18 Nov 1996 04:00:00


I had the same thing happen to me.  I think it has something to with recursion
but I'm not sure.  Anyway, use NULL; in the on-logon and move your logon code to
a seperate form.  Call the logon form from the pre-form trigger and that should
work.  If it doesn't and you'ld like a sample (i.e., the logon i use), e-mail me
and I'll send it to you.

Lewis


>I have a problem when overriding the default logon screen by using my own
>logon screen. Please see the following code:
>/* on-logon trigger */
>if :logon.bypass_logon is not null then

>  if not form_success then
>    raise form_trigger_failure;
>  end if;
>end if;
>/* end of on-logon trigger */
>/* when-new-form-instance trigger */
>:logon.bypass_logon := 'F';
>:global.logon_failure := 0;
>show_my_logon_screen;
>/* end of when-new_form_instance trigger */
>/* when-button-pressed trigger for the OK button in the my_logon_screen */
>execute_trigger('ON-LOGON');
>if form_success then
>  hide_my_logon_screen;
>  message('You logon successfully');
>  continue ....
>elsif :global.logon_failure = 2 then
>  exit_form(no_validate);
>else
>  :global.logon_failure := :global.logon_failure + 1;
>  message('Incorrect username or password. Please try again');
>  remain in my_logon_screen;
>end if;
>/* end of when-button-pressed trigger */
>Note that the above code work alright in forms 4.0. But when I ported the
>code to run in forms 4.5, problems come. If I type a wrong username or
>password, then I am remain in my_logon_screen. Afterwards, I type a right
>one and I am virtually logon successfully. Unfortunately, if the program
>run to a sentence that request data from database, Application error saying
>: F45RUN caused a General Protection Fault in module PLR1171W.DLL at
>0003:CF58.
>However, if I can type the correct username and password the first time,
>everything works alright.
>Do any of you know what's happening?
>Best Regards,
>Horace Kwong


 
 
 

Logon procedure in Oracle Forms 4.5

Post by Miles Thom » Wed, 20 Nov 1996 04:00:00




[snip]

Quote:>>Note that the above code work alright in forms 4.0. But when I ported the
>>code to run in forms 4.5, problems come. If I type a wrong username or
>>password, then I am remain in my_logon_screen. Afterwards, I type a right
>>one and I am virtually logon successfully. Unfortunately, if the program
>>run to a sentence that request data from database, Application error saying
>>: F45RUN caused a General Protection Fault in module PLR1171W.DLL at

I've had the same problem.  Its a known bug of Oracle Forms 4.5.6, apparently
fixed in 4.5.7.  Unfortunately, the Windows 3 version was supposed to be
shipping by now, but there's been a delay.  And no work-around.....

Best thing that I can figure to do is write a Pro*C or VB/ODBC front end to
the application, which tests the user's password, and then calls f45run with
un/pw string.

 
 
 

1. Overriding the default logon screen in Forms 4.5

Do anybody have tried to use own logon screen by overriding the default
logon screen. Asking user to type in the connection string is a bit "urgy".

In the previous version of forms (v4.0). I can successfully override it by
making some code in the on-logon trigger. I call the logon built-in in the
on-logon trigger. It worked.

But when I use the same trick in v4.5. Problem comes that when user type in
a wrong password the first. The second time, he type in a right password.
Then he can logon virtually. Once, the program run to some code that ask
the database for data, general protection fault appears!!!

Horace Kwong

2. How to confirm current connection valid??..

3. Oracle Forms 4.5 Text Form

4. Microsoft SQL Server 2000

5. Oracle forms 4.5 with Personal oracle 8

6. Counting the number of satisfied LIKES in a SELECT statement

7. Forms 4.5 and Packaged Procedures

8. Storing addresses in a database

9. Forms 4.5 & stored procedures - problems with COMMIT

10. Losing Access To Database Procedures From FORMS 4.5

11. calling a procedure in a .dll from forms 4.5

12. Portage d'une application de FORMS 3.0 en FORMS 4.5

13. Migrating SQL*Forms 3.0 to Forms 4.5, 5 or 6