Creating DateTime in plugin

date = REALnewInstanceWithClass(DateTimeClassRef);

What will this give me ?

I suspect it will not give me DateTime.Now

And if not then how do I create DateTime.Now in plugin ?

Xojo Inc. has yet to give guides on how to use DateTime class from plugins.
For the time being, I think we just return dates.

Maybe @William Yu can comment?

Well the Xojo is out and we got users hammering us for when objects use the new API. The norm would be to publish new API with new release so we have some answers for the users.

typedef REALobject (*DateTimeNowTy)(void);
static REALclassRef dateTimeClassRef = REALGetClassRef("DateTime");
DateTimeNowTy dateTimeNowFunc = (DateTimeNowTy)REALLoadSharedMethod(dateTimeClassRef, "Now As DateTime");

Thanks William !

Thought we did not have LoadSharedMethod at all ! I will look asap.