bug browse.prg version 23/11/2011
Moderator: Rathinagiri
bug browse.prg version 23/11/2011
error no Exported variable: ClassName:nCellRowIndex
error no Exported variable: ClassName:nNew also nDiff
browse.prg is from abstractgrid
virtualgrid is from abstractgrid
Virtualgrid has data nNew init 0 but browse.prg not
You must add data nCellRowIndex and nNew and nDiff to browse.prg
(look at line 342 in browse.prg. It uses ::nNew but there is no line DATA nNew init so it must be added)
error no Exported variable: ClassName:nNew also nDiff
browse.prg is from abstractgrid
virtualgrid is from abstractgrid
Virtualgrid has data nNew init 0 but browse.prg not
You must add data nCellRowIndex and nNew and nDiff to browse.prg
(look at line 342 in browse.prg. It uses ::nNew but there is no line DATA nNew init so it must be added)
Re: bug browse.prg version 23/11/2011
Which is the sample that gives you problem ?
JosK wrote:error no Exported variable: ClassName:nCellRowIndex
error no Exported variable: ClassName:nNew also nDiff
browse.prg is from abstractgrid
virtualgrid is from abstractgrid
Virtualgrid has data nNew init 0 but browse.prg not
You must add data nCellRowIndex and nNew and nDiff to browse.prg
(look at line 342 in browse.prg. It uses ::nNew but there is no line DATA nNew init so it must be added)
Re: bug browse.prg version 23/11/2011
There are some bugs in browse.prg. (I have correct some bugs in browse.prg, mostly DATA used in class but not defined. I have not uploaded the code)mrduck wrote:Which is the sample that gives you problem ?
JosK wrote:error no Exported variable: ClassName:nCellRowIndex
error no Exported variable: ClassName:nNew also nDiff
browse.prg is from abstractgrid
virtualgrid is from abstractgrid
Virtualgrid has data nNew init 0 but browse.prg not
You must add data nCellRowIndex and nNew and nDiff to browse.prg
(look at line 342 in browse.prg. It uses ::nNew but there is no line DATA nNew init so it must be added)
I like virtualgrid.prg more so i don't look at bugs in browse.prg anymore.
You can see my other posts for a nice example with virtualgrid, tab-pages, jkgrid/virtualgrid, setkey, layoutbox, insets. (you must expand youre screen and then you see wat insets does.
Re: bug browse.prg version 23/11/2011
Can you please attach a zip file with all the modifies source code ? It's very time consuming extracting the coe from the messages posted.
Thanks
Thanks
Re: bug browse.prg version 23/11/2011
the zip (browse, virtualgrid, abstractgrid)
- Attachments
-
- HMGJK.ZIP
- (16.64 KiB) Downloaded 251 times
Re: bug browse.prg version 23/11/2011
Josk, the common language for comments in the sources should be english, please.
I don´t understand this change in browse.prg:
In Virtualgrid you deleted the methods AllowAppend() and AllowDelete() because they seem to do do nothing (now), but they are there because of HMG3 compatibility!
I don´t understand this change in browse.prg:
Code: Select all
//::nNew := y + 1 //error line ->no exported variable classname()nNew
::nNew := y+1
Re: bug browse.prg version 23/11/2011
with the browse.prg of 23/11/2011 i get the error no exported variable classname() nNew add that lineRicci wrote:Josk, the common language for comments in the sources should be english, please.
I don´t understand this change in browse.prg:In Virtualgrid you deleted the methods AllowAppend() and AllowDelete() because they seem to do do nothing (now), but they are there because of HMG3 compatibility!Code: Select all
//::nNew := y + 1 //error line ->no exported variable classname()nNew ::nNew := y+1
therefore i have add nNew, nDiff .. to browse.prg:
DATA cClass INIT "BROWSE"
DATA QAbstractItemModel INIT NIL
DATA nCellRowIndex INIT 0
DATA nCellColIndex INIT 0
DATA aStruct INIT NIL
DATA QHeaderView INIT NIL
DATA oSize INIT NIL
DATA nCX INIT 0
DATA nCY INIT 0
DATA QAbstractItemDelegate INIT NIL
DATA QItemSelectionModel INIT NIL
DATA nCurrent INIT NIL
DATA nNew INIT NIL
DATA nDiff INIT NIL
DATA nMasterRecNo INIT NIL
DATA nRecordCount INIT 0
DATA oQHeaderView INIT NIL
DATA nValue INIT NIL
DATA bOnDblClick INIT NIL
Re: bug browse.prg version 23/11/2011
I think that BROWSE was somehow deemed obsolete by Rathinagiri when he revised code of grid and virtualgrid.
Infact there is no samples/browse.
Probably we should complete this migration.... please wait till next tuesday and I will try to do a resume on the subject.
Infact there is no samples/browse.
Probably we should complete this migration.... please wait till next tuesday and I will try to do a resume on the subject.
Re: bug browse.prg version 23/11/2011
I also did some work on abstractgrid / virtualgrid / grid / browse but samples\browse was already deleted....mrduck wrote: Infact there is no samples/browse.
Next week I'll check...
Re: bug browse.prg version 23/11/2011
Hi JosK,JosK wrote:virtualgrid
I had a look at your changes.
ABSTRACTGRID:
I can't understand your comment (DEZE EVAL DOEN WE ALLEEN BIJ INVOEREN EN NIET BIJ OPBOUWEN SCHERM)... can you please exaplain why you removed the eval ?
Perhaps because it is already done in DoKeyboardEvents ?
First of all I'd like to suggest to you and other developers reading the thread that when we need to "specialize" a hmg4 class we may inherit from the base one and override the specific methods.JosK wrote:JKgrid
For example, in the case of JKgrid I'd do:
Code: Select all
CLASS JKGRID FROM ABSTRACTGRID
METHOD DoCellKeyBoardEvents
ENDCLASS
JKGrid has a different handling of keypresses during editing, it actually adds some features... so I'd write:
Code: Select all
METHOD xxx
// handle special new cases
super:xxx() // handle the standard cases
Later for the contents...