I have a zip file decoded in base 64bit (it’s a string). I want to take that string, convert it to 32bit and create the zip file. How can i do it?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Edited.
Check out http://www.atrevido.net/blog/2004/01/13/Base32%2BIn%2BNET.aspx if you need a base32 representation of your bytes.
If you just need to create a zip file from at base64 encoded string, convert it to byte[] and write it to a zip stream:
byte[] bytes = Convert.FromBase64String(base64String);
GZipStream stream..
stream.Write(bytes,0,bytes.length);
The base 64 string contains a representation of your bytes – it’s not a 64 bit representation, it’s a 64 characters representation: http://en.wikipedia.org/wiki/Base64