CRYSTAL REPORT, run time query report by date 
Author Message
 CRYSTAL REPORT, run time query report by date

Hi,

 Iam trying to create a query report during the run time by
date.
I used :
 crystalreport1.selectionformula = "{filename.date}=#" &
text1.text &"#"
but after I press ok, it's not responding at all. although
this command is working with other data types e.g
numbers,strings..etc.
please if any body can help this will really be highly
appreciated.

Thanks
Hisham

* Sent from AltaVista http://www.*-*-*.com/ Where you can also find related Web Pages, Images, Audios, Videos, News, and Shopping.  Smart is Beautiful



Sun, 22 Sep 2002 03:00:00 GMT  
 CRYSTAL REPORT, run time query report by date
Crystal Reports expects the date in yyyy/mm/dd order
Quote:

>Hi,

> Iam trying to create a query report during the run time by
>date.
>I used :
> crystalreport1.selectionformula = "{filename.date}=#" &
>text1.text &"#"
>but after I press ok, it's not responding at all. although
>this command is working with other data types e.g
>numbers,strings..etc.
>please if any body can help this will really be highly
>appreciated.

>Thanks
>Hisham

>* Sent from AltaVista http://www.altavista.com Where you can also find related Web Pages, Images, Audios, Videos, News, and Shopping.  Smart is Beautiful



Mon, 23 Sep 2002 03:00:00 GMT  
 CRYSTAL REPORT, run time query report by date
Hi,

Crystal needs the date format added so your query should look something like
this :-

"{filename.date} = Date(yyyy,mm,dd)"

I wrote the following function to automatically format the date so all I
have to pass is the following

"{filename.date} = Date(" & CrystalDate(Now) & ")"

Function CrystalDate(sDate As String)

Dim iDay As Integer
Dim iMonth As Integer
Dim iYear As Integer

iDay = Day(sDate)
iMonth = Month(sDate)
iYear = Year(sDate)

CrystalDate = CStr(iYear) & "," & CStr(iMonth) & "," & CStr(iDay)

End Function

Hope this helps !

Regards,

David.

Quote:

>Hi,

> Iam trying to create a query report during the run time by
>date.
>I used :
> crystalreport1.selectionformula = "{filename.date}=#" &
>text1.text &"#"
>but after I press ok, it's not responding at all. although
>this command is working with other data types e.g
>numbers,strings..etc.
>please if any body can help this will really be highly
>appreciated.

>Thanks
>Hisham

>* Sent from AltaVista http://www.altavista.com Where you can also find

related Web Pages, Images, Audios, Videos, News, and Shopping.  Smart is
Beautiful


Fri, 27 Sep 2002 03:00:00 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Query Crystal Report at Run Time from VB

2. Crystal Reports, Date/Time, and the Time() function

3. Date/Time field & Crystal Reports in VB5

4. VB 6.0, Crystal Reports, getting date/time from Oracle 8.0

5. crystal report time/date problems

6. crystal reports abd date/time data type ?

7. Crystal Reports and the Date/Time variable

8. Date/Time in Crystal Reports

9. Q: Pass a SQL query from VB to crystal report sub-report

10. Date/Time type in Crystal Reports

11. sub-report (2 query's ) in crystal reports

12. Date/Time arithmetric in Crystal Reports?

 

 
Powered by phpBB® Forum Software