Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
LINQ to datatable - how to create a variable?
Message
Information générale
Forum:
ASP.NET
Catégorie:
Code, syntaxe and commandes
Versions des environnements
Environment:
C# 4.0
OS:
Windows 7
Network:
Windows 2003 Server
Database:
MS SQL Server
Application:
Web
Divers
Thread ID:
01576896
Message ID:
01577635
Vues:
45
>>
>>The problem is to declare query variable separately and re-use it later.
>>
>
>
>You can't. It's anonymous which basically means you don't have access to the internally generated class name the compiler built for it. If you need access to it from other methods, it's no longer anonymous (basically, you have to declare a real class type which will hold the results and project the results into that instead of "new { }".

Thanks, Paul. It was not clear to me before.
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform