Re: Hex writing doesn't work?
- Posted by Caballero Rojo <pampeano at ROCKETMAIL.COM> Apr 25, 2000
- 443 views
Hello Carl, I don't speak english very well, so I couldn't explain it better :( Anyway, the solution was using puts. :) Thanks. -- Best regards, ICQ Number: 3198249 Caballero Rojo mailto:pampeano at rocketmail.com Tuesday, April 25, 2000, 9:16:35 AM, you wrote: CRW> Your description is unclear, but I think I understand... :) CRW> I think you're wanting to do this: CRW> #4E23 as a number --> "4E23" as a string, without printing it. CRW> For this you need the sprintf() function (notice the extra 's') CRW> Then you can do this: CRW> sequence hexstring CRW> integer hexval CRW> hexval = #4E23 CRW> hexstring = sprintf("%04x", hexval) CRW> I don't even need to write a function this time. :) CRW> Hope this is what you wanted, CRW> Carl CRW> -- CRW> Carl R. White - Software Tester @ CTD - Carl- at -comodo.net CRW> Cyrek the Illogical - Geek - cyrek- at -bigfoot.com CRW> Remove hyphens before mailing s'il vous plait... __________________________________________________ Do You Yahoo!? Talk to your friends online with Yahoo! Messenger. http://im.yahoo.com