I have used this w/o any problem so far in Vfp6. Don't remember where I got it from. Matt must be around. DDE is used here also.
*-----[ This goes at the start of the main program in your app. PARAMETERS _APPNAME =ddesetoption("SAFETY",.F.) ch = ddeinitiate(_APPNAME,"SYSTEM") IF CH != -1 =DDETERMINATE(CH) QUIT ENDIF DO DDE_SETUP PROCEDURE DDE_SETUP =DDESETSERVICE(_APPNAME,"DEFINE") =DDESETTOPIC(_APPNAME,"SYSTEM","DETECTED") RETURN *---[ This bit can go in your procedure file if you have one. FUNCTION DETECTED PARAMETERS A,B,C,D,E,F * ZOOM WINDOW SCREEN MAX RETURN .T. **------[End of Matt's Code Regards Ajoy Khaund Neamati Road Near Bhogdoi Bridge Jorhat 785001-21 Assam, India Tel: 91-376-2351288 Cell: 91-94350-92287 Mail: akha...@hotmail.com Mail: akha...@gmail.com "Walking on water and developing software from a specification are easy if both are frozen." - Edward V. Berard, "Life-Cycle Approaches" -------------------------------------------------- From: "Eurico Chagas Filho" <echagas...@terra.com.br> Sent: Tuesday, July 14, 2009 4:41 PM To: <profoxt...@leafe.com> Subject: How to avoid two instances > > I came across a code written by Ramani to avoid two instances of an > application in the same desktop. > It uses extensively the DDE functions, is there anything I should be aware > of ? > > TIA, E. > > > [excessive quoting removed by server] _______________________________________________ Post Messages to: ProFox@leafe.com Subscription Maintenance: http://leafe.com/mailman/listinfo/profox OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech Searchable Archive: http://leafe.com/archives/search/profox This message: http://leafe.com/archives/byMID/profox/60f4d703f573410fbe1776dcd8e5a...@compaq ** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.