The information in this article applies to:
- Microsoft FoxPro for Windows, versions 2.5, 2.5a, 2.5b
SYMPTOMS
When you use the UPDATEGRPH function to programmatically update a graph in
a database created by Microsoft Graph through GENGRAPH.APP, the y-axis
number format (for example, #,##0) that is saved with the graph's datasheet
is lost after the graph is updated with the new data. The #,##0 format on
the y-axis is replaced with the general format based on the new data.
STATUS
Microsoft is researching this problem and will post new information here in
the Microsoft Knowledge Base as it becomes available.
MORE INFORMATION
Steps to Reproduce Behavior
- In the Command window, issue the following command:
CREATE QUERY
- Select the CUSTOMER.DBF file from the FOXPROW\TUTORIAL subdirectory.
- Select the Fields check box.
- In the RQBE Select Fields dialog box, choose the Remove All button.
- In the Table Fields list box, select the YTDPURCH field and then
choose the Move button. Repeat this step again, but this time select
the CONTACT field. Select the No Duplicates check box and then choose
the OK button.
- Under Field Name, select the STATE field, select the logical operator
LIKE, and in the Example text box, type the state LA.
- In the Output list box, select Graph.
- Choose the Do Query button.
- Select the Column chart type and then choose the Next button.
- If you want, change the default title and then choose the Next
button.
- Choose the Zoom button.
- Double-click the graph to open Microsoft Graph.
- Click the datasheet and select the entire YTDPURCH column.
- From the Format menu, choose Number, select the #,##0 format, and then
choose the OK button. Check that the values on the Y-axis in the chart
display in the newly selected format (that is, 12,0000, 10,000, and so
on).
- From the File menu, choose Update, and then choose Exit And Return To
FoxPro [###].
- Click the close box in the Zoom window.
- In the Microsoft FoxPro GraphWizard dialog box, choose the Save As
button.
- Using the default filename (QRYGRAPH.DBF), save the graph in the
FOXPROW directory and then choose the Save button. A WAIT window will
appear with the drive and directory where the QRYGRAPH.DBF file is
saved.
- Choose the OK button in the Microsoft FoxPro GraphWizard dialog box and
then press ESC to close the RQBE dialog box. You don't have to save the
UNTITLED.QPR file.
- From the Window menu, choose View.
- In the View window, select a work area and open the QRYGRAPH.DBF file
and then BROWSE the database. Double-click the field called GEN and
verify that the chart's Y-axis is correctly formatted. Press ESC twice
to exit the general field and the Browse window. Close the
QRYGRAPH.DBF.
- In the Command window or in a program, issue the following code:
CLEAR ALL
SELECT ytdpurch,contact FROM \Foxprow\Tutorial\CUSTOMER WHERE ;
STATE="MA" INTO CURSOR query && semicolon not required at
&& the Command window
DO UPDATEGRPH IN GENGRAPH.APP WITH ;
"\FoxProw\qrygraph.dbf", 1, 1, "My Title"
USE \Foxprow\qrygraph IN 0
SELECT qrygraph
BROWSE
- In the Browse window, double-click the field called GEN; the values on
the updated chart's y-axis will show a different number format. The
#,##0 number format that was originally saved with the graph's
datasheet will be replaced by the general format based on the new data.
|