Hi Mark, I have a hunch you're complicating the issue. For one thing, despite your explanations, I still don't understand what you're trying to do. To me this indicates that you don't understand the problem yet; which is, more than likely, the reason you have not solved it. 1. You're creating a window of some sort. 2. You define a rectangle in that window's coordinates. 3. You call a toolbox routine to paint that rectangle in that window. 4. Here's where I'm lost. Does the Desktop "port" become the current "port" because of something the user does, or are you just wanting to use the Desktop for some "ulterior motive" of your own? 8-} 5. Are you actually wanting to paint this same rectangle on the Desktop? OR is the "Desktop" just another window that you've created? I don't think so. Maybe someone else understands what you're doing, but I don't. Please explain at greater length and more specificity and why you're even getting GlobalToLocal etc. involved in the first place. You must be anticipating that someone is going to do something out of the ordinary??? Joe Wilkins Mark Goodes wrote: > I'd like to accomplish a simple task: > > 1. Set and paint rectangle in the current port. > 2. Change the port to the desktop port (cwmgrport) > 3. Paint the rectangle in exactly the same place that it originally > was. > > To do this, I tried using the following intermediate steps: > 1. Set and paint rectangle in the current port. > 1a. Call LOCALTOGLOBAL on the rectangle's coordinates. > 2. Change the port to the desktop port (cwmgrport) > 2b. Call GLOBALTOLOCAL on the rectangle's coordinates. > 3. Paint the rectangle in exactly the same place that it originally > was. > > But the rectangle just won't go where I want it to go. Anyone know how > to do this properly? > > Mark