AutoHotkey Community

It is currently May 25th, 2012, 2:30 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 3 posts ] 
Author Message
PostPosted: April 24th, 2007, 9:15 pm 
Offline

Joined: April 17th, 2007, 1:37 pm
Posts: 761
Location: Florida
OK, I've got a script created to update addresses in Oracle from a list on an Excel spreadsheet. The problem is that Oracle won't let me plug in city, state, and zip before trying to validate one of those values. What happens is if you put one value in and tab off of it, it will bring up a modal window where you select the correct zip/city etc.

SO... What I've done is created a MsgBox that pops up to ask the user to select the correct city and state after pasting in the zip code and tabbing off. I've set it to always on top so the user doesn't have to alt-tab back to it in order to resume the script. The problem is that it pops up directly over the window where you choose the address... Is there a way to make the MsgBox pop 200 or 300 pixels higher or lower?

Code:
Send, %Zip%{TAB}
MsgBox, 4097, Commit Record?, Press OK when you are ready to commit record.`nYou have to select %City%`, %State% from an Oracle window BEFORE PRESSING OK.
IfMsgBox Cancel
{
Blah Blah Bail out of update and send ERROR to spreadsheet
}
Else
{
Blah Blah commit record and send OK to spreadsheet
}

_________________
[Join IRC!]
Image


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: April 24th, 2007, 9:26 pm 
Offline
User avatar

Joined: August 30th, 2005, 8:43 pm
Posts: 8647
Location: Salem, MA
can you detect the oracle window and set %city% and %state% yourself?

The script can also start a timer that moves the msgbox somewhere else, but that's a hack.

_________________
Image
(Common Answers) - New Tutorials Forum - Humongous FAQ


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: April 24th, 2007, 9:45 pm 
Offline

Joined: November 17th, 2005, 10:14 pm
Posts: 196
Location: Leicester, UK
You can use a timer to watch out for the msgbox then move it.
Have a playabout with this:
Code:
#Persistent
SetTimer PlaceMsgBox, 100

Sleep 1000
MsgBox,, Move Me!, I've been moved!

PlaceMsgBox:
SetTimer PlaceMsgBox, Off
IfWinExist Move Me!
{
   WinMove Move Me!,,0,400
   }
SetTimer PlaceMsgBox, On
Return


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: Bing [Bot], lblb, mrhobbeys, Yahoo [Bot] and 14 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group