Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Sorting grid on Click header
Message
From
05/04/2020 12:01:27
Luis Santos
Biglevel-Soluções Informáticas, Lda
Portugal
 
 
To
05/04/2020 11:16:57
Antonio Lopes (Online)
BookMARC
Coimbra, Portugal
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
01673953
Message ID:
01673963
Views:
43
>>Hello community,
>>
>> [...]
>>
>>someone could give me the reason for that error.
>
>Is it possible that N is sometimes greater than the number of index tags on your cursor? I tried to
>
set order to 5
>on a table with 3 tags and got the same error.
>
>Hello Dragan
>
> [...]
>my Cursor have fields type char,boolean,memo and numeric, i don´t know if some of theses fields type are supported ?
>

Luís, I would say that Dragan pointed you into the right direction.

Assuming that your grid holds the fields of your cursor in their natural order, you must create indexes for all of the first 11 fields, regardless of their type, otherwise the code you're using will not work at all.

Hello Antonio,

Thanks for your reply.

My cursor have 21 fields (see attachment).
For i=1 To PDU_FCTEXM.Pageframe1.Udcpage3.Grid1.ColumnCount && the result of PDU_FCTEXM.Pageframe1.Udcpage3.Grid1.ColumnCount must be 21
	If Inlist(i,1,2,3,4,5,6,7,8,9,10,11)  &&choice only the column to sort asc/descending-grid can have any columnCount
		aa="PDU_FCTEXM.Pageframe1.Udcpage3.Grid1.column"+Trans(i)+".header1"
		Bindevent(&aa,"click",oHandler,"mygridinit",1)
	Endif
Endfor
I suppose the result of : For i=1 To PDU_FCTEXM.Pageframe1.Udcpage3.Grid1.ColumnCount must be equal to 21 fields
when you mencioned : "you must create indexes for all of the first 11 fields, regardless of their type, otherwise the code you're using will not work at all."
But i suppose the indexes have been create for all of the fields of my cursor.
When i click on column8, the SYS(21) return 8.

do you mean that before : set order to N in mybolistex, i must declare:
INDEX ON N TO N
set order to N in mybolistex

Sorry but i not understand, could you help me.

Best regards,
Luis
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform