Page 1 of 1

IQueryable and NullException

Posted: Mon 05 Oct 2009 11:51
by Falke
I want to make a xml File, i use following code:
how can i say if film.content is null, that it should be filled with a empty string?
the assignment works but if i go through the objects e.g. with a for each through the filmlist the error occure.

Does sombody know, what i could do?

Dim list As System.Linq.IQueryable(Of System.Xml.Linq.XElement)
filmliste = From film In context.Films _
Where film.startdate >= Now.Date _
Order By film.startdate _
Select






Posted: Wed 07 Oct 2009 07:38
by AndreyR
I have just tried to run the similar code and succeeded in executing For Each statement.
Could you please send me a small test project illustrating the problem?
Please include the script of your DB objects in it.

Posted: Thu 08 Oct 2009 21:18
by Falke
okey i will send it to you tomorrow evening ...

how should i send it? i don't want to make it public ...

you don't have in your profile an e-mail and this board doesn't accept pm ...

Posted: Fri 09 Oct 2009 08:29
by AndreyR
Send it to support * devart * com with subject "LINQ: Null problems".