Web Visual Developer 2010 doesn't recognise namespace System.Data

I've installed Web Visual Developer 2010 Beta plus Silverlight SDK and Tools and have started a Silverlight app in C#. All has been fine up to now but now I'm starting with the DB section it doesn't recognise namespace System.Data

The error is:
The type or namespace name 'Data' does not exist in the namespace 'System' (are you missing an assembly reference?)
ChrisJonesLycosAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Bob LearnedCommented:
1) The RTM version should be available, now that 2010 was released yesterday.

2) Usually, when you can't find a namespace, it is because there isn't a reference to the .dll added to the project.  You should be able to "Add Reference", and select the System.Data.dll, and then be able to use that namespace.
0
ChrisJonesLycosAuthor Commented:
Have you any idea where the System.Data.dll is located? I can find only one and it is in a very obscure folder.
0
Bob LearnedCommented:
System.Data should be in the Global Assembly Cache (GAC), and should be available in the "Add Reference" dialog.
0
CompTIA Cloud+

The CompTIA Cloud+ Basic training course will teach you about cloud concepts and models, data storage, networking, and network infrastructure.

ChrisJonesLycosAuthor Commented:
Unfortunately it's not there then. Could it be that either VWD 10 or VWD 10 no longer use this namespace. I've noticed lots of differences between VWD 10 and the examples I'm following in VWD 8. But this seems pretty fundamental.
0
ChrisJonesLycosAuthor Commented:
[Corrected] Unfortunately it's not there then. Could it be that either VWD 10 or VWD 10 beta no longer use this namespace? I've noticed lots of differences between VWD 10 and the examples I'm following in VWD 8. But this seems pretty fundamental.
0
Bob LearnedCommented:
System.Data.dll is a crucial part of the .NET framework, so it should be there.  The root for the file stored in the GAC is %SystemRoot%\Microsoft.NET\Framework\v4.0.30319.

Here is an attached image of the files in that folder, with System.Data.dll highlighted.  BTW, I don't have Visual Web Developer (I have VS.NET Ultimate RTM version, which includes that piece), but that shouldn't matter with this particular DLL.


Screenshot.png
0
guru_samiCommented:
Thought to see whats going on...so I created an silverlightApplication in VWD2010(RTM)...and tried to add a reference to System.Data but it is no longer under .NET tab..i.e. GAC....So I went to my gac folder
C:\Windows\assembly and none  of the 4.0 assemblies are listed there...

As TheLearnedOne: suggested I went to main root C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319 and it was there. But unfortunately I wasn't able to add System.Data dll....

This is the first ever Silverlight project I created and for now I don't know how it works...so can't explain what is going on...
0
ChrisJonesLycosAuthor Commented:
Yes, I've basically done the same. System.Data isn't there when you right click, Add Reference in the Solutions box. If I choose to browse to file and go to C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319, find System.Data and try to add it, it says this is the wrong version of .NET Framework. I removed all previous versions of .NET when I installed Silverlight just so I had the version Silverlight specified. So I'm not sure what's going on.

0
ChrisJonesLycosAuthor Commented:
Actually I think I might have solved it. It's to do with the (unspoken) philosophy of Microsoft on this one.

I've just created a new Silverlight project that uses a Web Service to provide the data for a Silverlight based client. In the client part you can't add System.Data, in the Web Service you can.

Obviously the thinking is that the client is exactly that, just a client, and it shouldn't have access directly to data - unless you want to statically code it in or through one of the simple file access methods.

I would love to see a website (or even a good old fashioned book) where all these things were explained. Anyone know of one?
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Bob LearnedCommented:
I don't work with Silverlight enough, yet, to know that one, but I guess that I have learned it now.  I don't know of any web site where that would be explained.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Development

From novice to tech pro — start learning today.