16 credit string turnt characters

xiaoxiao2021-03-06  111

///

/// 16 Entering character /// /// /// public string hextostr String str1) {string returnvalue = ""

IF (str1 == ") return" "

Byte [] w = new byte [str1.Length / 2];

For (int i = 0; i

ReturnValue = system.text.Encoding.default.getstring (w); return returnvalue;} ///

/// 16 enroller //// /// /// /// byte hextostr (string str1, int spage) {string returnValue; int IPTEMP; int = convert .Toint32 (spage); int startint = 0; int tent1nguint = 2;

INTTEMP = str1.length; // get string length if (ipage == 1) {startint = 0; ionthint = 2;} else {startint = (ipage-1) * iLENGTHINT;

IF ((INTTEMP-IPAGE * 2) <2) {isengthint = INTTEMP- (ipage-1) * 2;} else {ilengthint = 2;}}

ReturnValue = str1.substring (startint, ilengthint);

ReturnValue = ConvertString (ReturnValue, 16, 10);

Return Convert.Tobyte (ReturnValue);

转载请注明原文地址:https://www.9cbs.com/read-103321.html

New Post(0)