01.Blogs :
RobMiles  
Programming, gadgets and life as a lecturer in a UK university.

Planet Strange

I'm writing some presentation materials for my mobile conference at the moment (it's called Slide5 (www.slide5.com) and there are still some places left if you hurry. Great fun. I like producing this stuff.

<Developer Geeky Stuff>
Anyhoo, one of the things I've written as an example app is a very simple encoder program. You give it a password and the text that you want to encode. It then combines them to produce the encoded text. To get the text back you put in the encoded text and the password and, presto, back it comes. It makes use of the magic of exclusive OR and is a nice little demo for Smartphone. Except that it did a strange thing. If you encode the word  secret with the key cheese you get 0-761

Very weird. I seemed to have found the ASCII code for underlined seven. Turns out to be a feature of labels in Windows Forms. The actual string that is produced by the encoder is 0-&761. If you preceed a character in a label with & it means you can press ALT and the following character to hot foot to the screen item next to that label. I'd used a label to display the encoded string and so, although there is no ALT key on the Smartphone, the behaviour of the label display was just the same. Changing to a TextBox fixed the problem.  I've often marveled at how similar the Forms behaviour on Smartphone and big PC is, perhaps this one is a similarity too far....

</Developer Geeky Stuff>


posted on Thursday, June 30, 2005 3:33 PM by RobMiles


 
03.UPDATE CALENDAR :
<June 2005>
SunMonTueWedThuFriSat
2930311234
567891011
12131415161718
19202122232425
262728293012
3456789

05.MY LINKS :

07.Subscriptions :

Subscriptions


© Copyright 2005 Microsoft Corporation. All Rights Reserved.
Terms of Use | Privacy Statement | Code of Conduct | Hosted by MaximumASP for Microsoft
WHO-BAR