Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Build of COM server fails
Message
De
30/10/2014 21:29:37
 
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows Server 2012
Network:
Windows 2008 Server
Database:
MS SQL Server
Application:
Web
Divers
Thread ID:
01609784
Message ID:
01610244
Vues:
76
>I'm working with a customer and we're having an issue with the build process for a COM server. On my machine here and another test machine everything works just fine. However, for the customers machine and 2 others he's tried compilation of the COM server results in:
>
>Function argument value, type, or count is invalid
>
>The .exe file is not built. If we remove the one OLEPUBLIC class the project builds fine - it's only when compiling to COM that it fails. There is no errors.txt file since the project actually compiles OK.
>
>I know VFP requires Admin rights in order to and we are running FoxPro with Run as Administrator. I also know that Type library creation can fail if there are invalid characters in the public interface of a COM server, but since it works just fine for me that is unlikely to be the problem.
>
>Has anybody run into this before? Any other ideas what we can try?
>
>Some other thigns I've suggested:
>
>* Recreate the project and recompile (same result)
>* Move the project to a folder off the root (ie. c:\test to avoid path issues) (same result)

Hi Rick

Maybe this will help from Christof:
http://www.foxpert.com/knowlbits_200805.htm

"Function argument value, type, or count is invalid.
Another problem that is hard to locate. You build a COM project, either an EXE or any of the DLL types. After creating the EXE or DLL file, Visual FoxPro suddenly displays the error message "Function argument value, type, or count is invalid" and stops building the project. There is a DLL or EXE in the directory, but it doesn't contain any COM registration information. The TLB and VBR files are also missing.

If this happens to you, check the names of all methods and properties in the COM server that are neither protected nor hidden. Visual FoxPro doesn't properly generate the type library when names contain umlauts or other non-English characters. If you have a method like "GetDoppelgänger", this method would cause the error."

Also check for hidden Characters in the Method names and code - Recently I kept getting an error on a line that looked fine in the VFP IDE
Finally after pasting it into the WATCH window I found that what looked like a SPACE was actually CHR(8) - BACKSPACE. Don't know how it came there but once removed, the error went away.

Also check if HIS version of VFP is the same as yours - VFP9.EXE - IDE not the runtime.

HTH

Bernard
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform