Solved

Flexgrid Compare Event

Posted on 1998-12-17
1
679 Views
Last Modified: 2006-11-17
Does anyone have an example of how to use the "Compare" event of a flexgrid to sort rows. I want to eventually be able to sort by date. Any ideas?
0
Comment
Question by:gcw
1 Comment
 
LVL 8

Accepted Solution

by:
MikeP090797 earned 100 total points
ID: 1451163
Dim S1 as string, s2 as string
G1.Col=1
G1.Row = row1
S1=G1.Text
G1.Row=row2
S2=G1.Text

IF DateValue(S1)>DateValue(S2) then  cmp=-1
IF DateValue(S1)=DateValue(S2) then  cmp=0
IF DateValue(S1)<DateValue(S2) then  cmp=1



0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

828 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question