Trying to launch modal window in safari with Applescript

Hello,
I am writing a web-based app that needs to launch a modal browser window from an applescript file. No addressbar, no toolbar, etc. (the pc side uses a .vbs file to do the same thing.) It's like a popup, but this is from my app. Im not launching it from another web page.
I can do it with applescript and "System Events" :
tell application "Safari"
activate
make new document with properties {URL:"http://IPADDRESS/default.aspx"}
do JavaScript ("self.resizeTo(500,480);") in document 1
tell application "System Events"
keystroke "B" using {command down, shift down}
keystroke "/" using command down
keystroke "|" using command down
end tell
end tell
But this affects the entire Safari application so new windows opened by the user appear the same way. I need it to only affect the window that is opened. I tried some JS "toolbar=no" type commands but it did not have any effect. I must admit my JS and AS is very basic at this point so it could have been poor syntax..
Can any of you fine folks suggest a way to do this?

It's not what you want to hear, I'm afraid, but as far as I know there's no way to directly access placeholders other than the title and body in Keynote.
I did see mention of parsing XML to change values of individual items, but it might be overkill for what you want to achieve.
Perhaps if you explain what you are trying to do someone will come up with a helpful suggestion.

Similar Messages

  • I'm trying to open a PDF from Safari with iBooks, but when I choose "Open with ..." in Safari, only Pages and Dropbox show as options.  I'm running iOS 7.1.2 and iBooks 3.2.  Thanks for any ideas!

    On my iPad, I'm trying to open a PDF from Safari with iBooks, but when I choose "Open with ..." in Safari, only Pages and Dropbox show as options.  I'm running iOS 7.1.2 and iBooks 3.2.  I have rebooted the iPad and that did not help, and reinstalled iBooks, which also changed nothing.  Thanks for any ideas!

    Yup, it was uploaded to our school Wiki as a PDF, and Pages did open it.  I was then able to move it to iBooks, but I'd rather avoid the extra steps.

  • How i can synch my windows pc safari with my iphone safari?

    In the past I sync my windows pc safari with my phone  safari ( I am not sure how) and now I can see the bookmarks on my phone. I am looking to update my phone safari as i had add more bookmarks. How i can do that? i got iphone5s ios 8.1.1

    Hi ..
    The easiest way to sync your Safari bookmarks between your PC and iPhone is to use iCloud >  Apple - iCloud - Learn how to set up iCloud on all your devices.
    You get 5GB's of storage for free.

  • Trying to connect to Windows on LAN with MacBook outside of LAN

    Folks, I've scoured the support site thinking someone else has had this issue but no luck...I have a LAN powered by an Airport Extreme. I am trying to use my MacBook to access a Windows PC back in my LAN.
    Within the Airport Utility, under the advanced settings -> Port Mapping -> selected "Remote Login - SSH" as the service and put the IP address of the Windows machine within the Private IP Address field.
    Using Microsoft RDC for Mac on my MacBook, the computer name is the address of my ISP. For this RDC account, the login credentials are correct with the Domain field listing the same IP address as is in the Private Address field within Airport Utility.
    However, it will not connect. I am lost on this and would love any insight.
    Thanks!

    charlesdeanda wrote:
    changed the line in settings.
    in the right place:
    http://www.bulletsandbones.com/GB/GBFAQ.html#recordlinein
    (Let the page FULLY load. The link to your answer is at the top of your screen)
    I have read that some guitars will need some sort of amplification.
    http://www.bulletsandbones.com/GB/GBFAQ.html#pluginguitar
    (Let the page FULLY load. The link to your answer is at the top of your screen)
    Does this mean that these guitars have no sound/input at all
    no
    , or have some sound/input but very low.
    yes
    I just want to make sure its not me or the guitar thats the issue before i invest in some amplification
    a wise choice. so far my guess is it's a setting, you should hear something if everything is set correctly.
    will imic help? does it amplify?
    i would not recommend it, but it could work, yes.

  • How can I open one window in Safari with a tab?

    When I open Safari, the window opens up but not in a tab. I prefer the single window being in a tab.

    I'm guessing you're talking about new Safari windows are opening up in Windows rather than tabs..
    Go to Safari > Preferences > Tabs tab > set the option there.
    Regards,
    Captfred

  • How do I open a new window in Mail with AppleScript?

    I have an AppleScript that opens Mail, but if Mail is open in the background, but no window is open, then the "activate" command simply brings the application to the front, instead of creating a new window. Is there another command that will open a window if there is no existing window?

    You could also use any one of the following six “keystroke” commands:
    tell application "Mail"
        activate
        tell application "System Events"
            keystroke "0" using {command down} --> Message Viewer ⌘0
            keystroke "1" using {command down} --> Inbox ⌘1
            keystroke "2" using {command down} --> Drafts ⌘2
            keystroke "3" using {command down} --> Sent ⌘3
            keystroke "a" using {option down, command down} --> Address Panel ⌥⌘A
            keystroke "0" using {option down, command down} --> Activity ⌥⌘0
        end tell
    end tell

  • Retrieving all UI Elements from window with Applescript

    Hi All..
    I want to retrieve all the ui elements from one of the window in runtime with Applescript.
    The problem is in order to get the elements of the particular window i need to pass thru the hierarchy like UI element 1 of scroll area 1 of window 1 etc..
    How do i get the hierarchy at the runtime??
    For eg: if the hierarchy level is 3, i can get the UI elemets like.. ui elements of ui elements of ui elements of window 1.. this works fine
    but i want to repeat the same statement in loop, till i get some elements, how do i achieve the same??
    I tried the below code its not working for me... Pls suggest
    set allButtons to {}
    set i to 0
    tell application "System Events"
        tell process "Install Adobe Reader"
            set num to count of UI elements of window 2
            set element to every UI element of window 2
                  repeat with i from 0 to num
                if class of element is button then
                    return true
                else
                    set element to (a reference to UI elements of element)
                    set num to count of UI elements of element
                    end if
            end repeat
        end tell
    end tell

    madhusudhanjr wrote:
    actually am implementing Applescripts in Java, the output what we get in Java is not exactly similar to Applescript.. Is their any way to make a list or Array of the above codes output??
    Because they are objects.
    Here's how to convert these objects in  text format :
    set allButtons to ""
    tell application "System Events"
          tell process "Install Adobe Reader"
                with timeout of 0 seconds
                      set tElements to entire contents of window 1
                end timeout
                repeat with i in tElements
                      if class of i is button then try
                            i as text
                      on error err
                            tell my cleanUpErr(err) to if it is not "" then set allButtons to allButtons & it & linefeed
                      end try
                end repeat
          end tell
    end tell
    allButtons
    on cleanUpErr(t)
          set oTID to text item delimiters
          try
                set text item delimiters to "«" -- remove description of the error at beginning of the text
                set t to "«" & (text items 2 thru -1 of t) as text
                set text item delimiters to " of «class pcap»" -- remove 'of process "xxxx" of application "System Events"'
                set r to text item 1 of t
                set text item delimiters to oTID
                return r -- return object in text format
          end try
          set text item delimiters to oTID
          return ""
    end cleanUpErr
    You will get a button to each line (the last line will be empty).
    Here is an example of the result :
    «class butT» 1 of window "xyz"
    «class butT» "bla" of window "xyz"
    «class butT» 3 of window "xyz"
    «class butT» "OK" of «class scrb» 1 of «class scra» 1 of window "xyz"
    Each line is compilable in (osascript or in the Editor) without changing the text even if some of the classes are Raw Code --> «class butT»

  • Making and opening folder with applescript

    I'm trying to create and open a folder with applescript, but my script gives an error...
    This is what i've written but can't figure out what i'm doing wrong. I hope you can help me!
    tell application "Finder"
    activate
              set the_folder to "106_WDJZ Eigen Magazine 20pp_Foto"
              set myfolder to make new folder at "Press4:10. Specials:N19. WDJZ Eigen Magazine 20pp:F. Foto:" with properties {name:the_folder}
              set openmap to (myfolder & the_folder)
    end tell
    Thank you very much in advance

    Thank you both for your awnsers. I really appreciate it! I was trying to create a folder (at "Press4:10. Specials:N19. WDJZ Eigen Magazine 20pp:F. Foto:") with a name (106_WDJZ Eigen Magazine 20pp_Foto) and after the folder is created I want the scrpt to open the folder.
    The in FileMakerPro (calculated) applescript is now working and look like this:
    "tell application \"Finder\"" & ¶ &
    "set the_folder to \"" & Editie_standaardgegevens::UitgaveID & "_" & Editie_standaardgegevens::Editienaam_intern & "_Foto" & "\"" & ¶ &
    "set sub_folder to \"Press4:10. Specials:" & Editie_standaardgegevens::Editienaam_intern_totaal & ":F. Foto:\"" & ¶ &
    "set myfolder to make new folder at sub_folder with properties {name:the_folder}" & ¶ &
    "set openfolder to (sub_folder & the_folder & \":\")" & ¶ &
    "open folder openfolder" & ¶ &
    "activate" & ¶ &
    "end tell"

  • I like and use Top Sites but it has become unsuable with this constant blacking out and reloading the thumbnails.  My MBP has not seen a problem at all.   I have been searching every other day for over a month trying to find a fix in Windows Safari with n

    I like and use Top Sites but it has become unsuable with this constant blacking out and reloading the thumbnails.  My MBP has not seen a problem at all.
    I have been searching every other day for over a month trying to find a fix in Windows Safari with no joy.  I want to resolve, not switch browsers. Please offer up a solution that only refreshes the Top Site thumbnails once a day or as some controlable interval.  Started about two versions ago, now on ver 5.1.5. Windows 7 64bit.
    Safari 5.1.5 for Win64 bit, Windows 7!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

    I think I solved the wifi connection problem, just by switching off completely the router! sounds trivial, but in this case it worked!!!
    the funny behaviour of the trackpad/cursor still persists. any suggestion???
    thanks again

  • I downloaded an update for my Safari web browser to "snow leopard". When I click on the .dmg file, a window opens up with a .pkg file but when I click on the .pkg file I get a prompt saying that it doesn't know what program to open it with. with a

    I downloaded an update for my Safari web browser to "snow leopard". When I click on the .dmg file, a window opens up with a .pkg file but when I click on the .pkg file I get a prompt saying that it doesn't know what program to open it with.

    I suspect if you're trying to open a file in 08 that's been opened in 09 the file has been updated to 09 and will not open in 08.

  • How Do I Launch Safari with Multiple Tabs Open to Specific Pages?

    I'd like a Windows shortcut that opens Safari with multiple tabs open to specific pages. With other browsers (Firefox, IE, Chrome, etc.), this is easily done by composing a command line that lists all desired URLs. However, Safari doesn't seem to use the same command line syntax as other browsers. Furthermore, I can't find Safari's command line syntax documented anywhere. From the comments I've seen while researching this question, I suspect this is a neglected area of Safari development, and that Safari simply can't be configured to open multiple pages. However, I'd like to make sure. Can it?
    -TC

    It strikes me that it should be possible to do that (or something similar) by building a safari extension, TC. Both Sessions and SafariRestore are able to launch multiple tabs from a previous session, so it seems like you should be able to create an extension that launches multiple tabs open to specific sites when Safari is launched.

  • Error 0x80070490 trying to launch VM without SCVMM on Windows 2008 Server R2

    Hello everybody,
    I get a weird issue trying to launch a VM.
    This is the current situation : I get a server, Windows 2008 R2. I've only install Hyper-V and Failover Cluster. I can create a VM but when I try to launch it, I get an error message into a popup (translated from french) : "The application encountered
    an error during modification of 'vm_name' state". "'vm_name' could not be initialize". "Could not initialize machine remoting system. Error 'Element not found'. (0x80070490). "Could not find a usable certificate. Error: 'Element not found'. (0x80070490)."
    So, I'm unable to launch my vm's.
    I'm not using SCVMM yet. I want to resolve this issue before.
    I read some articles and posts about SCVMM certificate issue but I'm not using SCVMM.
    More fun, I read articles about this issue but on Windows 2008 Server (not R2) : problem resolved by a fix, unapplicable on my Windows 2008 R2 :)
    I'm totalyblocked and ain't got no idea how I can resolve it.
    If someone gets I idea ...
    Cheers,
    Nicolas

    Environment: Windows 8.1 in an Active Directory Domain (2012R2) with MS Certficates Services support NAP/Health Registry, etc. 
    Error:  Attempts to start a Hyper-V VM on a machine generates the error message Error 0x80070490 trying to launch VM:
    "'vm_name' could not be initialize". "Could not initialize machine remoting system. Error 'Element not found'. (0x80070490). "Could not find a usable certificate. Error: 'Element not found'. (0x80070490)."
    Note: 
    VMM can manage other Hyper-V servers in environment from same machine, just not local machine.
    VMM on remote machine generates same error message when attempting to manage new VM machine
    Certificates - Service (Hyper-V Virtual Machine Management) on Local Computer shows 0 certificates under vmms\Personal
    Fixes Attempted and Failed except for #5!
    1) hotfix directly: Windows6.0-KB967902-x64.msu -> Failed: 0x80096002, Windows Update Standalone Installer.  The certificate for the signer of the message is invalid or not found.
    2) hotfix via pkgmgr: PkgMgr.exe has been deprecated. Please update scripts to use DISM.exe.  0x80070307
    3) Reset Certificates: 
     Start > Run > MMC
     Add the Certificates Snap-In
     Select Service Account
     Under the Select Account to Manager, select Hyper-V  Image Management Service
     Complete the Snap-In Wizard
     Expand the Certificates under Personal Category
     Notice the certificate generated has been created ‘for the future’ (assuming you’re suppose to revert the date & time to 2010, the certificate should display as invalid because it was created at 2013)
     Delete the Certificate(s)
     Go to the Services Console and Restart all Hyper-V Services
     Result: No certificate auto generated
    4) Uninstall / reinstall hyper-v service and management service addons from Windows features.  
    5) ‎did the following from http://technet.microsoft.com/en-us/library/ff935311(v=ws.10).aspx (WORKED!!! -> Note, their PS script has an error, add a dash(-) before the word recurse)
    reg add "HKLM\Software\Microsoft\Windows NT\CurrentVersion\Virtualization" /v "DisableSelfSignedCertificateGeneration" /f /t REG_QWORD /d 1
    24 ca 36 b5 bd 6d ef 7e eb aa a5 74 df e5 fd 41 ef ab 1c 29
    $certs = dir cert:\ -recurse | ? { $_.Thumbprint -eq "24ca36b5bd6def7eebaaa574dfe5fd41efab1c29" }
    $cert = @($certs)[0]
    $location = $cert.PrivateKey.CspKeyContainerInfo.UniqueKeyContainerName
    $folderlocation = gc env:ALLUSERSPROFILE
    $folderlocation = $folderlocation + "\Microsoft\Crypto\RSA\MachineKeys\"
    $filelocation = $folderlocation + $location
    icacls $filelocation /grant "*S-1-5-83-0:(R)"

  • I updated iTunes today (Windows).  When I tried to launch, I get the message, ""The procedure entry point AVCFURLAssetInheritURIQueryComponentFromReferencingURIKey could not be located in the dynamic link library AVFoundationCF.dll".

    I updated iTunes today (Windows).  I restarted the computer but when I tried to launch, I get the message, ""The procedure entry point AVCFURLAssetInheritURIQueryComponentFromReferencingURIKey could not be located in the dynamic link library AVFoundationCF.dll".
    I then did a new install of the latest iTunes version and got the same problem.   No more iTunes.
    HELP!!!

    For general advice see Troubleshooting issues with iTunes for Windows updates.
    The steps in the second box are a guide to removing everything related to iTunes and then rebuilding it which is often a good starting point unless the symptoms indicate a more specific approach. Review the other boxes and the list of support documents further down page in case one of them applies.
    Your library should be unaffected by these steps but there is backup and recovery advice elsewhere in the user tip.
    tt2

  • Get message firefox already running but not responding when trying to launch..tells me to close firefox wondow and try again (no ffox window is open)

    When trying to launch Firefox I get the following message.
    "Firefox is already running, but is not responding. To open a new window, you must first close the existing Firefox process, or restart your system."
    This is not the first time and I am tired of having to restart my computer. BTW I have Firefox as my default browser, but had to use IE to get to this support site!
    In answer to the next question...every time I TRY to open Firefox.

    Simple fix for you I think--it works for me.
    1. Open your TASK MANAGER (rt click on your taskbar)
    2. Go to PROCESSES
    3. Scroll down until you see "firefox.exe"(or anything with the word Firefox in it)
    4. Click(highlight) the "firefox.exe"
    5. At the bottom right side,click "End Process"
    6. Close the Task Manager and do whatever you were attempting to do.
    Cheers
    Bilk 24

  • OS X with Safari with Windows MediaPlayer

    We are Canadians, presently living in the United Arab Emirates, and we would like to listen live to CBC Radio (Canadian national radio) at www.cbc.ca. We are using OS X version 10.4.3 with Safari. CBC uses Windows Media Player to broadcast live on the net. When we click on the Media Player at the CBC site the following prompt comes up:
    The page “CBC Radio One Vancouver (32 kbps)” has content of MIME type “application/x-mplayer2”, but you don’t have a plug-in installed for this MIME type. A plug-in should be available on this page:
    http://www.microsoft.com/Windows/MediaPlayer/
    Do you want to open the page?
    We did download the appropriate version of MediaPayer for the OS X but another prompt states that a plug-in is still missing. Repeated attempts to get the plug-in have failed.
    Any suggestions???
    Thanks
    PowerBookG4   Mac OS X (10.4.3)  
    PowerBookG4   Mac OS X (10.4.3)  

    Use the direct URLs in Windows Media Player instead of trying to listen to it through Safari.
    http://www.cbc.ca/listen/streams.html
    The one for Vancouver is
    http://origin.www.cbc.ca/mrl2/livemedia/cbcr1-vancouver.asx
    Windows Media Player
    File > Open URL...
    Paste the above link into the field.

Maybe you are looking for

  • Multiple calendars on one machine

    I would like to have a machine near our phone that has each family member's ical calendar information displayed on one calendar. Is it possible to sync a computer to multiple ical accounts and have all those accounts displayed on one calendar ... aut

  • Problem with the JNDI properties while executing a client test

    Hello Everybody, I'm trying to learn Jdeveloper, and I have followed the tutoriel " Learn Oracle Fronn Oracle" Volum 2, so i am trying to create a simple oriented bean message with EJB 3.0, and a client test to deliver a message, and the problem is t

  • Wifi printer is no longer being found by my mac

    I have a 2 office business...  Both offices are sharing an epson wifi printer.   Both computers where printing fine over the wifi, and then this week neither mac can discover the printer.   Ive checked the printer and it is connected correctly to the

  • Officejet L7680 Problems with printing in Vista

    My printer has totally stopped printing.  I have unplugged, tried a test page, checked for jams etc.  It will not print. I did change the ink cartridge for black as it was very low, but that did not do it either.  We have the hp officejet pro L7680 a

  • HP Mini 210-2090NR malware and fatal error after update

    Hi,  I have an HP Mini 210-2090NR with Win 7 starter. I had malware that kept trying to contact websites like adclick, etc. It tried an auto update and then got a one line "fatal error". Now it will boot to the quickweb but not the OS. I tapped ESC u