Stuart McLachlan
stuart at lexacorp.com.pg
Wed May 28 02:22:53 CDT 2003
On 27 May 2003 at 16:35, Kathryn Bassett wrote: > There is an event procudure that opens the "look in" browser. What > would I add to the below (and where) to get the blasted thing to open > in the center of my screen instead of the upper left of the screen. I > need to see upper left portion of the underlying form, to remind me of > the name of the person I'm looking for in the "look in", and the way > it is now, I have to drag it out of the way. > > Thanks, > As Michael said, you can use another form to control the position, but note that the form must be "Popup", otherwise the dialog will still use the main Access Window for it's location. Here's what to do with your current code. Create a new unbound form "frmPosition" set it just a few pixels high and wide. Set it with no scroll bars, record selectors or navigation buttons. Set Autocenter to No Set its Popup state to Yes Position it somewhere well down on your screen and save it ( move it around and re-Save it as necesary after testing the changes below to get it where you want it) Change your code as follows: 1. Insert this line straight after the DIM lines: DoCmd.OpenForm "frmPosition", , , , , acHidden 2. Change this OpenFile.hwndOwner = Me.hWnd to this OpenFile.hwndOwner = Forms!frmPosition.Hwnd 3. Insert this straight after the call to GetOpenFileName() DoCmd.Close , "frmPosition" -- Lexacorp Ltd http://www.lexacorp.com.pg Information Technology Consultancy, Software Development,System Support.