Hi,
I'm aware that the report control isn't the fastest object of the codejock suite. In this case I don't have large datasets. I tested with 1000 lines, and came to the conclusion that it is acceptable. I has quite some power in it. With drag and drop you can get totals and subtotals as you want.
Doing the same in a dcbrowse will certainly be possible. However this would take me maybe two weeks of work or even more. Now I had spend only 3 hours.
Tom, are you a speaker at the Devcon in the Netherlands in November?
Browse/report with accordeon
Re: Browse/report with accordeon
this is when using "single additem" with Listview ...unixkd wrote:Try to populate 5000 items on the codejock report control, you will come back home quickly.
when using LVS_OWNERDATA and LVN_GETDISPINFO you can show Array with 100000 in < 1 Sec.
(to build Array take more time ... )
hm ... when talk about "SKIP" i agree ... but this is also the "Problem" with XbpBrowse() using a "DbSkipper".unixkd wrote:In terms of performance on large datasets nothing close to Xbase++ in the market today except you are coding in C/C++.
when "browse" a big SQL-Result Set with a "Skipper" does not make Sence ... better to divide Query with LIMIT and OFFSET into Parts.
Listview does have LVN_ODCACHEHINT Notify Event and NMLVCACHEHINT Structure does give you
Code: Select all
//
// cache the data pCacheHint->iFrom to pCacheHint->iTo ...
//
nFrom := st:iFrom
nTo := st:iTo
cText := "Cache from "+LTRIM(STR(nFrom))+" to "+LTRIM(STR(nTo))
look for new Demo Source at http://bb.donnay-software.com/donnay/vi ... f=7&t=1583
greetings by OHR
Jimmy
Jimmy
Re: Browse/report with accordeon
Hi Jimmy
What do you mean by:
this is when using "single additem" with Listview ...
when using LVS_OWNERDATA and LVN_GETDISPINFO you can show Array with 100000 in < 1 Sec.
(to build Array take more time ... )
I noticed that all codejock controls in my application takes time for the dialog to show up.
Thanks.
Joe
What do you mean by:
this is when using "single additem" with Listview ...
when using LVS_OWNERDATA and LVN_GETDISPINFO you can show Array with 100000 in < 1 Sec.
(to build Array take more time ... )
I noticed that all codejock controls in my application takes time for the dialog to show up.
Thanks.
Joe
Re: Browse/report with accordeon
hi,
back to a old Thread ... where i just working on
i found out that XbpTreeviewItem() have no Handle ( o:GetHwnd() ) so it seem me not possible to "replace" it.
i also had to change some Design in my native DXE_Treeview() to use it together with DXE_Listview()
but Windows Controls can more than Xbase++ let us doso i can use it this Way
something like this can be used for every 2D*** Windows Control
*** Parent which use o:AddiTem to get Child
---
using LVS_OWNERDATA as Style let you use your own Data e.g. Array ... but Data must be display somehow.
have you see Demo Source ? http://bb.donnay-software.com/donnay/vi ... f=7&t=1583
think about Ownerdraw ...aInfo[1][1] does contain a "Index" ...
older Windows Controls, like XbParts, do not have "data binding" ... but you can simulate it with a "Index".
but how to display data now ... i have to check a Event (like o:subscribeEvent() )this is when LVN_GETDISPINFO Event is fired to display data where i need to react onlike Ownerdraw i have Control "what" to Display ... just need "Index" to locate my Data to display
back to a old Thread ... where i just working on

i found out that XbpTreeviewItem() have no Handle ( o:GetHwnd() ) so it seem me not possible to "replace" it.
i also had to change some Design in my native DXE_Treeview() to use it together with DXE_Listview()
Code: Select all
CLASS DXE_Report ftom DXE_Treeview, DXE_Listview
each o:AddItem need some Windows Call e.g. reserve Memory. using ActiveX will increase time.unixkd wrote:What do you mean by:
but Windows Controls can more than Xbase++ let us do
Code: Select all
INLINE METHOD LB_InitStorage(nNum,nBytes)
/****************************************************************
* Allocates memory for the specified number of items and their associated strings.
*
* wParam
* The number of items to add.
*
* lParam
* The amount of memory, in bytes, to allocate for item strings.
*
* Return Value
* If an error occurs, the return value is LB_ERR.
*
*****************************************************************/
RETURN @User32:SendMessageA(::hLbox,LB_INITSTORAGE,nNum,nBytes )
Code: Select all
INLINE METHOD _AddBigArray(aArray)
LOCAL iMax := LEN(aArray)
LOCAL nLen := 0
LOCAL nBytes
// find max Item Lenght
//
AEval( aArray, {|x,i| IF(LEN(x)>nLen,nLen:=LEN(x),NIL) } )
// reserve Memory
//
nBytes := iMax * nLen
::LB_InitStorage(iMax,nBytes)
// store hole Array for (my) internal use
//
::aItems := ACLONE( aArray )
// AddString to Listbox
//
// Note : when Ownerdraw DATA, Window might limited
// so you need you ::NumItems() of LB_ADDSTRING
//
// ::LB_SetItemData(nIndex,cString) will just
// "replace" DATA when need to display
//
AEval( ::aItems, {|x,i| @User32:SendMessageA( ::hLBox,LB_ADDSTRING,0, x) } )
RETURN
*** Parent which use o:AddiTem to get Child
---
using LVS_OWNERDATA as Style let you use your own Data e.g. Array ... but Data must be display somehow.
have you see Demo Source ? http://bb.donnay-software.com/donnay/vi ... f=7&t=1583
think about Ownerdraw ...
Code: Select all
Xbase++ Syntax :
{| oPS, aInfo, self | ... }
older Windows Controls, like XbParts, do not have "data binding" ... but you can simulate it with a "Index".
but how to display data now ... i have to check a Event (like o:subscribeEvent() )
Code: Select all
// add for LVS_OWNERDATA
//
::SetLvNotifyCB( LVN_GETDISPINFO , {|o,notify_code,lp| ::OnDISPINFO(o,lp) } )
Code: Select all
METHOD DXE_ArrayView:OnDISPINFO(o,lp)
...
IF LEN(::aSource) > 0 // My Array
st := NMLVDISPINFO():New() // Windows Structure
st:_link_(lp,.F.)
// need for 64bit OS()
//
st:item:pszText := REPLICATE(CHR(0),255)
st:item:cchTextMax := 255
// ZERO-based :iItem and :iSubItem
//
nRec := st:item:iItem+1 // Array ZERO-based+1
nSub := st:item:iSubItem+1 // always 0 when Ownerdraw ?
// use My Array
//
ctext := ::aSource[nRec][nSub] // here i use "Index" on My Array to get Data
greetings by OHR
Jimmy
Jimmy