<br><font size=2 face="sans-serif">I'm trying to compile a program using the Win32 API function GetComputerName, but when I do I get the message "Error: Can't determine which overloaded function to call". The string GetComputerName does not exist anywhere in my code, other then this one line where I attempt to call that function, so it's not being overloaded by me.  :-)</font>
<br>
<br><font size=2 face="sans-serif">If I call the function explicitly -- GetComputerName.WINDOWS -- I don't get the overload error but I do get these two messages "Error: Wrong amount of parameters specified" and "Fatal: Syntax error, ";" expected but "(" found". According to ascdef.inc the calling convention is "function GetComputerName(lpBuffer:LPSTR; nSize:LPDWORD):WINBOOL;".</font>
<br>
<br><font size=2 face="sans-serif">The portion of my source code in question looks like this:</font>
<br>
<br><font size=2 face="sans-serif">const</font>
<br><font size=2 face="sans-serif">  MAX_SIZE = 255;</font>
<br>
<br><font size=2 face="sans-serif">var</font>
<br><font size=2 face="sans-serif">  NullString : pchar;</font>
<br>
<br><font size=2 face="sans-serif">GetComputerName.WINDOWS (NullString,MAX_SIZE);</font>
<br>
<br>
<br><font size=2 face="sans-serif">The Win32 API reference looks pretty much the same:</font>
<br>
<br><font size=2 face="sans-serif">BOOL GetComputerName</font>
<br><font size=2 face="sans-serif">(</font>
<br><font size=2 face="sans-serif">    LPTSTR lpBuffer,        // address of name buffer </font>
<br><font size=2 face="sans-serif">    LPDWORD nSize         // address of size of name buffer </font>
<br><font size=2 face="sans-serif"> );</font>
<br>
<br>
<br><font size=2 face="sans-serif">ppc386 -i says this:</font>
<br>
<br><font size=2 face="sans-serif">Free Pascal Compiler version 1.1</font>
<br><font size=2 face="sans-serif">Compiler Date  : 2001/06/19</font>
<br><font size=2 face="sans-serif">Compiler Target: i386</font>
<br>
<br>
<br><font size=2 face="sans-serif">It's probably fairly obvious, but I sure can't see it. Can anyone see what I'm doing wrong here? TIA...</font>
<br>
<br><font size=2 face="sans-serif">Jim</font>