Click here to Skip to main content
15,881,882 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello guys,

I am trying to use linq to sql to store data in to database in wpf application when i add a linq-to-sql in my project and try to drag and drop Table in to it it didnt allow to drag table and store procedure to add in linq-to-sql. so i have a question is that linq-to-sql works in WPF. if yes how can i use it.

Thank you
Posted
Comments
Matej Hlatky 12-Feb-13 8:25am    
I am using combination what have you described and never had problem with that.
As a workaround you can use sqlmetal to generate dbml file. Good luck
bikramjeet.sm 12-Feb-13 9:04am    
can you please explain about it?

1 solution

Hi,

are you trying to use sql server 2012 with vs 2010?
Then it could be a ms problem, please read this:

http://social.msdn.microsoft.com/Forums/pl/linqtosql/thread/78537f25-6c45-4b56-b476-992e7fe8b4bf[^]

In normal case it should be easy ;)

http://www.mssqltips.com/sqlservertip/1542/using-stored-procedures-with-linq-to-sql/[^]

SqlMetal on msdn:
http://msdn.microsoft.com/en-us/library/bb386987.aspx[^]

Regards
 
Share this answer
 
v3
Comments
bikramjeet.sm 13-Feb-13 12:23pm    
No Im working with SQL Server 2008 with VS 2010
El_Codero 13-Feb-13 12:29pm    
Do you get some exception?Otherwise (as Matej pointed to), try sql metal, but I would be longing to know what's the problem in VS. I've updated solution with link to sqlmetal.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900