Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

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.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8265839
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T04:56:37+00:00 2026-06-08T04:56:37+00:00

I have a csv string to bytes and i want to convert it in

  • 0

I have a csv string to bytes and i want to convert it in java byte array. Can anyone help me.

csv string

167, 27, 32, 195

The byte array should be like this

byte[0] should give me 167
byte[1] should give me 27
byte[2] should give me 32
byte[3] should give me 195
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T04:56:38+00:00Added an answer on June 8, 2026 at 4:56 am

    You can use an array of characters. The char type is intended to represent characters in Java.

    String csv = "167, 27, 32, 195";
    String[] numbers = csv.split(", ");
    char[] chars = new char[numbers.length];
    for (int i = 0; i < numbers.length; i++)
        chars[i] = (char)Integer.parseInt(numbers[i]);
    

    This method assumes that the numbers in the CSV file are Unicode code points of the characters.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a csv string like this 1,2,3 and want to be able to
I have a list of string that I am writing out to a CSV
I have the following piece of Java code that reads strings from CSV file.
I have CSV text thats stored in the session array as csv. The lines
I have CSV file and Macro in VBA. I want to open CSV file
i have csv files, java app and database, i read csv file from my
I have a string value read in from a CSV file. The CSV file
I have a varchar field that contains a string like 10,11,12,13. How can I
I'm trying to read CSV files using Java. Some of the files may have
I have a CSV string: string data = G9999999990001800002777107050,G9999999990002777107HMNLAQKPRLLHRAQRWJ010,1,3,29,P,6.74,11.23,07,P,5.25,14.29,08,P,6.89,16.92,2,5,052,U,4.78,31.04,095,O,9.59,27.63,076,P,3.85,16.50,094,P,4.84,18.30,093,O,8.28,26.90,062,P,4.64,16.00,061,P,2.84,12.87,090,O,7.90,20.83,050,P,3.36,16.59,057,B,12.05,34.46,1,1,111,P,7.26,13.79; The first 2 elements are

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.