I would like to convert a decimal number (base10) into hexadecimal and then save it into an unsigned char array.
I have an integer whose value increments from 1024 to a max of 2047 in steps of 1 whenever the user clicks a button. At each step I need to convert it to a hexadecimal number and save it into an unsigned char array or 2 elements so that I can send it to a device via USB.
If I want to send 1955 decimal number I would like to have my unsigned char array as below
Out = 0x07;
out = 0xA3
then I can use my transferdata(out) function.
In order to provide the ability to use many different languages in .net, and for components written in one language operate with components written in another, we need to use the same primitive types. These are supplied by the CTS.
*pre-emptive celebratory nipple tassle jiggle* - Sean Ewington
As we develop application in different language so they have different way of defining variable so How CLR will understand this.So for this .net define CTS like in c# we have int in VB we have Integer when they complied they are converted to Sysyem.int32 which is common for both language.
In Microsoft's .NET Framework, the Common Type System (CTS) is a standard that specifies how Type definitions and specific values of Types are represented in computer memory. It is intended to allow programs written in different programming languages to easily share information.