C
Carmen Sei
Is there any way to return either NULL or a SYSTEMTIME object? will
it work in C++?
as in Java, one can return either NULL or an object, does C++ has
something similar?
Is the following code OK for C++?
=================
SYSTEMTIME Table::Get(char* FieldName)
{
_variant_t vtValue;
vtValue = m_Rec->Fields->GetItem(FieldName)->GetValue();
if (vtValue.vt == VT_NULL) {
return NULL;
}
SYSTEMTIME m_st;
VariantTimeToSystemTimeWithMilliseconds (vtValue.date, &m_st);
return m_st;
}
it work in C++?
as in Java, one can return either NULL or an object, does C++ has
something similar?
Is the following code OK for C++?
=================
SYSTEMTIME Table::Get(char* FieldName)
{
_variant_t vtValue;
vtValue = m_Rec->Fields->GetItem(FieldName)->GetValue();
if (vtValue.vt == VT_NULL) {
return NULL;
}
SYSTEMTIME m_st;
VariantTimeToSystemTimeWithMilliseconds (vtValue.date, &m_st);
return m_st;
}