Page 1 of 1

Problem using DateTimeOffSet in BussinessObjects

Posted: Tue Nov 12, 2013 8:19 pm
by Daniel Schmitz
Hello.

I'm having some problems using a DateTimeOffSet property in a BussinessObjects, and trying to compile the report.

When I register my object in report's dictionary, and I look inside it, it is a DateTimeOffSet, so ok.
But in designer's dictionary tree it is shown as Object.
And the same happens when I send it back to the server, and I try to look inside the dictionary.

So the problem is that, if my report have some code like:

Code: Select all

Person.Birthdate.ToString("yyyy-MM-dd");
and I try to compile my report in server side:

Code: Select all

report.Compile("AnyPath...");
I get an error saying that Object does not contains a ToString(string) overload.

Thank you.

Re: Problem using DateTimeOffSet in BussinessObjects

Posted: Wed Nov 13, 2013 1:28 pm
by HighAley
Hello.

Unfortunately, this type like other not standard types is not supported in WebDesigner now.
This task is in our to-do list.

Thank you.

Re: Problem using DateTimeOffSet in BussinessObjects

Posted: Thu May 08, 2014 10:18 am
by HighAley
Hello.

The DateTimeOffSet type is absent in the .Net Framework 2.0. We can not add this type because we will lost compatibility with .Net Framework 2.0 and we have many customers that use this version of framework.

We have in plans to discontinue support of the .Net Framework 2.0, 3.5 to the next year.

There is a workaround you could use next expression:

Code: Select all

((DateTimeOffset)Person.Birthdate).ToString("yyyy-MM-dd");
Thank you.