Unexpected Column sort delay


[ Follow Ups ] [ Post Followup ] [ Signature.net Forum ]

Posted by Grant on May 18, 2016 at 10:10:43:

In WDL programs with a ListView, I've occasionally used LVN.ITEMCHANGED

! Set notify filter
cosCWnd$ = cosDlghDlg$
cosCtlText$ = inteld(IDC.LISTVIEW.01) + inteld(NM.DBLCLK) + FM.NMLISTVIEW.MIN$
gosub COS.AppendNotifyFilter2

cosCtlText$ = inteld(IDC.LISTVIEW.01) + inteld(LVN.COLUMNCLICK) + FM.NMLISTVIEW.MIN$
gosub COS.AppendNotifyFilter2

cosCtlText$ = inteld(IDC.LISTVIEW.01) + inteld(LVN.ITEMCHANGED) + FM.NMLISTVIEW.MIN$
gosub COS.AppendNotifyFilter2
-------------------------------
Case IDC.LISTVIEW.01 ! list box event notification
Gosub CW.ListView.UnpackMin ! Retrieves cosItemId and cosSubItem only

If (cosCommand EQ LVN.ITEMCHANGED)
GOSUB GetSelectedDetailRecord
BREAK
Endif

If cosCommand EQ NM.DBLCLK
GOSUB EditTheRecord
Break
ENDIF

If cosCommand = LVN.COLUMNCLICK
cosState = 3 ! Toggle sort order with each click
cosItemID = cosSubItem
gosub SetListSort
break
endif
-----------------------------------------

What I found was that LVN.COLUMNCLICK seems to cause a LVN.ITEMCHANGED on each record in the list. Which in turn, caused a Comet read of the data file. Unnoticable when the list was short, but a 20-30 second puzzlement when a 2000+ line list was resorted.

The LVN.ITEMCHANGED wasn't needed. It was junk from the cloning IBS to IBS to IBS.


Follow Ups:



Post a Followup

Name:
E-Mail:

Subject:

What is the name of the main Signature System's Product?  

Comments:

Optional Link URL:
Link Title:
Optional Image URL:

You may attach up to 5 files to your followup (see below):





Each file can be a maximum of 1MB in length Uploaded files will be purged from the server on a regular basis.


[ Follow Ups ] [ Post Followup ] [ Signature.net Forum ]