In Basic syntax:
Dim D As Number
'
D = 10031985.00
Formula = Mid(ToText(D,"00000000"),1,2) + "/" + Mid(ToText(D,"00000000"),3,2) + "/" + Mid(ToText(D,"00000000"),5,4)
This works for either 9 or 10 digit dates
You were using the OCX in the earlier version. I believe Crystal dropped support for the OCX in version 9. You will have to convert your code to use RDC or CRPE if that is the case.
numberVar n;
numberVar i;
n:= DateDiff("d",{?sDate},{?eDate})\7;
for i:= 0 to (DateDiff("d",{?sDate},{?eDate}) Mod 7) do
(
If DayOfWeek (DateAdd("d",-i,{?eDate})) = 6 Then
(
n:= n + 1;
exit for);
);
n
Dim strDate As String
strDate = "20030307"
Formula = DateValue(ToNumber(Mid(strDate,1,4)),ToNumber(Mid(strDate,5,2)),ToNumber(Mid(strDate,7,2)))
Try something like this:
Dim ip As string
ip = "12.456.78.000"
Formula = Left(ip,Instr(ip,Split(ip,".")(4)) -2)
Depending on your data you might need to add some data check to avoid errors.
You could use a formula something like:
Dim x as Number
x = 1.56
If Remainder (x, 0.05) < 0.025 Then
Formula = x - Remainder (x, 0.05)
Else
Formula = x + (0.05 - Remainder (x, 0.05))
End If
If you can have negative number than you will have to modify this slightly to work.
I should of mentioned that you should logon to database before you verify. I recall that I had the same problem until I remember that if you open up a report and verify it will want you to log on first. Where I used it was an application using the Lotus Notes native driver and it work as soon...
I do not think you can write a report directly from a Word Doc. But is you can save it as a text file then you can report off the converted text file using ODBC and setting up a DSN using the text driver.
You might try reorganizing your report as follows:
Property #N
Details A: Contact info (SubReport Linked using Property ID to limited contact info only for Property #N)
Details B: Email (SubReport Linked using Property ID to limited EMail info only for Property #N)
Details C: Phone No...
if ({CUSTOMER_NAME} = "funkyCustomer")
then
split({SERVICE_NAME}, " ")[1]
else
{SERVICE_NAME}
Note: This will not work if ({SERVICE_NAME} is = blank. If this can happen you will have to add a check for this condition.
Even though you can add the Viewer ActiveX control to an Access form I do not think it is compatible. You will notice that all the properties and methods are not exposed when you add the control to the Access form.
I would write a formula that captures the elapsed time in seconds using the function DateDiff:
DateDiff ("s",{Elapsed.Start} , {Elapsed.End})
Then to calculate and display the average write a formula as such:
numberVar Hrs;
numberVar Minutes;
numberVar Seconds;
Hrs:= Average ({@ET})...
If your record number field is numeric:
ToText({RecordNumberField},"00000")
If your record number field is a string:
ToText(ToNumber({RecordNumberField}),"00000")
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.