What happens when you step through it? Try commenting out the refresh and see if it works.
John -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of John Weller Sent: Wednesday, February 27, 2008 12:17 AM To: profox@leafe.com Subject: Command Button Behaviour I have a screen where I want to control the position and visibility of a set of buttons depending on a global variable. The visibility part is working fine but the positioning commands seem to be ignored. The form is the opening screen for the app and is a top-level MDI form. The code I am using is below: WITH ThisForm .SetAll('Left',693,'_cmdbutton') IF goStock.Master = .T. *&* Setup buttons .cmdTransfer.Visible = .T. .cmdTransfer.Top = 97 .cmdUpdate.Visible = .T. .cmdUpdate.Top = 148 .cmdStockList.Visible = .T. .cmdStockList.Top = 250 .cmdStockCheck.Visible = .T. .cmdStockCheck.Top = 352 .cmdImportData.Visible = .F. ELSE .cmdTransfer.Visible = .F. .cmdUpdate.Visible = .F. .cmdGoodsOut.Visible = .F. .cmdStockList.Visible = .T. .cmdStockList.Top = 208 .cmdStockCheck.Visible = .T. .cmdStockCheck.Top = 276 .cmdImportData.Visible = .T. .cmdImportData.Top = 140 ENDIF .Refresh ENDWITH Any comments gratefully received. John Weller 01380 723235 07976 393631 [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/[EMAIL PROTECTED]@shelbynet.com ** 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.