467,915 Members | 1,146 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 467,915 developers. It's quick & easy.

a problem with copymem API

i am using the following code

private var1 as Long
private var2 as Long
private var3 as Long

ReDim bytearray(0 To 3)
ReDim bytearray2(0 To 3)

For a = 0 To 3
bytearray(a) = Asc(Mid(DataSource, b, 1))
bytearray2(a) = Asc(Mid(DataSource2, c, 1))
b = b + 1
c = c + 1
Next a

var1 = IVbytearray(0) & IVbytearray(1) & IVbytearray(2) & IVbytearray(3)
var2 = IVbytearray2(0) & IVbytearray2(1) & IVbytearray2(2) & IVbytearray2(3)

CopyMemory var1, var1 Xor var2, 4
CopyMemory var1, var1 Xor var3, 4

an overflow error is sometimes thrown up in the copymemory api, how do i fix
it?
Feb 14 '07 #1
  • viewed: 3840
Share:
23 Replies
On Thu, 15 Feb 2007 10:27:25 +1100, "Antony Clements"
<an*************@optusnet.com.auwrote:
>i am using the following code

private var1 as Long
private var2 as Long
private var3 as Long

ReDim bytearray(0 To 3)
ReDim bytearray2(0 To 3)

For a = 0 To 3
bytearray(a) = Asc(Mid(DataSource, b, 1))
bytearray2(a) = Asc(Mid(DataSource2, c, 1))
b = b + 1
c = c + 1
Next a

var1 = IVbytearray(0) & IVbytearray(1) & IVbytearray(2) & IVbytearray(3)
var2 = IVbytearray2(0) & IVbytearray2(1) & IVbytearray2(2) & IVbytearray2(3)

CopyMemory var1, var1 Xor var2, 4
CopyMemory var1, var1 Xor var3, 4

an overflow error is sometimes thrown up in the copymemory api, how do i fix
it?
I can't make any sense of this code
- you don't use & for building a Long out of Bytes

If you described what you are trying to do, then maybe we can come up
with a suggestion.
Feb 15 '07 #2
i modified the code after i posted this, it no longer throws up an error but
it still doesn't work correctly.

dim var1 var2 and var3 as long

ReDim IVbytearray(0 To 7)
ReDim IVbytearray2(0 To 7)

bytearray() = Mid(stream1, b, 8)
bytearray2() = Mid(stream2, c, 8) 'a messagebox here proves that at this
point, the data held in bytearray() is different than the data held in
bytearray2()

var1 = bytearray()
var2 = bytearray2() 'this is where the problem is as var2 returns the same
value as var1 even though the value in bytearray() is different to the value
in bytearray2().

Call CopyMemory(var1, var1 Xor var2, 8)
Call CopyMemory(var1, var1 Xor var3, 8)
now here is the problem. even though the data source for bytearray() and
bytearray2() are different, for some reason or other they both have the same
value. var2 needs to be a value from the second data source. i hope this is
a clear indication of what i am trying to do.

"J French" <er*****@nowhere.ukwrote in message
news:45**************@news.btopenworld.com...
On Thu, 15 Feb 2007 10:27:25 +1100, "Antony Clements"
<an*************@optusnet.com.auwrote:
>>i am using the following code

private var1 as Long
private var2 as Long
private var3 as Long

ReDim bytearray(0 To 3)
ReDim bytearray2(0 To 3)

For a = 0 To 3
bytearray(a) = Asc(Mid(DataSource, b, 1))
bytearray2(a) = Asc(Mid(DataSource2, c, 1))
b = b + 1
c = c + 1
Next a

var1 = IVbytearray(0) & IVbytearray(1) & IVbytearray(2) & IVbytearray(3)
var2 = IVbytearray2(0) & IVbytearray2(1) & IVbytearray2(2) &
IVbytearray2(3)

CopyMemory var1, var1 Xor var2, 4
CopyMemory var1, var1 Xor var3, 4

an overflow error is sometimes thrown up in the copymemory api, how do i
fix
it?

I can't make any sense of this code
- you don't use & for building a Long out of Bytes

If you described what you are trying to do, then maybe we can come up
with a suggestion.


Feb 15 '07 #3
Antony Clements wrote:
i modified the code after i posted this, it no longer throws up an error but
it still doesn't work correctly.

dim var1 var2 and var3 as long

ReDim IVbytearray(0 To 7)
ReDim IVbytearray2(0 To 7)
These are redundant as they are replaced in the next block.
bytearray() = Mid(stream1, b, 8)
bytearray2() = Mid(stream2, c, 8) 'a messagebox here proves that at this
point, the data held in bytearray() is different than the data held in
bytearray2()
This copies a UNICODE string into the byte array.
This will be 16 bytes, every other one being a null character.

If you want each character as an item in the array, then you want:
bytearray = StrConv(string, vbFromUnicode)
var1 = bytearray()
var2 = bytearray2() 'this is where the problem is as var2 returns the same
value as var1 even though the value in bytearray() is different to the value
in bytearray2().
From the code below, you can't join them up like this.
You will need to do the arithmetic manually (shifting and adding) or
copymemory from the byte array to a long.
Bear in mind that you can only fit 4 bytes in a long...
Call CopyMemory(var1, var1 Xor var2, 8)
Call CopyMemory(var1, var1 Xor var3, 8)
Be VERY careful as longs are still only 4 bytes.
you WILL be corrupting memory with this code.
now here is the problem. even though the data source for bytearray() and
bytearray2() are different, for some reason or other they both have the same
value. var2 needs to be a value from the second data source. i hope this is
a clear indication of what i am trying to do.
It still doesn't explain what you have and what results you want at the
end...

--
Dean Earley (de*********@icode.co.uk)
i-Catcher Development Team

iCode Systems
Feb 15 '07 #4
Dean Earley wrote:
Antony Clements wrote:
>bytearray() = Mid(stream1, b, 8)
bytearray2() = Mid(stream2, c, 8) 'a messagebox here proves that at
this point, the data held in bytearray() is different than the data
held in bytearray2()

This copies a UNICODE string into the byte array.
This will be 16 bytes, every other one being a null character.

If you want each character as an item in the array, then you want:
bytearray = StrConv(string, vbFromUnicode)
This does assume a normal ANSI string. It will be longer if you have non
ANSI data in your string

--
Dean Earley (de*********@icode.co.uk)
i-Catcher Development Team

iCode Systems
Feb 15 '07 #5
if stream1 has a value of 1a2b3c4d i want bytearray() to return the asc
value of the string. the only way i know how to do this is take each
character convert to ascii and then place in a string and then place the
string in bytearray(). i'm looking for a simpler way. var1 and var2 are
always returning the value of 1306840 regardless. bytearray() will return
1a2b3c4d. i am copying the bytearray variables to long variables. the
problem will be solved once var1 and var2 are correct values.

"Dean Earley" <de*********@icode.co.ukwrote in message
news:45***********************@news.zen.co.uk...
Antony Clements wrote:
>i modified the code after i posted this, it no longer throws up an error
but it still doesn't work correctly.

dim var1 var2 and var3 as long

ReDim IVbytearray(0 To 7)
ReDim IVbytearray2(0 To 7)

These are redundant as they are replaced in the next block.
>bytearray() = Mid(stream1, b, 8)
bytearray2() = Mid(stream2, c, 8) 'a messagebox here proves that at this
point, the data held in bytearray() is different than the data held in
bytearray2()

This copies a UNICODE string into the byte array.
This will be 16 bytes, every other one being a null character.

If you want each character as an item in the array, then you want:
bytearray = StrConv(string, vbFromUnicode)
>var1 = bytearray()
var2 = bytearray2() 'this is where the problem is as var2 returns the
same value as var1 even though the value in bytearray() is different to
the value in bytearray2().

From the code below, you can't join them up like this.
You will need to do the arithmetic manually (shifting and adding) or
copymemory from the byte array to a long.
Bear in mind that you can only fit 4 bytes in a long...
>Call CopyMemory(var1, var1 Xor var2, 8)
Call CopyMemory(var1, var1 Xor var3, 8)

Be VERY careful as longs are still only 4 bytes.
you WILL be corrupting memory with this code.
>now here is the problem. even though the data source for bytearray() and
bytearray2() are different, for some reason or other they both have the
same value. var2 needs to be a value from the second data source. i hope
this is a clear indication of what i am trying to do.

It still doesn't explain what you have and what results you want at the
end...

--
Dean Earley (de*********@icode.co.uk)
i-Catcher Development Team

iCode Systems

Feb 15 '07 #6
the data is from the full ascii range
"Dean Earley" <de*********@icode.co.ukwrote in message
news:45**********************@news.zen.co.uk...
Dean Earley wrote:
>Antony Clements wrote:
>>bytearray() = Mid(stream1, b, 8)
bytearray2() = Mid(stream2, c, 8) 'a messagebox here proves that at this
point, the data held in bytearray() is different than the data held in
bytearray2()

This copies a UNICODE string into the byte array.
This will be 16 bytes, every other one being a null character.

If you want each character as an item in the array, then you want:
bytearray = StrConv(string, vbFromUnicode)

This does assume a normal ANSI string. It will be longer if you have non
ANSI data in your string

--
Dean Earley (de*********@icode.co.uk)
i-Catcher Development Team

iCode Systems

Feb 15 '07 #7
i eralilse what i said i'm trying to do is quite vague. the purpose of the
code is the core of a stream cipher where they key is defined as

key = var1 xor var2 xor var3 where var3 is (2147483647 * rnd). what happens
next is cipherbyte = chr((messagebyte xor key) mod 256)
>Call CopyMemory(var1, var1 Xor var2, 8)
Call CopyMemory(var1, var1 Xor var3, 8)
does actually work as written.

the problem is that var1 and var2 are always the same constant no matter
what the source is.

"Dean Earley" <de*********@icode.co.ukwrote in message
news:45***********************@news.zen.co.uk...
Antony Clements wrote:
>i modified the code after i posted this, it no longer throws up an error
but it still doesn't work correctly.

dim var1 var2 and var3 as long

ReDim IVbytearray(0 To 7)
ReDim IVbytearray2(0 To 7)

These are redundant as they are replaced in the next block.
>bytearray() = Mid(stream1, b, 8)
bytearray2() = Mid(stream2, c, 8) 'a messagebox here proves that at this
point, the data held in bytearray() is different than the data held in
bytearray2()

This copies a UNICODE string into the byte array.
This will be 16 bytes, every other one being a null character.

If you want each character as an item in the array, then you want:
bytearray = StrConv(string, vbFromUnicode)
>var1 = bytearray()
var2 = bytearray2() 'this is where the problem is as var2 returns the
same value as var1 even though the value in bytearray() is different to
the value in bytearray2().

From the code below, you can't join them up like this.
You will need to do the arithmetic manually (shifting and adding) or
copymemory from the byte array to a long.
Bear in mind that you can only fit 4 bytes in a long...
>Call CopyMemory(var1, var1 Xor var2, 8)
Call CopyMemory(var1, var1 Xor var3, 8)

Be VERY careful as longs are still only 4 bytes.
you WILL be corrupting memory with this code.
>now here is the problem. even though the data source for bytearray() and
bytearray2() are different, for some reason or other they both have the
same value. var2 needs to be a value from the second data source. i hope
this is a clear indication of what i am trying to do.

It still doesn't explain what you have and what results you want at the
end...

--
Dean Earley (de*********@icode.co.uk)
i-Catcher Development Team

iCode Systems

Feb 16 '07 #8
On Fri, 16 Feb 2007 09:46:04 +1100, "Antony Clements"
<an*************@optusnet.com.auwrote:
>if stream1 has a value of 1a2b3c4d i want bytearray() to return the asc
value of the string. the only way i know how to do this is take each
character convert to ascii and then place in a string and then place the
string in bytearray(). i'm looking for a simpler way. var1 and var2 are
always returning the value of 1306840 regardless. bytearray() will return
1a2b3c4d. i am copying the bytearray variables to long variables. the
problem will be solved once var1 and var2 are correct values.
I still don't follow what you are trying to do.

It looks as if you want to compute some sort of 32 bit number from an
8 character String.
Feb 16 '07 #9
Antony Clements wrote:
if stream1 has a value of 1a2b3c4d i want bytearray() to return the asc
value of the string. the only way i know how to do this is take each
character convert to ascii and then place in a string and then place the
string in bytearray().
As I said...
If you want each character as an item in the array, then you want:
bytearray = StrConv(string, vbFromUnicode)
From a string of "1a2b3c4d", this will give you an 8 item array
containing: 49, 97, 50, 98, 51, 99, 52, 100,

IF however, you want the 32bit equivalent of that hex encoded string (if
it is hex) then you will need to manually split it on every two
characters and pass it through val("&H" & hexvalue) and store each part
in the array.

--
Dean Earley (de*********@icode.co.uk)
i-Catcher Development Team

iCode Systems
Feb 16 '07 #10
It looks as if you want to compute some sort of 32 bit number from an
8 character String.
the numbers i am trying to generate from the string has a minimum value of
00000000 and a maximum of 255255255255255255255255 wich are the ascii codes
of 8 characters.

the block of code works except for those 2 little lines that don't return
correct values. no data type that i know of will support such a large number
but it is critical that the code does, and i wouldnt know where to begin to
write a type def that will support such a large number either.
Feb 16 '07 #11
stream1 is a pseudorandom string that can containing every character
available within the ansi standard with an undefined length. stream2 has a
defined length of 512 bits but can still contain any combination of
characters within the full ansi standard. that is characters with an ascii
code of 0 to 255. this means that var1 and var2 must hold a maximum number
of 255255255255. no data type that i know of will ever hold such a large
number except maybe a type def variable. but i wouldnt know where to begin
writing one to hold such a large number. i don't think converting from
unicode to ansi will have any positive effect on the rest of the code.

"Dean Earley" <de*********@icode.co.ukwrote in message
news:45***********************@news.zen.co.uk...
Antony Clements wrote:
>if stream1 has a value of 1a2b3c4d i want bytearray() to return the asc
value of the string. the only way i know how to do this is take each
character convert to ascii and then place in a string and then place the
string in bytearray().

As I said...
If you want each character as an item in the array, then you want:
bytearray = StrConv(string, vbFromUnicode)

From a string of "1a2b3c4d", this will give you an 8 item array
containing: 49, 97, 50, 98, 51, 99, 52, 100,

IF however, you want the 32bit equivalent of that hex encoded string (if
it is hex) then you will need to manually split it on every two characters
and pass it through val("&H" & hexvalue) and store each part in the array.

--
Dean Earley (de*********@icode.co.uk)
i-Catcher Development Team

iCode Systems

Feb 16 '07 #12
correction of mistake. i am only grabbing 4 bytes of both strings instead of
the original 8 and am trying to generate a number between 0 and 255255255255
from each 4 byte block of string
"J French" <er*****@nowhere.ukwrote in message
news:45**************@news.btopenworld.com...
On Fri, 16 Feb 2007 09:46:04 +1100, "Antony Clements"
<an*************@optusnet.com.auwrote:
>>if stream1 has a value of 1a2b3c4d i want bytearray() to return the asc
value of the string. the only way i know how to do this is take each
character convert to ascii and then place in a string and then place the
string in bytearray(). i'm looking for a simpler way. var1 and var2 are
always returning the value of 1306840 regardless. bytearray() will return
1a2b3c4d. i am copying the bytearray variables to long variables. the
problem will be solved once var1 and var2 are correct values.

I still don't follow what you are trying to do.

It looks as if you want to compute some sort of 32 bit number from an
8 character String.


Feb 16 '07 #13
Antony Clements wrote:
stream1 is a pseudorandom string that can containing every character
available within the ansi standard with an undefined length. stream2
has a defined length of 512 bits but can still contain any
combination of characters within the full ansi standard. that is
characters with an ascii code of 0 to 255. this means that var1 and
var2 must hold a maximum number of 255255255255.
So you want ascii value string concatenation rather than just the
decimal value of the 4 byte string?

If this really is the case (I don't believe it is) then use the strconv
code I gave you and join the byte array items together in a string and
convert the result to a number rather than copymemory into a long.
no data type that i know of will ever hold such a large number except
maybe a type def variable. but i wouldnt know where to begin writing
one to hold such a large number.
The currency data type will
i don't think converting from unicode to ansi will have any positive
effect on the rest of the code.
Yes it will, it will give you the real ascii values in a byte array
rather than utf16 unicode in a byte array.

You seem to be missing the point by a very long way here.

What EXACTLY do you have as input, what do you expect the intermediary
and final values to be?

--
Dean Earley (de*********@icode.co.uk)
i-Catcher Development Team

iCode Systems
Feb 16 '07 #14
So you want ascii value string concatenation rather than just the
decimal value of the 4 byte string?
i would prefer the decimal value, but the decimal value remains constant
regardless of what 4 bytes i pull from the streams, it is always 1306840
The currency data type will
i tried currency, it threw up an error
Yes it will, it will give you the real ascii values in a byte array
rather than utf16 unicode in a byte array.

You seem to be missing the point by a very long way here.

What EXACTLY do you have as input, what do you expect the intermediary
and final values to be?
i gave you an example for an input from stream2 "1a2b" which is input into a
bytearray, it is meant to return a dynamic number that changes as input
changes not a constant. even if the input from the stream was "help" it
still returns the same decimal value of 1306840. even if the input is 8
bytes "1a2b3c4d" it still returns the exact same value of 1306840. the point
i am making is that it doesn't matter what the input is, or how long the
input is, i get the same value from both streams regardless. the number that
gets returned from stream1 and stream2 must always be different depending on
the input.
Feb 16 '07 #15
On Fri, 16 Feb 2007 23:09:35 +1100, "Antony Clements"
<an*************@optusnet.com.auwrote:
>correction of mistake. i am only grabbing 4 bytes of both strings instead of
the original 8 and am trying to generate a number between 0 and 255255255255
from each 4 byte block of string
You could just use CopyMemory to slap the 4 character string into a 4
byte long

This is not reliable in Far Eastern locales which use Multi Byte
Character Sets, but with those areas the bets are off for strings.

I gather you are doing some sort of encryption.
Feb 17 '07 #16
you would be correct mr French. i have tried everything i know before i came
to ask for help, including everything that mr earley suggested, they all
work some occasions and throw up overflow errors on other occasions.

what i really need is work around so that no error occurs at all. the only
way to do this is to only take three characters at a time and this is not
acceptable in the long term. using CopyMemory in the way you just suggested
as it will throw up an error unless the long is unsigned. i know there is a
way in which to allow for an unsigned variable, but i'm not sure how this is
achieved.

"J French" <er*****@nowhere.ukwrote in message
news:45**************@news.btopenworld.com...
On Fri, 16 Feb 2007 23:09:35 +1100, "Antony Clements"
<an*************@optusnet.com.auwrote:
>>correction of mistake. i am only grabbing 4 bytes of both strings instead
of
the original 8 and am trying to generate a number between 0 and
255255255255
from each 4 byte block of string

You could just use CopyMemory to slap the 4 character string into a 4
byte long

This is not reliable in Far Eastern locales which use Multi Byte
Character Sets, but with those areas the bets are off for strings.

I gather you are doing some sort of encryption.

Feb 17 '07 #17
On Sat, 17 Feb 2007 21:42:28 +1100, "Antony Clements"
<an*************@optusnet.com.auwrote:
>you would be correct mr French. i have tried everything i know before i came
to ask for help, including everything that mr earley suggested, they all
work some occasions and throw up overflow errors on other occasions.

what i really need is work around so that no error occurs at all. the only
way to do this is to only take three characters at a time and this is not
acceptable in the long term. using CopyMemory in the way you just suggested
as it will throw up an error unless the long is unsigned. i know there is a
way in which to allow for an unsigned variable, but i'm not sure how this is
achieved.
I've been using CopyMemory for years with any old data, what happens
is the 'string' is converted to four ANSI characters and then shoved
into the Long. The sign does not matter a jot.

As I mentioned earlier this is dangerous in MBCS Locales as 8 bytes of
Unicode could convert into eight bytes of ANSI instead of four bytes.

I think that you are running into another problem.

Best you describe what you want to send in to a function and then what
you want to get out.
Feb 17 '07 #18
i am grabbing two 4 byte strings and placing them in a long one ascii code
at a time since i can't get any dynamic values any other way. this means
that both inputs are between 000 and 255255255 or three bytes of data. these
values will fit into a long. the end goal is to have a sub where i can
manipulate how many bytes are taken and converted into their respective
ascii codes, or a decimal value of the string. either is acceptable but i
think that things will work better with the ascii codes as placing a byte
array in a long returns a static value regardless of what is actually in the
byte array.

for an effective encryption sequence both strings need to be at least 4
bytes, for this reason i am using a double instead because it can fit the
ascii codes of 4 characters in it. these strings must be turrned into a
value so they can be XOR'd together. the result of this is then XOR'd with a
random value, the result of this is then XOR'd with the ascii code of the
byte of the file that is being encrypted and then mod 256. taking 4 bytes
from each will on occasion throw up an overflow error in a double data type
and will not work at all with a long. if you still don't understand what i
am trying to do then i will be happy to post the block of code so you can
see exactly what it is doing and where it is not working.

"J French" <er*****@nowhere.ukwrote in message
news:45***************@news.btopenworld.com...
On Sat, 17 Feb 2007 21:42:28 +1100, "Antony Clements"
<an*************@optusnet.com.auwrote:
>>you would be correct mr French. i have tried everything i know before i
came
to ask for help, including everything that mr earley suggested, they all
work some occasions and throw up overflow errors on other occasions.

what i really need is work around so that no error occurs at all. the only
way to do this is to only take three characters at a time and this is not
acceptable in the long term. using CopyMemory in the way you just
suggested
as it will throw up an error unless the long is unsigned. i know there is
a
way in which to allow for an unsigned variable, but i'm not sure how this
is
achieved.

I've been using CopyMemory for years with any old data, what happens
is the 'string' is converted to four ANSI characters and then shoved
into the Long. The sign does not matter a jot.

As I mentioned earlier this is dangerous in MBCS Locales as 8 bytes of
Unicode could convert into eight bytes of ANSI instead of four bytes.

I think that you are running into another problem.

Best you describe what you want to send in to a function and then what
you want to get out.

Feb 17 '07 #19
J French wrote:
On Fri, 16 Feb 2007 23:09:35 +1100, "Antony Clements"
<an*************@optusnet.com.auwrote:
>correction of mistake. i am only grabbing 4 bytes of both strings instead of
the original 8 and am trying to generate a number between 0 and 255255255255
from each 4 byte block of string

You could just use CopyMemory to slap the 4 character string into a 4
byte long

This is not reliable in Far Eastern locales which use Multi Byte
Character Sets, but with those areas the bets are off for strings.

I gather you are doing some sort of encryption.
No, you CAN'T just CopyMemory from a 4 char string to a 4 byte long (and
get the results you expect.
As per my previous email, strings in vb are UTF-16 Unicode, meaning that
for normal ASCII text, EVERY character is followed by a single null byte.

To get the ASCII value of each character in each member of a byte array
(which you just proposed), you WILL need to use StrConv (unless you feel
like manually copying each character)

--
Dean Earley (de*********@icode.co.uk)
i-Catcher Development Team

iCode Systems
Feb 19 '07 #20
Dean Earley wrote:
J French wrote:
>On Fri, 16 Feb 2007 23:09:35 +1100, "Antony Clements"
<an*************@optusnet.com.auwrote:
>>correction of mistake. i am only grabbing 4 bytes of both strings
instead of the original 8 and am trying to generate a number between
0 and 255255255255 from each 4 byte block of string

You could just use CopyMemory to slap the 4 character string into a 4
byte long

This is not reliable in Far Eastern locales which use Multi Byte
Character Sets, but with those areas the bets are off for strings.

I gather you are doing some sort of encryption.

No, you CAN'T just CopyMemory from a 4 char string to a 4 byte long (and
get the results you expect.
As per my previous email, strings in vb are UTF-16 Unicode, meaning that
for normal ASCII text, EVERY character is followed by a single null byte.

To get the ASCII value of each character in each member of a byte array
(which you just proposed), you WILL need to use StrConv (unless you feel
like manually copying each character)
Admittedly, I was assuming you were using the standard declaration of
CopyMemory that takes two pointers rather than a string which is
transparently converted by VB before being passed.

I still highly recommend using just StrConv for this operation.

--
Dean Earley (de*********@icode.co.uk)
i-Catcher Development Team

iCode Systems
Feb 19 '07 #21
On Mon, 19 Feb 2007 09:17:38 +0000, Dean Earley
<de*********@icode.co.ukwrote:
>Dean Earley wrote:
<snip>
>I still highly recommend using just StrConv for this operation.

--
Dean Earley (de*********@icode.co.uk)
i-Catcher Development Team

iCode Systems
Well mostly I recommend that you know before you post
Feb 19 '07 #22
J French wrote:
On Mon, 19 Feb 2007 09:17:38 +0000, Dean Earley
<de*********@icode.co.ukwrote:
>Dean Earley wrote:
<snip>
>I still highly recommend using just StrConv for this operation.

Well mostly I recommend that you know before you post
I did, hence my post...

--
Dean Earley (de*********@icode.co.uk)
i-Catcher Development Team

iCode Systems
Feb 19 '07 #23
i couldn't get the strconv to work with what i am trying to do, so i am
retrieving the ASCII code for each character and concatenating it into a
double variable.
To get the ASCII value of each character in each member of a byte array
(which you just proposed), you WILL need to use StrConv (unless you feel
like manually copying each character)

--
Dean Earley (de*********@icode.co.uk)
i-Catcher Development Team

iCode Systems

Feb 20 '07 #24

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by Richard Galli | last post: by
reply views Thread by FreeStyle | last post: by
3 posts views Thread by Marcus | last post: by
2 posts views Thread by fartsniff | last post: by
2 posts views Thread by Fredrik Jonson | last post: by
reply views Thread by Aldo Polli | last post: by
2 posts views Thread by Marcus | last post: by
1 post views Thread by Randell D. | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.