getBytes
public byte[] getBytes(String enc)
                throws UnsupportedEncodingException
Convert this String into bytes according to the specified character encoding, storing the result into a new byte array.

解决方案 »

  1.   

    Var
       Cyc:Byte;
       Str:String;
       Bytes:Array[1..255] Of Char;
    Begin
       For Cyc:=1 To Length(Str) Do
          Bytes[Cyc]:=Char(Str[Cyc]);
    End.
       
      

  2.   

    for()
    //
    static byte parseByte(String s, int radix) ;
    然后给byte[];
      

  3.   

    jsyx():getBytes 怎么用的 enc 用什么 
      

  4.   

    想起来了,enc : 8859_1 gbk gb2312 and so on!
      

  5.   

    String str="test";
    byte[] bt=str.getBytes();