Announcement

Collapse
No announcement yet.

2 more: Killing external apps and creating projects on a specific location

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • 2 more: Killing external apps and creating projects on a specific location

    I have 2 questions.

    1: How do I kill an external application? Let's say I have calc.exe running but it is not selected and I want to kill it. How do I do that? I assume you have to select (make it active and then send the kill signal).

    2. How do I make a AMS exe open up only at a specific point. E.g. I have a 800x400 AMS app. I want it to only open at 0x200 from top left of the screen. Can that be done?

    Lwin

  • #2
    Re: 2 more: Killing external apps and creating projects on a specific location

    Hi:

    1. Combine WINDOW > FIND action(s) with WINDOW > CLOSE action(s).

    2. Use a WINDOW > MOVE action OnShow.



    Corey Milner
    Creative Director, Indigo Rose Software

    Comment


    • #3
      Re: 2 more: Killing external apps and creating projects on a specific location

      Thanks. Just what I was looking for.

      Comment


      • #4
        Re: 2 more: Killing external apps and creating projects on a specific location



        Corey Milner
        Creative Director, Indigo Rose Software

        Comment


        • #5
          Re: 2 more: Killing external apps and creating projects on a specific location

          Corey,

          Am I doing something wrong here? This is what I did.
          %MusicPlayerWindow%=Window.Find("MusicPlayer")
          IF (%MusicPlayerWindow%<>"")
          File.Open(open,MusicPlayer.exe")
          ELSE
          Window.Restore(%MusicPlayerWindow%)
          END IF


          It is pretty much supposed to look for music player. If it is not there, it will load music player using open file command and if it is there, it will restore it.

          For some unknown reasons, it keeps loading a new music player even when one is there.

          Kind of puzzling me.

          Comment


          • #6
            Re: 2 more: Killing external apps and creating projects on a specific location

            I'll see if I can write the ID into a ini file and see if that solve this issue.

            Comment


            • #7
              Re: 2 more: Killing external apps and creating projects on a specific location

              %MusicPlayerWindow%=Window.Find("MusicPlayer")
              IF (%MusicPlayerWindow%<>"")
              File.Open(open,MusicPlayer.exe")
              ELSE
              Window.Restore(%MusicPlayerWindow%)
              END IF

              Looks like you have the logic backwards. It should either be:

              <font class="small">Code:</font><hr /><pre>%MusicPlayerWindow% = ""
              %MusicPlayerWindow%=Window.Find("MusicPlayer")
              IF (%MusicPlayerWindow%=="")
              File.Open(open,MusicPlayer.exe")
              ELSE
              Window.Restore(%MusicPlayerWindow%)
              END IF
              </pre><hr />

              or

              <font class="small">Code:</font><hr /><pre>%MusicPlayerWindow% = ""
              %MusicPlayerWindow%=Window.Find("MusicPlayer")
              IF (%MusicPlayerWindow%<>"")
              Window.Restore(%MusicPlayerWindow%)
              ELSE
              File.Open(open,MusicPlayer.exe")
              END IF
              </pre><hr />

              Note that you need to initialize %MusicPlayerWindow% to "" if you want to use a comparison to "" to determine whether Window.Find set the variable to anything.
              --[[ Indigo Rose Software Developer ]]

              Comment

              Working...
              X