All sorting and selection with quickreports needs to be done outside of 
Quickreport.  For example, you could put a query component with the SQL code 
showing what you want (Select....) and the sort order (OrderBy...) and make it 
execute when the QR form is created.

Other methods would be to use a table with a secondary index sorting the 
records the way you want and using filters to remove unwanted records.

Having the user determine the sort sequence requires that you select the query 
or Table index before you run your quick report.

In the case of a query, use a blank query component and in the Onshow event of 
the form load the SQL your report needs and then execute the query.  For 
example:

If SortbyKey = True then Query1.SQL.Add('Select * from Table1 OrderBy Key')
Else Query1.SQL.Add('Select * from Table1 OrderBy Date');
Query1.Open;

Handling dates requires that you work on the data in it's raw form. You may see 
the data in a month/day/year format but I am guessing that this is not the way 
it is stored. If your data is in a Year/Month/Day format then you will need to 
create a temporary field to store the Day and another to store the month and 
the Year.  Then you can use the orderby to sort by Day/Month/year.

Hope this helps!

Tom Nesler


-----Original Message-----
From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf Of Arsen 
Khachatryan
Sent: Monday, July 10, 2006 2:59 PM
To: [email protected]
Subject: [delphi-en] Urgent Date format and QReport list order by


Hi all people how are you?
I have a few problem in delphi and dopn“t know what to
do?

How can I order in quich report the lists with date or
price or names?? is it possible put anything and if
user want to order by price or by date then print.

And second in query the default date format is
MM/DD/YY and when I want to search by date I have to
put MM/DD/YY, how can I change the format,that the
user can search it like DD/MM/YY?

Please help me with this if someone can.

Thank You a lot


                
---------------------------------
Yahoo! Music Unlimited - Access over 1 million songs.Try it free. 

[Non-text portions of this message have been removed]




-----------------------------------------------------
Home page: http://groups.yahoo.com/group/delphi-en/
To unsubscribe: [EMAIL PROTECTED] 
Yahoo! Groups Links



 



------------------------ Yahoo! Groups Sponsor --------------------~--> 
Check out the new improvements in Yahoo! Groups email.
http://us.click.yahoo.com/6pRQfA/fOaOAA/yQLSAA/i7folB/TM
--------------------------------------------------------------------~-> 

-----------------------------------------------------
Home page: http://groups.yahoo.com/group/delphi-en/
To unsubscribe: [EMAIL PROTECTED] 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/delphi-en/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to