|
-
Jun 3rd, 2001, 07:23 AM
#1
ByRef argument type mismatch, what is wrong with this little piece of code
Hi,
i can't figure out why i get this error..
All seems fine, i used this code before..
well here it is:
Code:
Dim Inum As Integer
Nget IniLine, "Num", Inum 'i'll explain this down
i use this function to get stuff out of my ini file..
it suppose to get 'Num' from IniLine.
'Num' in the ini file is '6'.
Normaly i would get that Inum = 6, but instead i get a ByRef error..
in the previus line i used the same code:
Code:
Dim Iname As String
Nget IniLine, "Name", Iname
and i got the value of Iname with no trubble..
why is that..??
anyone?
thanks...
-
Jun 3rd, 2001, 08:42 AM
#2
_______
<?>
How are you storing 6 in your file?
integer or string...
"A myth is not the succession of individual images,
but an integerated meaningful entity,
reflecting a distinct aspect of the real world."
___ Adolf Jensen
-
Jun 3rd, 2001, 08:45 AM
#3
Addicted Member
The items stored in the INI file are always strings. Either use val or use an API call such as GetIniInt
-
Jun 3rd, 2001, 08:49 AM
#4
mmmm...
I thought it was integer but you were correct...
It was string and it's working now... i didn't encouter this anywhere before...
thanks..!!
-
Jun 3rd, 2001, 09:05 AM
#5
Addicted Member
oops...
GetIniInt is from one of our proprietary dlls
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|