Problem with "Task.StartDate" in Outlook.dll

JOTHA

Well-Known Member
Licensed User
Longtime User
I wanted to use the Outlook-function "Task", but there might be a bug in the Outlook.dll.

The first problem is to use "Task.StartDate".

If I use the sample-code from the help-file:
B4X:
Task.StartDate = DateParse("09/13/2008") + (TimeParse("08:00") Mod cTicksPerDay)
the following message is shown:
"... Es kann keine Fehlermeldung angezeigt werden, da die optionale Ressource der Assembly, die die Fehlermeldung enthält, nicht gefunden wurde. Continue?"

I tried also:
B4X:
Task.StartDate = DateParse("09/13/2008")
with the same message ...

Because of the Error-Messages I made some more experiments with the code, but nothing worked.

If I use this:
B4X:
Task.StartDate = ("13.09.2008")
... this:
B4X:
Task.StartDate = (Date(Now))
... this:
B4X:
Task.StartDate = Date(Now)
... or I use this:
B4X:
Task.StartDate = "13.09.2008"
The following message is shown:
"... Fehlermeldung:
Error description:
FormatException
Continue?"

The next problem is to use the "Reminder-function" As specci48 has written to you yesterday (it is always at 08:00).

All the time I thought it was my fault in programming, but now I think there must be a bug somewhere.

But in the whole time I liked your Basic4PPC more and more, it is a great software and worth every cent! :sign0188:
... and the forum is also very very good! :sign0060: :)
 

agraham

Expert
Licensed User
Longtime User
B4X:
Task.StartDate = "13.09.2008"
Have you reset DateFormat to the European format "dd/mm/yyyy"? With the default USA format of "mm/dd/yyyy" 13 is a month and so is invalid. That is a different error to your original one, which is displaying a default error message as you don't have the complete error message set installed.

EDIT:- To see the actual message you need the German error message resource. The last post here http://www.b4x.com/forum/questions-help-needed/870-error-messages-device.html might be what you need but I am not sure, it's for WM5.0 and WM6.0.
 
Last edited:

JOTHA

Well-Known Member
Licensed User
Longtime User
B4X:
Task.StartDate = "13.09.2008"
Have you reset DateFormat to the European format "dd/mm/yyyy"?

Hello agraham,

thank you for your help.

I know the rules about the DateFormat in Europe (is written: "dd.mm.yyyy"), and I think this is not the reason for the error-messages, because I tried all formats (although the english/american ones).

I will check out you link to the error-messages on the device, maybe it helps me for better understanding, what the error-message means.

THANKS
 

JOTHA

Well-Known Member
Licensed User
Longtime User
Hi Erel,

thank you for helping me.
B4X:
 Task.StartDate = now
That´s a solution for the moment, but what can be done if you need a StartDate for "tomorrow" or in 3 weeks?

Is there another solution?
 

JOTHA

Well-Known Member
Licensed User
Longtime User
Hi Erel,

I´m sorry, but the code isn´t working proper.

First I have changed the date format into "20.09.2008" (Europe). It works.

If I use your code above, there are some Problems for the User on the Pocket-PC:

1) You wrote: "You can change the time."
But I can change it only in the code, but a User can´t change it on the Pocket-PC.

2) Another problem is, when today (DueDate) is the 09/19/2008 (19.09.2008) and the StartDate is the 09/20/2008 (20.09.2008) = in the future, an error-message is shown:
An Error occurred ... PimCol.AddItem(Task.Value)
Error description:
Native method call failed.
Continue?

There should be a possibility for the user to put in the StartDate and the DueDate, also to set an Alarm. (This would be the best solution) ;)

The "DueDate" function is working correct.

Now I made this:
B4X:
Task.StartDate = DateParse(""&BeginnDatum.Text&"") + (TimeParse(""&BeginnUhrzeit.Text&"") Mod cTicksPerDay)
... and the "StartDate" function is also working! (the Date- and Time-Fields must be TextBoxes, although it is not working!)

So, only the "Alarm"-function is needed.

Question to case 2) How can I avoid the error-message an show instead a messagebox like that: "Your Due-Date is set before the Start-Date. Please correct that ..."

Thanks in advance!
 

JOTHA

Well-Known Member
Licensed User
Longtime User
P.S.:
Did you install the error-messages cab?

I did, but there is no other message as before.

Do I had to reset the PPC after installing the CAB-File?
 
Top