Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.clipper.visual-objects > #13479 > unrolled thread

help

Started byaurora baccio <aurorabaccio@gmail.com>
First post2021-11-26 07:38 -0800
Last post2021-11-28 14:38 +0100
Articles 7 — 3 participants

Back to article view | Back to comp.lang.clipper.visual-objects


Contents

  help aurora baccio <aurorabaccio@gmail.com> - 2021-11-26 07:38 -0800
    Re: help JohnMartens <martens@tennishulp.info> - 2021-11-26 16:56 +0100
      Re: help aurora baccio <aurorabaccio@gmail.com> - 2021-11-28 02:21 -0800
        Re: help JohnMartens <martens@tennishulp.info> - 2021-11-29 18:50 +0100
    Re: help "Wolfgang Riedmann" <wriedmann@gmail.com> - 2021-11-27 18:07 +0100
      Re: help aurora baccio <aurorabaccio@gmail.com> - 2021-11-28 02:25 -0800
        Re: help "Wolfgang Riedmann" <wriedmann@gmail.com> - 2021-11-28 14:38 +0100

#13479 — help

Fromaurora baccio <aurorabaccio@gmail.com>
Date2021-11-26 07:38 -0800
Subjecthelp
Message-ID<9b517af8-3f8a-4af4-a948-fbafd0b548b8n@googlegroups.com>
good afternoon.
I have a question to ask, due to lack of documentation on VO.
method VaBene() class DemPagante_Maschera

oNotice := NoticeReceipt_Mask{self:Owner,aParam}  
FabCenterWindow(oNotice)
oNotice:Show()  

In this particular case I alert the user that a receipt is about to be printed, indicating the patient's name and the amount. 
And it starts via the classic 'Okay" button. At the end there is the line 
self:Dialog() 
which takes me back to the Vabene method of the DemPagante_Maschera Class
Is it correct to write in this method
oNotice:Close() ?
I hope I managed to explain myself.
Thanks

Translated with www.DeepL.com/Translator (free version)

[toc] | [next] | [standalone]


#13480

FromJohnMartens <martens@tennishulp.info>
Date2021-11-26 16:56 +0100
Message-ID<snr031$p0g$1@dont-email.me>
In reply to#13479
Hi Aurora,

Ik think that the user will close the NoticeReceipt_Mask by clicking the 
OK button and that the NoticeReceipt_Mask is app modal. In that case the 
window is closed by the user and the code will procees after the 
oNotice:Show() line with the next thing to do.

In this case oNotice:Close() after the Show() line will cause problems 
because it tries to close a window that is already closed by the user.

If the NoticeReceipt_Mask window is not app modal it will be on the 
users screen after the show but your VaBene() method will proceed and 
the NoticeReceipt_Mask window might not be closed at all if you do not 
call oNotice:Close() that window

So it depends on you. Make the window app modal so the user must press 
OK to start the print. Or make it just a progress window which cannot me 
closed by the user and has Show() and Close() in tha VaBene() method.
Status updates on the progress in VaBene() could be shown if 
NoticeReceipt_Mask has a ShowProgress() mathod that shows the progress 
info on it's window

Is this of any help ?

John



Op 26-11-2021 om 16:38 schreef aurora baccio:
> good afternoon.
> I have a question to ask, due to lack of documentation on VO.
> method VaBene() class DemPagante_Maschera
> 
> oNotice := NoticeReceipt_Mask{self:Owner,aParam}
> FabCenterWindow(oNotice)
> oNotice:Show()
> 
> In this particular case I alert the user that a receipt is about to be printed, indicating the patient's name and the amount.
> And it starts via the classic 'Okay" button. At the end there is the line
> self:Dialog()
> which takes me back to the Vabene method of the DemPagante_Maschera Class
> Is it correct to write in this method
> oNotice:Close() ?
> I hope I managed to explain myself.
> Thanks
> 
> Translated with www.DeepL.com/Translator (free version)
> 

[toc] | [prev] | [next] | [standalone]


#13483

Fromaurora baccio <aurorabaccio@gmail.com>
Date2021-11-28 02:21 -0800
Message-ID<c8058ad6-d0a9-44de-9f6c-030048be0677n@googlegroups.com>
In reply to#13480
Il giorno venerdì 26 novembre 2021 alle 16:56:18 UTC+1 JohnMartens ha scritto:
> Hi Aurora, 
> 
> Ik think that the user will close the NoticeReceipt_Mask by clicking the 
> OK button and that the NoticeReceipt_Mask is app modal. In that case the 
> window is closed by the user and the code will procees after the 
> oNotice:Show() line with the next thing to do. 
> 
> In this case oNotice:Close() after the Show() line will cause problems 
> because it tries to close a window that is already closed by the user. 
> 
> If the NoticeReceipt_Mask window is not app modal it will be on the 
> users screen after the show but your VaBene() method will proceed and 
> the NoticeReceipt_Mask window might not be closed at all if you do not 
> call oNotice:Close() that window 
> 
> So it depends on you. Make the window app modal so the user must press 
> OK to start the print. Or make it just a progress window which cannot me 
> closed by the user and has Show() and Close() in tha VaBene() method. 
> Status updates on the progress in VaBene() could be shown if 
> NoticeReceipt_Mask has a ShowProgress() mathod that shows the progress 
> info on it's window 
> 
> Is this of any help ? 
> 
> John 
> 
> 
> 
> Op 26-11-2021 om 16:38 schreef aurora baccio:
> > good afternoon. 
> > I have a question to ask, due to lack of documentation on VO. 
> > method VaBene() class DemPagante_Maschera 
> > 
> > oNotice := NoticeReceipt_Mask{self:Owner,aParam} 
> > FabCenterWindow(oNotice) 
> > oNotice:Show() 
> > 
> > In this particular case I alert the user that a receipt is about to be printed, indicating the patient's name and the amount. 
> > And it starts via the classic 'Okay" button. At the end there is the line 
> > self:Dialog() 
> > which takes me back to the Vabene method of the DemPagante_Maschera Class 
> > Is it correct to write in this method 
> > oNotice:Close() ? 
> > I hope I managed to explain myself. 
> > Thanks 
> > 
> > Translated with www.DeepL.com/Translator (free version) 
> >
Thank you for your response, which is extremely important to me.
Basically you suggest me to insert in the postinit method of the window
self:SetModal(True).
In this case the closing of the window happens from the method 'VaBene' that closes with the classic 'EndDialog'. 
The window doesn't remain open and doesn't cause problems.
Otherwise in the line following the Show() I must insert the closing command.
Correct?
Thanks
Aurora Baccio

[toc] | [prev] | [next] | [standalone]


#13486

FromJohnMartens <martens@tennishulp.info>
Date2021-11-29 18:50 +0100
Message-ID<so33tf$9u2$1@dont-email.me>
In reply to#13483
Hi Aurora,

The AppModal setting depends on what you want

You will always need the Show() of the window.
Then you have 2 options

1 You want the user to do something before you want to continue after 
the Show() line. Eg do some settings like selecting an output directory 
or agree on the parameters the user will continue on. In that case you 
want an AppModal window so it will prevent all other actions in your app 
until the user made up it's mind. In this case the window will and 
itself with EndWindow(0 in its last line of code where you make sure the 
users has set the right parameters. In this case you wil NOT have any 
Close() in the method that dis the Show() of the window

2 You just want to have a progress windows. In that case the window need 
the be NOT AppModal. The code will proceed after the Show() and by 
calling something like oNotice:ShowMyProgress(cTextToShowOnTheWindow) 
the progress is shown to the user.
In this case when the job is finished and there is no further progress 
to show oNotice:EndWindow() (or another close of the window depending on 
the type of window)

Does this help ?

John



Op 28-11-2021 om 11:21 schreef aurora baccio:
> Il giorno venerdì 26 novembre 2021 alle 16:56:18 UTC+1 JohnMartens ha scritto:
>> Hi Aurora,
>>
>> Ik think that the user will close the NoticeReceipt_Mask by clicking the
>> OK button and that the NoticeReceipt_Mask is app modal. In that case the
>> window is closed by the user and the code will procees after the
>> oNotice:Show() line with the next thing to do.
>>
>> In this case oNotice:Close() after the Show() line will cause problems
>> because it tries to close a window that is already closed by the user.
>>
>> If the NoticeReceipt_Mask window is not app modal it will be on the
>> users screen after the show but your VaBene() method will proceed and
>> the NoticeReceipt_Mask window might not be closed at all if you do not
>> call oNotice:Close() that window
>>
>> So it depends on you. Make the window app modal so the user must press
>> OK to start the print. Or make it just a progress window which cannot me
>> closed by the user and has Show() and Close() in tha VaBene() method.
>> Status updates on the progress in VaBene() could be shown if
>> NoticeReceipt_Mask has a ShowProgress() mathod that shows the progress
>> info on it's window
>>
>> Is this of any help ?
>>
>> John
>>
>>
>>
>> Op 26-11-2021 om 16:38 schreef aurora baccio:
>>> good afternoon.
>>> I have a question to ask, due to lack of documentation on VO.
>>> method VaBene() class DemPagante_Maschera
>>>
>>> oNotice := NoticeReceipt_Mask{self:Owner,aParam}
>>> FabCenterWindow(oNotice)
>>> oNotice:Show()
>>>
>>> In this particular case I alert the user that a receipt is about to be printed, indicating the patient's name and the amount.
>>> And it starts via the classic 'Okay" button. At the end there is the line
>>> self:Dialog()
>>> which takes me back to the Vabene method of the DemPagante_Maschera Class
>>> Is it correct to write in this method
>>> oNotice:Close() ?
>>> I hope I managed to explain myself.
>>> Thanks
>>>
>>> Translated with www.DeepL.com/Translator (free version)
>>>
> Thank you for your response, which is extremely important to me.
> Basically you suggest me to insert in the postinit method of the window
> self:SetModal(True).
> In this case the closing of the window happens from the method 'VaBene' that closes with the classic 'EndDialog'.
> The window doesn't remain open and doesn't cause problems.
> Otherwise in the line following the Show() I must insert the closing command.
> Correct?
> Thanks
> Aurora Baccio
> 

[toc] | [prev] | [next] | [standalone]


#13482

From"Wolfgang Riedmann" <wriedmann@gmail.com>
Date2021-11-27 18:07 +0100
Message-ID<j0f6uoFm8ufU1@mid.individual.net>
In reply to#13479
Hi Aurora,

> I have a question to ask, due to lack of documentation on VO.

I'm really sorry, but your question has nothing to do with lack of
documentation in VO.

If you would close a datawindow, use the method EndWindow(), and if
your window is a dialogwindow, you have to use the method EndDialog().

So you have to write

self:EndDialog( IDOK )

if DemPagante_Maschera is a DialogWindow, or

self:EndWindow()

if DemPagante_Maschera is a DataWindow.

Wolfgang


> method VaBene() class DemPagante_Maschera
> 
> oNotice := NoticeReceipt_Mask{self:Owner,aParam}  
> FabCenterWindow(oNotice)
> oNotice:Show()  
> 
> In this particular case I alert the user that a receipt is about to
> be printed, indicating the patient's name and the amount.  And it
> starts via the classic 'Okay" button. At the end there is the line
> self:Dialog() which takes me back to the Vabene method of the
> DemPagante_Maschera Class Is it correct to write in this method
> oNotice:Close() ?
> I hope I managed to explain myself.
> Thanks
> 
> Translated with www.DeepL.com/Translator (free version)



-- 

[toc] | [prev] | [next] | [standalone]


#13484

Fromaurora baccio <aurorabaccio@gmail.com>
Date2021-11-28 02:25 -0800
Message-ID<2a24bf13-b6c7-407b-beae-605499e7c3b5n@googlegroups.com>
In reply to#13482
Il giorno sabato 27 novembre 2021 alle 18:07:39 UTC+1 Wolfgang Riedmann ha scritto:
> Hi Aurora,
> > I have a question to ask, due to lack of documentation on VO.
> I'm really sorry, but your question has nothing to do with lack of 
> documentation in VO. 
> 
> If you would close a datawindow, use the method EndWindow(), and if 
> your window is a dialogwindow, you have to use the method EndDialog(). 
> 
> So you have to write 
> 
> self:EndDialog( IDOK ) 
> 
> if DemPagante_Maschera is a DialogWindow, or 
> 
> self:EndWindow() 
> 
> if DemPagante_Maschera is a DataWindow. 
> 
> Wolfgang
> > method VaBene() class DemPagante_Maschera 
> > 
> > oNotice := NoticeReceipt_Mask{self:Owner,aParam} 
> > FabCenterWindow(oNotice) 
> > oNotice:Show() 
> > 
> > In this particular case I alert the user that a receipt is about to 
> > be printed, indicating the patient's name and the amount. And it 
> > starts via the classic 'Okay" button. At the end there is the line 
> > self:Dialog() which takes me back to the Vabene method of the 
> > DemPagante_Maschera Class Is it correct to write in this method 
> > oNotice:Close() ? 
> > I hope I managed to explain myself. 
> > Thanks 
> > 
> > Translated with www.DeepL.com/Translator (free version)
> --

Dear Mr. Riedman,
what does self:enddialog( IDOK) mean?
The question refers to the word IDOK.
Does it mean the name assigned to the window ?
thanks 
Aurora Baccio

[toc] | [prev] | [next] | [standalone]


#13485

From"Wolfgang Riedmann" <wriedmann@gmail.com>
Date2021-11-28 14:38 +0100
Message-ID<j0hf24F4qh1U1@mid.individual.net>
In reply to#13484
Hi Aurora,

> what does self:enddialog( IDOK) mean?
> The question refers to the word IDOK.
> Does it mean the name assigned to the window ?

the method EndDialog() of the dialogWindow class has one numeric
parameter.
This parameter is assigned to the :Result instance variable.

IDOK is a constant that has the value of 1, whereas IDCANCEL has the
value of 2.

This is a sample:

class MyDialog inherit DialogWindow

method OkButton() class MyDialog

	self:EndDialog( IDOK )

	return nil

method CancelButton() class MyDialog

	self:EndDialog( IDCANCEL )

	return nil

.....
local oDlg as MyDialog

oDlg := MyDialog{ self }
oDlg:Show()
if oDlg:Result == IDOK
  // do something because the dialog was closed with the OK button
endif

HTH

Wolfgang






-- 

[toc] | [prev] | [standalone]


Back to top | Article view | comp.lang.clipper.visual-objects


csiph-web