473,388 Members | 1,326 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,388 software developers and data experts.

Numeric to array of byte

I know about BitConverter to convert an array of Byte to a numerical value
(like ToInt64). I haven't been able to find the inverse -- to convert the
numerical variable into an array of Byte.

Is there such methods in the Framework?

Richard Rosenheim
Nov 21 '05 #1
2 1099
See BitConverter.GetBytes(). It has many overloads for various data types.

"Richard L Rosenheim" <ri*****@rlr.com> wrote in message
news:u7**************@TK2MSFTNGP14.phx.gbl...
I know about BitConverter to convert an array of Byte to a numerical value
(like ToInt64). I haven't been able to find the inverse -- to convert the
numerical variable into an array of Byte.

Is there such methods in the Framework?

Richard Rosenheim

Nov 21 '05 #2
Thanks -- I completely missed it.

Richard Rosenheim
"Shiva" <sh******@online.excite.com> wrote in message
news:uZ**************@TK2MSFTNGP10.phx.gbl...
See BitConverter.GetBytes(). It has many overloads for various data types.

"Richard L Rosenheim" <ri*****@rlr.com> wrote in message
news:u7**************@TK2MSFTNGP14.phx.gbl...
I know about BitConverter to convert an array of Byte to a numerical value
(like ToInt64). I haven't been able to find the inverse -- to convert the
numerical variable into an array of Byte.

Is there such methods in the Framework?

Richard Rosenheim

Nov 21 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Phil | last post by:
Hi, I don't understand this strange behaviour: I compile this code : #include <Python.h> #include"Numeric/arrayobject.h" static PyObject *
1
by: Philippe Grosse | last post by:
Hi, I don't understand this strange behaviour: I compile this code : #include <Python.h> #include"Numeric/arrayobject.h" static PyObject *
0
by: Travis Oliphant | last post by:
Numarray is making great progress and is quite usable for many purposes. An idea that was championed by some is that the Numeric code base would stay static and be replaced entirely by Numarray. ...
1
by: Kamilche | last post by:
I have a need to multiply all the bytes in a Numeric array, by a float, such as .9, .8, etc. I can't figure out a way to do that. Does anyone have a clue how this is accomplished? I need the...
5
by: bandw | last post by:
I am having a problem using Numeric-24.0b2 in conjunction with the NetCDF module from ScientificPython (version 2.4.9). This problem does not surface using Numeric-23.8. The problem arises in...
6
by: Anders Würtz | last post by:
i have an assignment to iterate through a collection containing different types of numeric values (float, double, int, byte, short etc.) and to add 1 to all of them. I tried with array and...
7
by: Sheldon | last post by:
Hi, I have the following loop that I think can be written to run faster in Numeric. I am currently using Numeric. range_va = main.xsize= 600 main.ysize= 600 #msgva is an (600x600) Numeric...
11
by: Jiang Nutao | last post by:
Hi, I simplify my problem like below To convert list aa = into How to do it fast? My real list is huge.
8
by: Frank Swarbrick | last post by:
My DBA says that a column defined, for instance, as DECIMAL(11,2) and containing a value of 1.00 takes up no more space on the database disk than a column defined as DECIMAL(7,2) and containing a...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.