COMVariant.createFromDateAndTime Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
createFromDateAndTime(Date, Int32) |
Creates a new COMVariant object and initializes it with a date and time in one operation. |
createFromDateAndTime(Date, Int32, COMVariantInOut) |
createFromDateAndTime(Date, Int32)
Creates a new COMVariant object and initializes it with a date and time in one operation.
public:
static Dynamics::AX::Application::COMVariant ^ createFromDateAndTime(Microsoft::Dynamics::Ax::Xpp::AxShared::Date date1, int num1);
public static Dynamics.AX.Application.COMVariant createFromDateAndTime (Microsoft.Dynamics.Ax.Xpp.AxShared.Date date1, int num1);
static member createFromDateAndTime : Microsoft.Dynamics.Ax.Xpp.AxShared.Date * int -> Dynamics.AX.Application.COMVariant
Public Shared Function createFromDateAndTime (date1 As Date, num1 As Integer) As COMVariant
Parameters
- date1
- Microsoft.Dynamics.Ax.Xpp.AxShared.Date
- num1
- Int32
Returns
The new COMVariant object.
Remarks
The COMVariant object that is created by this method has the data type VT_DATE (date/time). You can change the data type of an existing COMVariant object to VT_DATE by using the variantType method.
The following example creates a COMVariant object and assigns it the current date, and a time of 10 seconds past midnight.
date theDay;
COMVariant theDayAndTime;
theDay = today();
theDayAndTime = COMVariant::createFromDateAndTime(theDay, 10);
info(theDayAndTime.toString());
Applies to
createFromDateAndTime(Date, Int32, COMVariantInOut)
public:
static Dynamics::AX::Application::COMVariant ^ createFromDateAndTime(Microsoft::Dynamics::Ax::Xpp::AxShared::Date _date, int _time, Dynamics::AX::Application::COMVariantInOut _inOutFlag);
public static Dynamics.AX.Application.COMVariant createFromDateAndTime (Microsoft.Dynamics.Ax.Xpp.AxShared.Date _date, int _time, Dynamics.AX.Application.COMVariantInOut _inOutFlag);
static member createFromDateAndTime : Microsoft.Dynamics.Ax.Xpp.AxShared.Date * int * Dynamics.AX.Application.COMVariantInOut -> Dynamics.AX.Application.COMVariant
Public Shared Function createFromDateAndTime (_date As Date, _time As Integer, _inOutFlag As COMVariantInOut) As COMVariant
Parameters
- _date
- Microsoft.Dynamics.Ax.Xpp.AxShared.Date
A flag that determines whether the object can be used to pass data to a COM method or COM property, to receive data, or both. This parameter is optional. Possible values are:
- _time
- Int32
A flag that determines whether the object can be used to pass data to a COM method or COM property, to receive data, or both. This parameter is optional. Possible values are:
- _inOutFlag
- COMVariantInOut
A flag that determines whether the object can be used to pass data to a COM method or COM property, to receive data, or both. This parameter is optional. Possible values are: