Doing Master detail in the best way..
Moderator: Rathinagiri
Re: Doing Master detail in the best way..
Yes I understand - however frmJournal and frmJournals is valid for me in that sense (one for a single record and the other for the whole file..). Anyway I'll try to make a change for the better. Thanks Esgici.
Charly
Argentina, Hobbyist developer, Clipper/Delphi/PHP/Progress
Argentina, Hobbyist developer, Clipper/Delphi/PHP/Progress
- esgici
- Posts: 4543
- Joined: Wed Jul 30, 2008 9:17 pm
- DBs Used: DBF
- Location: iskenderun / Turkiye
- Contact:
Re: Doing Master detail in the best way..
Hola Charly
Let me correct my own fault first :
This is because frmJournals not defined in Journal.prg.
Again,
So we need add this line:
to top of Journal.prg.
A little caution : Journal.prg has two STATIC variable definition statement at top. New (DECLARE) statement must be come after these two lines.
Saludos
--
Esgici
Let me correct my own fault first :
And :esgici wrote: IMHO
frmJournal.GridMaster.Refresh
is correct than
frmJournal.GridMaster.Refresh(.t.)
but second syntax doesn't produce any error and again I'm not sure functionality is the same for this two syntax; please check it.
Regarding syntax error on line 125 of Journal.prg :HMG Doc wrote:
Syntax of refresh in GRID :
Refresh([lValue])
Refresh Method: Refresh Content For a Data-Bound Control
Syntax:
<WindowName>.<ControlName>.Refresh
Data-bound Grid supports an optional logical parameter. When set to .t., the selected logical records is preserved.
This is because frmJournals not defined in Journal.prg.
Again,
HMG Doc wrote:DECLARE WINDOW
Declares a Window Name
DECLARE WINDOW <WindowName>
A window must be declared using this command, if you need to refer to it prior
its definition in code, or when you refer to it in a different .prg file from
the one it was defined using semi-oop syntax.
So we need add this line:
Code: Select all
DECLARE WINDOW frmJournalsA little caution : Journal.prg has two STATIC variable definition statement at top. New (DECLARE) statement must be come after these two lines.
Saludos
--
Esgici
Viva INTERNATIONAL HMG 
Re: Doing Master detail in the best way..
EXCELLENT Esgici!! I tried
PRIVATE frmJournals
but DECLARE WINDOW is what I needed.
For some reason in the final product it works allright but you have taught me another HMG trick. Thanks a lot!
PRIVATE frmJournals
but DECLARE WINDOW is what I needed.
For some reason in the final product it works allright but you have taught me another HMG trick. Thanks a lot!
Charly
Argentina, Hobbyist developer, Clipper/Delphi/PHP/Progress
Argentina, Hobbyist developer, Clipper/Delphi/PHP/Progress
- esgici
- Posts: 4543
- Joined: Wed Jul 30, 2008 9:17 pm
- DBs Used: DBF
- Location: iskenderun / Turkiye
- Contact:
Re: Doing Master detail in the best way..
Good news, thanks 
Saludos
--
Esgici
Saludos
--
Esgici
Viva INTERNATIONAL HMG 