Project

General

Profile

Defect #335

Request for a 'close' function

Added by Rafi Galibov almost 13 years ago. Updated almost 13 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Target version:
Start date:
06/28/2011
Due date:
% Done:

0%

Estimated time:
Browser (if web client):

Description

I am using it in a solution that is sending emails from a web page.
If the email goes successfully, I am displaying a dialog saying 'success' and have a button saying 'Done' on it.
This gets passed back to a global and my client wanted the web page/solution to close when the email was sent successfully so that the Servoy client licence wasn't kept in use, in case the user left the browser open
so I am doing this

@
globals.send_form_nhs_mail ( event, globals.send_to, globals.send_subject, globals.send_msg_txt, globals.attachment_file_name, globals.send_msg_type );

if (( application.getApplicationType ( )  APPLICATION_TYPES.WEB_CLIENT ) && (globals.button_pressed  'Done'))
    {
application.sleep(3000) ;
application.closeForm(true) ;
application.closeSolution() ;
}
@

where your dialog is being called in the globals.send... method,

@
if ( globals.is_headless != 1 ) {
if ( !success ) {
globals.DIALOGS.showWarningDialog ( 'Alert', plugins.mail.getLastSendMailExceptionMsg ( ), 'OK' );
}
else {
globals.button_pressed = globals.DIALOGS.showInfoDialog ( 'Success', globals.send_msg_type + ' Sent Successfully!', 'Done' );
}
}
@
but what is happening is that your 'dialog' is not closing, so the solution closes in that window and things look weird.
I added the sleep hoping it would give it enough time to go, but it doesn't, so could you add a 'globals.DIALOGS.close();' to allow me to force it to close? (I also added the closeForm, but that didn't help...)


Files

mod_dialog.servoy (50.1 KB) mod_dialog.servoy 1.1.2b2 Robert Ivens, 07/01/2011 04:02 PM

Related issues

Related to Dialogs module - Defect #336: dialog not dismissing...Closed06/28/2011

Actions

History

#1

Updated by Robert Ivens almost 13 years ago

  • Status changed from New to In Progress

I've got Johan looking at it now. It might be related to this reported issue : https://forum.servoy.com/viewtopic.php?f=9&t=16373

#2

Updated by Robert Ivens almost 13 years ago

  • File mod_dialog.servoy added

Can you try this version and see if still see the 2 issues you reported.

#3

Updated by Robert Ivens almost 13 years ago

  • File deleted (mod_dialog.servoy)
#4

Updated by Robert Ivens almost 13 years ago

New version for you to test.

#5

Updated by Robert Ivens almost 13 years ago

  • Status changed from In Progress to Resolved

Version 1.1.2 that is just released should solve the issues you have. To make it work properly in the web client you need Servoy 5.2.10 or 6.0rc3 (or higher).
Both Servoy versions are not yet available at this time.

#6

Updated by Robert Ivens almost 13 years ago

  • Target version set to 1.1.2

Also available in: Atom PDF