System.IO.File is not a member of system.io.file

Hi,

I am creating a program in vb.net for a handheld scanner and am receiving the following error in my code:

System.IO.File is not a member of system.io.file

I need to be able to write an array of bytes without doing the following:  
System.IO.File.WriteAllBytes("E:\outLabel.pdf", objRes.Label.Data)

Regards,

Ross
ross13Asked:
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.

Miguel OzSoftware EngineerCommented:
Uhmm, a bit strange. Please check that you have import System.IO and that a third party library is not introducing a new namespace that conflicts with .NET namespaces.
If more help needed please post your code.
0
ross13Author Commented:
I am using the compact framework if that helps.
0
Miguel OzSoftware EngineerCommented:
Compact framework does NOT support all System.IO classes and/or methods as they are mobile OS dependent.

Note: If more help needed, please
1) Post what version of .NET compact framework, VS and target mobile OS you are using.

 2) Send a cut down version of your Project. I have VS2010 and VS2013.
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
ross13Author Commented:
What I ended up doing was creating a web service and passing the byte array to it and generating a .pdf file.
0
ross13Author Commented:
Thanks for your help.

Regards,

Ross
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
.NET Programming

From novice to tech pro — start learning today.