Windows Phone Thoughts - Daily News, Views, Rants and Raves

Check out the hottest Windows Mobile devices at our Expansys store!

Digital Home Thoughts

Loading feed...

Laptop Thoughts

Loading feed...

Android Thoughts

Loading feed...

Go Back   Thoughts Media Forums > WINDOWS PHONE THOUGHTS > Windows Phone Developer

Thread Tools Display Modes
Prev Previous Post   Next Post Next
Old 01-14-2011, 08:38 AM
Join Date: Aug 2006
Posts: 323
Default Does VS2010 Express for Phone support Collections classes?

I am developing and XNA game for Windows Phone 7. I have installed Visual Studio 2010 Express for Windows Phone. My project is almost ready for release.

I would like to add a Hashtable to my project. Of course, I have "using System.Collections," but that was insufficient. My project does include a reference to mscorlib. The object browser indicates that it is version [], which does not contain Hashtable/Queue/Stact/etc. The object browser does have a description of mscorlib [], which does.

Unfortunately, my attempts to add it have failed. I located it in the .NETFramework\4.0 directory, but my attempt to add it by browsing to it failed. VS said that I already have an mscorlib.

I tried to remove the original mscorlib and add the 4.0 version. That partially worked. I can now define a Hashtable. Unfortunately, when I build the solution, I get this error:
"Predefined type 'System.Object' is not defined or imported."

I did some msdn and google searches, but apparently did not ask the right queries. The most relevent comment I found was this:
"Don't take my word for it, but I think that the .NET compact framework only supports the Dictionary class."

This suggests that I should forget about using collection classes in my XNA project.

Just before trying any of this, I copied the entire project directory to a thumb drive, so I can handle the 'System.Object' problem by restoring from backup.

Is there a way to use collection classes in an XNA project in VS 2010 Express? Any suggestions would be greatly appreciated. Thank you in advance!
Reply With Quote

collections, windows phone 7, xna

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT +1. The time now is 02:31 AM.