All Forums
 Microsoft Windows CE
 .NET Application Development
 FlashFX Disk in C#
 Forum Locked
 Send Topic to a Friend
 Printer Friendly
Author Topic  

davidknechtges

6 Posts

Posted - 28 Apr 2008 :  16:15:03  Show Profile
I am trying to write to the FlashFX disk from C# (using a stream writer to perform XML serialization on a class). I get an IOException when doing this no matter what I do.

If I direct the write to the \Temp folder or the other folders, the same code I have written works correctly.

I have also tried using the ADSCF Flash class and calling Open before the writes, but that had no effect either.

Is there something else I should know?

Thanks,

David

ctacke

877 Posts

Posted - 28 Apr 2008 :  16:25:48  Show Profile  Email Poster
Showing your failing code would be very useful. My bet is that you're not enclosing the path in quotes, so the space in the name is causing a failure.
Go to Top of Page

davidknechtges

6 Posts

Posted - 29 Apr 2008 :  08:52:51  Show Profile
Below is a snippet. If I run it as shown, it will throw the IOException. If I run it with the GetFileNameWithQuotes, it
throws the Value does not fall within expected range exception.

If I change GetFileName to any other folder, it works.

StreamWriter st = new StreamWriter(GetFileName());

string file = "test.txt";

public string GetFileName()
{
return String.Format(@"\FlashFX Disk\{0}", file); // IOException
// return String.Format(@"\My Documents\{0}", file); - this line works correctly and opens the file for writing.
}
public string GetFileNameWithQuotes()
{
return String.Format(@"""\FlashFX Disk\{0}""", file); // Value does not fall within expected range Exception.
}
Go to Top of Page

davidknechtges

6 Posts

Posted - 29 Apr 2008 :  09:22:07  Show Profile
Nevermind, I believe this is a hardware problem, not a code problem.

Thanks....
Go to Top of Page

cbadr

154 Posts

Posted - 29 Apr 2008 :  16:02:02  Show Profile  Email Poster
Where are you running your application from?
Go to Top of Page
  Topic  
 Forum Locked
 Send Topic to a Friend
 Printer Friendly
Jump To:
Eurotech Support Forums © Eurotech Inc. Go To Top Of Page
This page was generated in 0.03 seconds. Snitz Forums 2000