Activate Dialog Box From Quicksilver

I am trying to activate a dialog box by running it through a trigger with Quicksilver. My problem is that I would like the dialog to come to the front and activate so I don’t have to click on it. I thought that maybe activating Firefox after was the problem but even using the “run” command instead of “activate” doesn’t solve the problem.

In short I just need to have the dialog box activate no matter what application I am in if possible.

set search to text returned of (display dialog "Enter YouTube Video Search" default answer "" buttons {"Cancel", "Search"} default button "Search") activate

tell application "Firefox"
	activate
	open location "http://www.youtube.com/results?search_query=" & search
end tell

--Use this script with this plug-in installed for firefox so you don't see featured video which often shows junk http://userstyles.org/styles/20570 


I don’t know for QuickSilver, but for Butler, I had the same problem. By letting the application activate itself first, I solved my problem:

tell me to activate
display dialog "Hello World"


Hope it works,
ief2

Thanks a lot, it works perfect!:smiley:

tell me to activate

set search to text returned of (display dialog "Enter YouTube Video Search" default answer "" buttons {"Cancel", "Search"} default button "Search")

tell application "Firefox"
	activate
	open location "http://www.youtube.com/results?search_query=" & search
end tell

--Use this script with this plug-in installed for firefox so you don't see featured video which often shows junk http://userstyles.org/styles/20570