![]() |
|
[C#] C# Simple ASCII encoding - Printable Version +- Hack Forums (https://hackforums.net) +-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444) +--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151) +---- Forum: Software Development (https://hackforums.net/forumdisplay.php?fid=118) +---- Thread: [C#] C# Simple ASCII encoding (/showthread.php?tid=717156) |
C# Simple ASCII encoding - ubbelol - Oct 3, 2010 I love browsing through my old projects. I found this little encoding function i made to turn strings into ASCII values. But please note that when trying to use this function don't use "advanced" chars (characters with an ascii value > 999) as the function can't handle them (it's easily modified though if you need it) Basically what it does is check if the value is under 100, if it is it formats the value like "9(ascii #)" so it can be read in the decode function. I don't know what this could be used for but maybe for your strings in stubs? Encode: http://pastie.org/1196502 Decode: http://pastie.org/1196504 Example usage: Code string str = "abc";[IMG]http://i350.photobucket.com/albums/q408/ubbe12/ascii.gif[/IMG] * - Local Celeb - Oct 3, 2010 This is a nice little snippet :) I can use this for something, possibly. Perfect timing though ;) On another note : Get on msn ! :D * - ubbelol - Oct 3, 2010 (Oct 3, 2010 06:13 AM)Asydix Wrote: This is a nice little snippet :) I am on MSN. What's your address? 😝 * - Local Celeb - Oct 3, 2010 Oh woops. I was on the wrong one :P [email protected] * - daemon10 - Oct 3, 2010 Nice Post.. and nicely coded C# is awsome * - My Life - Oct 3, 2010 Nice little encryption . I may use this in my project. Thanks for share. |