You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
25 lines
587 B
C#
25 lines
587 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
|
|
namespace Admin.Core.Common.Helper
|
|
{
|
|
public class StringChange
|
|
{
|
|
public static string bytesToHexStr(byte[] bytes, int iLen)//e.g. { 0x01, 0x01} ---> " 01 01"
|
|
{
|
|
string returnStr = "";
|
|
if (bytes != null)
|
|
{
|
|
for (int i = 0; i < iLen; i++)
|
|
{
|
|
returnStr += bytes[i].ToString("X2");
|
|
}
|
|
}
|
|
return returnStr;
|
|
}
|
|
}
|
|
}
|