Microsoft KB Archive/107745

= Client Not Updated with Multiple Instances of Excel =

Article ID: 107745

Article Last Modified on 6/23/2005

-

APPLIES TO


 * Microsoft Excel 97 Standard Edition
 * Microsoft Query 2000

-



This article was previously published under Q107745



SUMMARY
When multiple instances of Microsoft Excel are simultaneously serving as dynamic data exchange (DDE) clients to a single DDE server, only one instance of Microsoft Excel will be updated.



MORE INFORMATION
This is a problem with the current implementation of the DDE management library (DDEML). The problem will only occur when all of the following conditions are met:
 * There are two or more instances of the same application serving as DDE clients.
 * The applications all have objects with the same name (such as "Sheet1")
 * The applications are all trying to use FETCH.ADVISE

Steps to Reproduce Problem
Microsoft provides programming examples for illustration only, without warranty either expressed or implied. This includes, but is not limited to, the implied warranties of merchantability or fitness for a particular purpose. This article assumes that you are familiar with the programming language that is being demonstrated and with the tools that are used to create and to debug procedures. Microsoft support engineers can help explain the functionality of a particular procedure, but they will not modify these examples to provide added functionality or construct procedures to meet your specific requirements.  Start Microsoft Query.  Open two instances of Microsoft Excel and run the following Visual Basic macro from each instance: Sub dde

chanNum = DDEInitiate("msquery", "system") ' Use the path for your query file for the following: ' Note: query files in Excel 97 contains a dqy extension. DDEExecute chanNum, "[open('c:\excel\query1.qry')]" nRows = DDERequest(chanNum, "NumRows") nCols = DDERequest(chanNum, "NumCols") DDEExecute chanNum, "[fetch.advise('Excel','sheet1','r1c1:r" & _     nRows(LBound(nRows)) & "c" & nCols(LBound(nCols)) & "','all')]"

End Sub NOTE: You will need to create a query file to run this macro if you don't already have one. Use the path for this file in line 2 of the macro.)  Check Sheet1 on both instances of Excel; they should display a copy of the query. Switch to Query Tool and from the Records menu, choose Allow Editing. Change some of the records in the query.

Check Sheet1 on both instances of Microsoft Excel; the records should have been updated on one but not the other.

Additional query words: 8.00 97 XL

Keywords: kbprogramming KB107745

-

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

© Microsoft Corporation. All rights reserved.