This project is read-only.

file not found...

Oct 22, 2011 at 6:15 PM
Hi,
I’m trying to read a .txt file created in the phone game project
folder. Here is my code:
using (BinaryReader reader =3D new BinaryReader(
=20 TitleContainer.OpenStream(_fileName)))
But during run-time the file cannot be found. I added the txt file
by right-clicking project->Add->New item->General->text file,=20 and
then filled some stuff in. Is anything wrong?
Thanks.
Yajie.
Oct 26, 2011 at 1:32 PM
Edited Oct 26, 2011 at 1:46 PM
Right click the text file, set Build Action to Compile and Copy to Output Directory to Copy if newer

Hope that works.
Oct 26, 2011 at 4:38 PM
yes! I just found that’s the step I missed. Thanks!
From: [email removed]
Sent: Wednesday, October 26, 2011 8:32 PM
To: [email removed]
Subject: Re: file not found... [nine:276825]

From: yufeih

Right click the test file, set Build Action to Compile and Copy to Output Directory to Copy if newer

Hope that works.