469,267 Members | 971 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,267 developers. It's quick & easy.

convert any image file to hex code

hi frnds
in using vb.net i want to read or convert any image file to HEX code ..actually
i want to send wallpaper to a mobile phone using gateways
Jul 6 '07 #1
5 5657
Plater
7,872 Expert 4TB
What do you mean hex code? Bytes?
Just open the file with File.Open() and read in the bytes to an array or something then you can send them out.
Jul 6 '07 #2
What do you mean hex code? Bytes?
Just open the file with File.Open() and read in the bytes to an array or something then you can send them out.

i hav to send it on mobile and a moblie phone want it in hex code ,,,,
i use streamreader to read that image file but it read in unknown format ..thats why i got a problem
Jul 9 '07 #3
Plater
7,872 Expert 4TB
"hex code" isn't really code. Hexadecimal is a number system with base 16. (As opposed to standard decimal which is base 10)

Is the image you are trying to send mobile-friendly? Back in the day phones only took .wbmp but I imagine they can handle more.

Everything going to a cell phone generally has to be compressed (if it's going directly, if you go through a proxy'd gateway it will probably do the compression for you)
Jul 9 '07 #4
"hex code" isn't really code. Hexadecimal is a number system with base 16. (As opposed to standard decimal which is base 10)

Is the image you are trying to send mobile-friendly? Back in the day phones only took .wbmp but I imagine they can handle more.

Everything going to a cell phone generally has to be compressed (if it's going directly, if you go through a proxy'd gateway it will probably do the compression for you)
thnks 4 reply
but it is not a solution i use clickatell gateway to send wallpaper ,,and u can'nt send the the path of u r wallpaper to that gate way,,so u hav to convert that wallpaper into hexadecimal string.. that why i want to convert image in to hex string which is also compatible with clickatell
Jul 11 '07 #5
Plater
7,872 Expert 4TB
So you would say have something like:
string mypicstring="0xAA 0xBA 0xDD";
and then you would send that string?

Well if you read in the bytes, then convert them to int8, you cna then use the .ToString("2X") to display them as hex characters
Jul 11 '07 #6

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

reply views Thread by Nicolas Guilhot | last post: by
1 post views Thread by mevar81 | last post: by
3 posts views Thread by Ignacio Marcos | last post: by
7 posts views Thread by Scott Schluer | last post: by
5 posts views Thread by Socrates | last post: by
6 posts views Thread by PenguinPig | last post: by
5 posts views Thread by stef | last post: by
reply views Thread by zhoujie | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.