in your declaration of the WritePrivateProfileSection, change the "As
String" to "As Any".
Jimmy
Leonard Bosco <ldmfu...@worldnet.att.net> wrote in message
news:370D4B4B...@worldnet.att.net...
Not quite accurate. Try bvNullString instead. vbNull is a special types of
Null, I think used mainly for VBA type stuff. The Chr$(0) would probably
work though, since I think the function would interpret it as a pointer to a
null.
Sometimes I get really confused about the difference between a pointer to a
Null, and a Null pointer. If anyone would care to elaborate on this topic,
Please Do!
Unless I am misunderstanding your question, the problem stems from
overloading the word "null". In the domain of computer programming the word
"null" can have at least three distinct meanings:
1) An ASCII character represented by a value of 0 (e.g., '\0'). Generally
interpreted as "end of string", at least in C.
2) A special value a pointer can have that indicates it is not pointing to
any memory location (e.g., int* x = 0);
3) A special value a database field can contain to indicate the value it
contains is unknown.
Notes:
N1) A "null string" is a string consisting of a single ASCII "null"
character as defined in 1, above.
N2) A "null pointer" is a pointer as defined in 2, above. A "null pointer"
can never point to a "null string" ( or anything else for that matter).
N3) A "null" generally means a "null" character as defined in 1, above.
However, you need to understand the context to be sure.
Confusing enough?
--
- Barry L. Wallis
- Oceanside, California, USA
Da Man wrote in message ...
Tom
Leonard Bosco wrote in message <370D4B4B...@worldnet.att.net>...
Barry L. Wallis <walli...@earthlink.net> schrieb in im Newsbeitrag:
7ennsi$esq$1...@holly.prod.itd.earthlink.net...
> The following is from a C/C++ perspective. A VB programmer may put a
> different spin on the examples, however, the definitions should be the
same.
>
> Unless I am misunderstanding your question, the problem stems from
> overloading the word "null". In the domain of computer programming the
word
> "null" can have at least three distinct meanings:
>
> 1) An ASCII character represented by a value of 0 (e.g., '\0'). Generally
> interpreted as "end of string", at least in C.
>
> 2) A special value a pointer can have that indicates it is not pointing to
> any memory location (e.g., int* x = 0);
>
> 3) A special value a database field can contain to indicate the value it
> contains is unknown.
Sorry, but ... no.
If a database field (at least a jet database field) is NULL it means the
field is not CREATED.
The field defenition exists in the table, but on storing the values for the
record, the field was not filled, and therefore not created.
To make it more clear, a text field can be set to 255 chars.
On saving only 1 char in it, 255 chars are reserved on the HD.
If, on the other hand, you put 0 chars in it (either by putting NULL or not
putting anything at all in it), the field won't exist on the HD.
BTW, this goes for any type of field, not only for text fields :-)
>
>
> Notes:
>
> N1) A "null string" is a string consisting of a single ASCII "null"
> character as defined in 1, above.
>
> N2) A "null pointer" is a pointer as defined in 2, above. A "null pointer"
> can never point to a "null string" ( or anything else for that matter).
>
> N3) A "null" generally means a "null" character as defined in 1, above.
> However, you need to understand the context to be sure.
>
> Confusing enough?
> --
>
> - Barry L. Wallis
> - Oceanside, California, USA
>
--
Hope this helps ...
Rene Whitworth
Whitworth Software Solutions - Germany
http://www.w-s-s.de
Please reply to the newsgroup :-)