February 18th, 2004, 08:52 AM
Float Inexact Result
I am getting the following error First-chance exception in UCSSocketServer.exe (KERNEL32.DLL): 0xC000008F: Float Inexact Result. My VC++ program invokes a method of a VB ocx which in turn calls the VB dll. The error occurs during the invocation of the dll method. I have a VB client which works without any problem. But when I try to call it through my VC++ code it throws this exception. Can anybody give a solution to this. Thanks in advance.
February 18th, 2004, 11:56 AM
February 18th, 2004, 12:01 PM
I don't think you'll get any quick solutions without posting some relevant code. With the information you've given so far, we can only guess what might be wrong.
Originally posted by johnsam2000
February 18th, 2004, 12:06 PM
You can't get solutions if you don't post anything related to the problem. What are the parameters to the function you are trying to call?
Also, I did a google search in the newsgroups for "Float Inexact Results"
At least 10 pages of hits.
February 18th, 2004, 12:12 PM
The VC++ code which instantiates the ***_Host.ocx and calls its Receive() method
HRESULT hrOCXCreate = CoCreateInstance (***_Host::CLSID_***_Data,NULL,CLSCTX_ALL, ***_Host::IID__***_Data,(void**)&pobjASSData);
The ***_Host.ocx code where it invokes the dll method
Public Function Receive() As Integer
Dim oBearbeitenData As Object
On Error GoTo ErrorReceive
Set oBearbeitenData = AssAccess1.GetAss
In debug mode I get the following error at this point
First-chance exception in UCSSocketServer.exe (KERNEL32.DLL): 0xC000008F: Float Inexact Result.
February 18th, 2004, 12:32 PM
Looks like your A S S - Host has been censored by the forum software...
Originally posted by johnsam2000
The VC++ code which instantiates the ***_Host.ocx and calls its
February 18th, 2004, 08:35 PM
I may be wrong, but I think that it's the VB runtime dll that generates these errors if you run it inside of VCs debugger. In any case, anytime I debug a C++ COM object with a program written in VB, I get loads of these. Maybe it's when in VB you use implicit conversions, variant datatypes or generic functions taking variants as input.
In any case, if it comes from the VB ocx, I wouldn't worry about it.
Thinking about the whole thing, it's probably normal behaviour by VB. The thing is that a certain function generates this exception and usually the VB runtime (or the compiled code) would catch it directly and handle it accordingly. But since you attached a debugger, that sees the exception before VB can handle it. Hence it's name "First chance exception". If the VB runtime (or the compiled VB code) would not handle the exception, the debugger would catch a "Second chance exception" while the VB program would crash.
So, in short, don't worry about that.]
Last edited by Yves M; February 18th, 2004 at 08:42 PM.
Get this small utility
to do basic syntax highlighting in vBulletin forums (like Codeguru) easily.
Supports C++ and VB out of the box, but can be configured for other languages.
July 23rd, 2009, 11:41 PM
Re: Float Inexact Result
"(KERNEL32.DLL): 0xC000008F: Float Inexact Result" errors occurs on calling an OCX control method with incorrect parameter type.
virtual HRESULT __stdcall put_xxx (
VARIANT_BOOL _arg1 ) = 0;
INCORRECT Function Call
VARIANT_BOOL bValue = 0;
pMyOCX->get_Something( bValue ); // The above execption will happen
CORRECT Function Call
VARIANT_BOOL bValue = FALSE;
pMyOCX->get_Something( bValue );
Click Here to Expand Forum to Full Width
This a Codeguru.com survey!