A
Abhishek
Hii Everyone,
I got a fundamental problem. I add a file to my project in .net compact C#,
and set it to Build Action to Content. The basic objective is when I deploy
my solution it uploads the file to the emulator. This works fine. Now when I
use a FileStream object to read bytes of from this file I find that my
middle bytes have different values then they have on the desktop. For
instance value of a byte(213) in the file on the disk is decimal value, 62
and the same byte in my pocket pc application has decimal value 65. Why is
this happening? In my pocket pc app I am not doing any thing except use a
FileStream object with the path of the file and then I declare a byte array
and BinaryReader ReadBytes method to read into my byte array. So when I
inspect this byte array i find that the bytes are no longer having the same
decimal values. As I gave the e.g. above byte # 213 on the PC has 62 and on
the Pocket PC emulator has 65. And this is not for only this byte but many
other. The file that I am referring to is a JPG file. Please suggest me what
could be wrong and what is the way out? I suspect it has something to do
with encoding but I am not sure.
Regards,
Abhishek
I got a fundamental problem. I add a file to my project in .net compact C#,
and set it to Build Action to Content. The basic objective is when I deploy
my solution it uploads the file to the emulator. This works fine. Now when I
use a FileStream object to read bytes of from this file I find that my
middle bytes have different values then they have on the desktop. For
instance value of a byte(213) in the file on the disk is decimal value, 62
and the same byte in my pocket pc application has decimal value 65. Why is
this happening? In my pocket pc app I am not doing any thing except use a
FileStream object with the path of the file and then I declare a byte array
and BinaryReader ReadBytes method to read into my byte array. So when I
inspect this byte array i find that the bytes are no longer having the same
decimal values. As I gave the e.g. above byte # 213 on the PC has 62 and on
the Pocket PC emulator has 65. And this is not for only this byte but many
other. The file that I am referring to is a JPG file. Please suggest me what
could be wrong and what is the way out? I suspect it has something to do
with encoding but I am not sure.
Regards,
Abhishek