I converted a String to BigInteger as follows:
String
BigInteger
Scanner sc=new Scanner(System.in); System.out.println(\"enter the message\"); String
You can also use Java's implicit conversion:
BigInteger m = new BigInteger(bytemsg); String mStr = "" + m; // mStr now contains string representation of m.