You Are Here:

Community: Developer Discussion Boards

#1 Old hex number - 2008-01-27, 16:02

Join Date: May 2007
Posts: 57
RamiX
Offline
Regular Contributor
how i can set a hex identifier and convert it to byte[] ?
i need a code line!

thanks


www.NearConn.com - the first Bluetooth - Cellular - Web Social network
-------------------------------------------------------------------
Please visit my programming blog , it has many programming problems and soulution that may help u.
http://byramix.blogspot.com
Reply With Quote

#2 Old 2008-02-03, 14:57

Join Date: Mar 2003
Posts: 2,617
traud
Offline
Super Contributor
What do you mean with ‘hex identifier’? Could you just write what you think of and we correct it then?
Reply With Quote

#3 Old Re: hex number - 2008-02-03, 22:52

Join Date: May 2007
Posts: 57
RamiX
Offline
Regular Contributor
i have an encryption function that need a hex key in bytes, how i can write for example: key = "a1a1a1"
and turn it to bytes so the function can use it


www.NearConn.com - the first Bluetooth - Cellular - Web Social network
-------------------------------------------------------------------
Please visit my programming blog , it has many programming problems and soulution that may help u.
http://byramix.blogspot.com
Reply With Quote

#4 Old 2008-02-04, 12:14

Join Date: Mar 2003
Posts: 2,617
traud
Offline
Super Contributor
Still, I am not able to help you. I recommend to ask the support of encryption function API.

Some guesses (no idea, sorry):
If the key is a String: key.getBytes() (of class String)
If the key is an Integer encoded in a String as hexadecimal: Long.parseLong(key, 16)
If all that does not help: Byte.parseByte(everyTwoCharsOfKey, 16)?
Reply With Quote
Reply « Previous Thread | Next Thread »
Display Modes
Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules

You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Forum Jump
Similar Threads
Thread Thread Starter Forum Replies Last Post
WML & WMLSCript problem ???? gemini_shooter Browsing and Mark-ups 0 2006-01-14 07:02
WML & WMLSCript problem ???? gemini_shooter Browsing and Mark-ups 0 2006-01-14 07:01
Personal JSmith77 PersonalJava 4 2003-07-30 13:52
Unicode Song Title In NSM Ringtone mcai7db3 Smart Messaging 3 2002-08-28 07:58
Internet Access Config via Smart Message ajbrindley Smart Messaging 1 2002-08-14 08:56

Rate This

 
Bookmark this page: DeliciousDiggFacebookGoogleYahooStumbleUponRedditDiigoTechnocratiTwitter  Share this page Share this page Print this Page Print this page Invite a friend Invite a friend
京ICP备05048969号    Email Newsletters Press Terms & Conditions Privacy Policy Sitemap Contact Us © 2009 Nokia