Microsoft KB Archive/189927

= PRB: MsGraph 8.0 Causes Fatal Exception Error =

Article ID: 189927

Article Last Modified on 12/11/1999

-

APPLIES TO


 * Microsoft Visual FoxPro 5.0 Standard Edition
 * Microsoft Visual FoxPro 5.0a
 * Microsoft Visual FoxPro 6.0 Professional Edition

-



This article was previously published under Q189927



SYMPTOMS
If you define an MsGraph 8.0 object with the Top, Left, Width, Height, Autosize, and Stretch properties in the class in Visual FoxPro 5.x, an exception error might occur when the class is instantiated.



RESOLUTION
Do not include the Top, Left, Width, and Height properties in conjunction with Autosize and Stretch properties in the class.

Use the following sample code to work around for this problem: PUBLIC x  x=CREATEOBJECT('MyForm') x.ole1.AutoSize=.F.  x.ole1.Stretch=0 x.ole1.DoVerb x.Show

DEFINE CLASS MyForm AS Form WindowType=1 ADD OBJECT ole1 AS OleControl WITH ; OleClass='MSGraph.chart.8',; Top=10, Left=10, Width=100, Height=100 ENDDEFINE



STATUS
Microsoft is researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.



Steps to Reproduce Behavior
 Create a .prg (program) file.  Copy the following code into the program file: PUBLIC x     x=CREATEOBJECT('MyForm') x.Show

DEFINE CLASS MyForm AS Form WindowType=1 ADD OBJECT ole1 AS OleControl WITH  ; OleClass='MSGraph.chart.8',; Top=10, Left=10, Width=100, Height=100,; AutoSize=.f.,Stretch=0 ENDDEFINE  Save the program and run it.

RESULT: An exception error occurs, and Visual FoxPro shuts down.

Additional query words: kbOOP kbinterop kbVFp500a kbVFp500 kbVFp600

Keywords: kbprb kbpending KB189927

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.