Cannot save projects in Visual Studio 2008

Discussion in 'General Questions' started by Patrick Besong, Mar 5, 2009.

  1. Patrick Besong

    Patrick Besong Bit poster

    Messages:
    4
    I upgraded to Parallels 4 this morning and before I did I backed up my VB project, but after re-installing VB Express Edition, I cannot open this file. It gives me the following error:

    "Unable to read the project file 'WindowsApplication1.vbproj'. Invalid URI: The hostname could not be parsed."

    Is there some way of saving my file so I can open it again? I put the file here:

    \\.psf\Home\Documents\Visual Studio 2008\Projects\WindowsApplication1

    Prior to installing Parallels on my Mac the file lived here:

    c:\Documents and Settings\Parallels XP\My Docs\Visual Studio 2008\Projects

    So I decided to create a new project and possibly add the old project to it. I created a new project then quit Visual Studio. When I reopen Visual Studio I cannot open the project I just created previously even though I didn't even add anything to it yet. I have no idea what is going on. It does not seem to like the default location of the project files. Is there a fix for this?
     
  2. Jason Heffner

    Jason Heffner Bit poster

    Messages:
    4
    Visual Studio under Parallels

    There is actually two things that need to be considered when running Visual Studio 2008 under Parallels. The first is making sure the file system between the shared folder on your mac is trusted by the .NET Framework. To accomplish this you can use the following command..

    C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\caspol.exe -m -ag 1.5 -url file://\\.psf/* FullTrust

    There is a really good write-up at http://blogs.imeta.co.uk/sstrong/archive/2009/01/29/589.aspx

    The second issue is related to the error you are seeing. The path in which your project is located can not contain a ".", as in ".psf". To circumvent this I created another shared folder under the Virtual Machine Configuration called "Visual Studio 2008" and pointed it to "/Users/YourName/Documents/Visual Studio 2008". By default this will become X:\ within Parallels and you will now be able to save and open using that new path.

    I don't think it was very smart of Parallels to include a period in a folder/share path since Windows doesn't support this normally.
     
    Last edited: Mar 6, 2009
  3. Patrick Besong

    Patrick Besong Bit poster

    Messages:
    4
    Thanks again, Jason. You went above and beyond.
     
  4. Jason Heffner

    Jason Heffner Bit poster

    Messages:
    4
    No problem, but I did realize since the drive is already mapped as "Z:/" there is no reason to create a new share. You could just use Z:/ to access your projects.
     
  5. ionblue

    ionblue Member

    Messages:
    26
    I've had NO luck being able to actually test a VS site locally - HELP

    I've tried everything I can find on the net about trying to test a site locally in a Parallels VM with content on the Host. Nothing works. I've tried all the above and chamged my mappings so many times I can't even tell you. When I look at the page in IE I get the following:

    Server Error in '/' Application.
    --------------------------------------------------------------------------------
    Configuration Error
    Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

    Parser Error Message: An error occurred loading a configuration file: Failed to start monitoring changes to 'X:\detoxstrategy'.
    Source Error:

    [No relevant source lines]

    Source File: X:\detoxstrategy\web.config Line: 0

    As I said, I've tried every type of mapping of the drive letters, no directory and just a letter, long names, short names, etc, etc. and nothing works. I've tried hitting the directory over SMB and that fails. I've got the site config setup to run with Virtual Path /, dynamic port False, Port 8080 (using the built in little servlet). This is driving me nuts!

    The only solution so far is to copy the site into a folder IN the VM and do it there - this works fine. But I need to be able to get at the code in both the Mac and the XP VM, preferably without starting the VM every time.

    Any help is greatly appreciated on this. I have no idea what else to try.
     
  6. Sylvain Dupras

    Sylvain Dupras Bit poster

    Messages:
    1
    Thanks for the info with the caspol.exe part.

    I use VS08 for developpement of WinForms application. Sp1 of VS08 solved the issus but making it very slow.

    caspol.exe help to give some speed.
     
  7. geneicspecies

    geneicspecies Bit poster

    Messages:
    2
    I have the same problem with the "ASP.NET Development Web Server" giving the same error about the web.config file etc.

    I think the problem is that the dev server runs from the aspnet user account... and that account might not necessarily have permission to access the mapped drive.

    I'm trying to figure out how to run the dev server from my own local account instead.
     
  8. Carl

    Carl Bit poster

    Messages:
    3
    Has anybody a suggestion how to run Visual Studio 2008 on Windows 7 or Windows XP with Parallels. When I try to compile a website I always get the same error message. I really like the source file to be on the Mac because of the automatic backup of Time Machine. Is is possible to rename the hostname '.psf' to remove the '.'
     
  9. ionblue

    ionblue Member

    Messages:
    26
    I was able to get around problems with project builds and whatnot in 2 fashions:

    1) Files on Mac shared through SMB and NOT the standard shares (.psf)
    2) Locate all project related files in the Windows VM, not on the Mac

    The 2nd one is actually how I'm doing things these days due to work switching from Subversion to Visual Source Safe which DID NOT like having files on my Mac at all. It's not ideal, but it works and I can access files as long as the VM is up. Also, Time Machine backs the VM up unless you turn that off, so at least there that. I'm also using snapshots just in case.
     
  10. geneicspecies

    geneicspecies Bit poster

    Messages:
    2
    What I've ended up doing is having my local copy of the code in a directory in ~/Documents on my Mac HD.

    In Windows, I mapped a drive to ~/Documents, and then load that into VS.

    I installed Cassini web server. The problem is that IIS and Cassini both will not serve pages from a mapped drive. So, each time I want to test, I publish in VS to a directory inside the VM (e.g. c:\website).

    Luckily, I can use Mac browsers to test with.

    I guess this solution is about as good as it gets at the moment. It's bloated and chaotic, just like ASP.NET itself really.

    Would be much better off PHP and Symphony/CakePHP/CodeIgniter. Would also mean using Apache instead of those third-rate web servers.
     
  11. Carl

    Carl Bit poster

    Messages:
    3
    Thanks I will try the SMB solution.
     

Share This Page