|
| Close a report |
 |
Mon, 13 Aug 2007 14:11:30 +020 |
Ken Mayer writes in its "The dBase Plus Tutorial", Phase V, page 4,
how
one can close the current form in an applicaton.
How can I do the same in a report?
A report does not have onGotFocus and none onLostFocus Event.
Thanks for your response.
|
| Post Reply
|
| Re: Close a report |
 |
Tue, 14 Aug 2007 00:54:35 -040 |
In article <T90IQVa3HHA.696@news-server>, kutanner@bluewin.ch says...
> Ken Mayer writes in its "The dBase Plus Tutorial", Phase V, page
4, how
> one can close the current form in an applicaton.
> How can I do the same in a report?
> A report does not have onGotFocus and none onLostFocus Event.
> Thanks for your response.
>
> Kurt Tanner
>
Kurt,
Instead of FORM.close( ) you can use REPORT.release( ). However, be sure
you are doing that at a time when you really want to get rid of the
report (for instance, in a pushbutton or when a form closes). If you do
REPORT.render( ) and then REPORT.release( ), your report will be gone in
the blink of an eye. <g>
--
Geoff Wass [dBVIPS]
Montréal, Québec, Canada
.|.|.| dBASE info at http://geocities.com/geoff_wass |.|.|.
.|.|.| ---------------------------------------------------------- |.|.|.
|
| Post Reply
|
| Re: Close a report |
 |
Tue, 14 Aug 2007 20:36:24 +020 |
Geoff
Thanks for your answer.
I went another way. I used Streamframe1_onRender for:
if type("_app.framewin") # "U"
_app.framewin.currentForm = this.parent.parent
endif
and form_close for:
if type("_app.framewin.currentForm") # "U"
_app.framewin.currentForm := null
endif
return NEUREPORT::close()
It seems that works well.
|
| Post Reply
|
| Re: Close a report |
 |
Wed, 15 Aug 2007 01:41:01 -040 |
In article <JViG#Qq3HHA.1216@news-server>, kutanner@bluewin.ch says...
> Geoff
> Thanks for your answer.
> I went another way. I used Streamframe1_onRender for:
> if type("_app.framewin") # "U"
> _app.framewin.currentForm = this.parent.parent
> endif
>
> and form_close for:
> if type("_app.framewin.currentForm") # "U"
> _app.framewin.currentForm := null
> endif
> return NEUREPORT::close()
>
> It seems that works well.
>
> Kurt
>
Kurt,
Maybe I am misunderstanding things, but I don't see how that closes a
report for you. All you are doing is creating a reference to a report in
_app.frameWin and then deleting the _reference_, nothing related to the
report.
--
Geoff Wass [dBVIPS]
Montréal, Québec, Canada
.|.|.| dBASE info at http://geocities.com/geoff_wass |.|.|.
.|.|.| ---------------------------------------------------------- |.|.|.
|
| Post Reply
|
| Re: Close a report |
 |
Wed, 15 Aug 2007 09:58:03 +020 |
Geoff Wass [dBVIPS] schrieb:
> Maybe I am misunderstanding things, but I don't see how that closes a
> report for you. All you are doing is creating a reference to a report in
> _app.frameWin and then deleting the _reference_, nothing related to the
> report.
---------------------------
My English knowledge is small. Therefore I wrote only the most
necessary. Excuse me!
The command to close the report comes from a menu item:
function M_AKTFORMSCHLIESEN_onClick
// Schliessen des aktuellen Formulars, sofern vorhanden
if type( "_app.framewin.currentForm" ) # "U" and ;
type( "_app.framewin.currentForm" ) # "NULL" //==
"O"
_app.framewin.currentForm.close()
else
msgBox("Das im Moment geöffnete Formular kann auf desem Weg
nicht;
geschlossen werden", "Geht nicht", 64)
endif
return
Kurt
|
| Post Reply
|
|
|
|
|
|
|
|
|
|