Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Retrieving a datetime field form a CE database table
Message
From
01/06/2007 08:25:30
 
 
To
All
General information
Forum:
ASP.NET
Category:
ADO.NET
Title:
Retrieving a datetime field form a CE database table
Environment versions
Environment:
C# 2.0
OS:
Windows XP SP2
Network:
Windows XP
Database:
MS SQL Server
Miscellaneous
Thread ID:
01229763
Message ID:
01229763
Views:
60
Hi,

I'm trying to retrieve a datetime field from a WinCE database table using the following code:

DateTime LupdDate;

System.Data.SqlServerCe.SqlCeCommand sqlCeCommand2 = new
System.Data.SqlServerCe.SqlCeCommand("select LupdDate from Product where prodid =12036",SqlCeProvider.Connection);

sqlCeCommand2.Connection.Open();

LupdDate = (DateTime)sqlCeCommand2.ExecuteScalar();

The problem is that I only get the date part of the datetime.

Any ideas why ?

Best regards,
Hans
Next
Reply
Map
View

Click here to load this message in the networking platform