LINQ to SQL: What is the equivalent of timedate in C#

  • Thread starter Nicholas Paldino [.NET/C# MVP]
  • Start date
N

Nicholas Paldino [.NET/C# MVP]

Konrad,

Why not the DateTime structure? That's what you use in .NET to
represent date/time values.

Why can't you use the automatic code generator?
 
K

K Viltersten

One of the columns i'm mapping my class to
has the variable type "datetime" and i
wonder what that could be mapped to in C#.
The only thing i've found was TimeInterval
and that's hardly correct, is it?

private ?!?!?! _time;
[Column (Name = "time")]
public ?!?!?! time {get{...} set{...}}

I can't use the automatic code generator,
sadly, hence not being able to check that
myself by drag-and-drop.
 
K

K Viltersten

Why not the DateTime structure? That's
what you use in .NET to represent
date/time values.

Great suggestion. I must have missed that
or only checked things starting with T.
I guess i'm getting tired and prone to
make errors. Time to go to bed!
Why can't you use the automatic code
generator?

As i described in another question, when
i D&D a table into the "drop stuf here
to auto-create code"-area, i get error
that the selected object uses an
unsupported data provider. Nobody
answered that question so i assumed that
it's either stupid or complicated.

So, i wrote my own LINQ to SQL manager
from scratch and it works seemingly.
 
M

Michael Starberg

K Viltersten said:
So, i wrote my own LINQ to SQL manager
from scratch and it works seemingly.

You don't need sleep, you need to get layed; or a wife. =)

- Michael Starberg
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top