Evert,
Well, there is no reason you can't code the objects that LINQ uses
yourself. You can then apply whatever attributes you wish. You can
easily
create class definitions which LINQ can use.
Here is a link to the section of the MSDN documentation titled "The
LINQ
to SQL Object Model", which should help:
http://msdn2.microsoft.com/en-us/library/bb386989.aspx
--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)
Evert said:
Hmm... I am searching for a good technology for my new application.
(Sort
of
time management on web). I thought the Validation Application Block was
good
for my business objects. And LINQ to SQL is good for getting the data
from
the database. But if it is not possible to use the VAB i can't use
linq.
Do you have a better solution? I like the VAB a lot. It is easy to use,
fast
to program and very sollid. With the AJAX validation controls it is
also
easy
to use in the GUI.
Best regards,
Evert
:
Evert,
You can't through the designer. There is no way to add attributes
through the designer to the classes. You could modify the
designer-generated code, but it might be overwritten by the designer.
There is no good solution to this, I am afraid.
--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)
Does anybody know if it is possible to use the Validation
Application
Block
from Enterprise Library 3.1 in Linq. The problem is that I don't
know
how
to
add the validation attributes to the generated properties.
Thanks in advance,
Evert