Loading ...
Sorry, an error occurred while loading the content.

Re: IsWindowEnabled

Expand Messages
  • byronkat
    Thanks, this is a big help!
    Message 1 of 7 , Mar 7 7:54 AM
    • 0 Attachment
      Thanks, this is a big help!

      --- In perlguitest@yahoogroups.com, "Dennis K. Paulsen
      <ctrondlpaulsden@y...>" <ctrondlpaulsden@y...> wrote:
      > The following example checks the enabled state of Calculator's
      > Backspace button, try something similar for your purposes:
      >
      > # Tested under Win32::GuiTest (v 1.49.2)
      > use Win32::GuiTest qw/
      > FindWindowLike
      > WaitWindowLike
      > IsWindowEnabled
      > /;
      >
      > # Start and then wait for calculator window to appear
      > system("start calc.exe");
      > WaitWindowLike(0, "Calculator", "");
      >
      > # Find Calculator window
      > my ($CalcWin) = FindWindowLike(0, "Calculator", "");
      >
      > # Find Backspace button(window) belonging to Calculator window
      > ($CalcWin)
      > my ($BackSpace) = FindWindowLike($CalcWin, "Backspace", "");
      >
      > # See if Backspace button is enabled; which it should be
      > if (IsWindowEnabled($BackSpace)) {
      > print "BackSpace is enabled.\n";
      > } else {
      > # Backspace should be enabled. If not, die here.
      > die "BackSpace is not enabled!";
      > }
      >
      >
      > Regards,
      > Dennis K. Paulsen
      >
      > --- In perlguitest@yahoogroups.com, "byronkat <byronkat@y...>"
      > <byronkat@y...> wrote:
      > > I'm trying to check to see if a button is enabled or disabled.
      > I've
      > > seen that the IsWindowEnabled method can be used. Does anyone
      > know
      > > how to use this method? Thanks!
    • fareh_rafik
      I have a prblem with the use of IsWindowEnabled, It do nt return false when a button is disabled. Can you help me?
      Message 2 of 7 , Oct 10, 2005
      • 0 Attachment
        I have a prblem with the use of IsWindowEnabled,
        It do'nt return false when a button is disabled.
        Can you help me?
      • amine beghdous
        Hi All, I m new to perl and Guitest and I m trying to execute the following perl script: #!/usr/bin/perl ## Initially generated by Win32-GuiTest Recorder
        Message 3 of 7 , Oct 10, 2005
        • 0 Attachment
          Hi All,



          I'm new to perl and Guitest and I'm trying to execute the following perl script:



          #!/usr/bin/perl
          ## Initially generated by Win32-GuiTest Recorder (v1.03)

          ## Pragmas/Directives
          use strict;
          use warnings;




          ## Imports
          use Win32::GuiTest qw/:ALL/;

          $Win32::GuiTest::debug = 0; # Set to "1" to enable debug output.

          ## Main/Core

          # system "start notepad";
          sleep 1;
          while(1) {
          SendRawKey(VK_DOWN, KEYEVENTF_EXTENDEDKEY);
          SendKeys "{PAUSE 200}";
          }

          but i got the error message below:



          Bareword "VK_DOWN" not allowed while "strict subs" in use at tmp10.pl line 19.
          Bareword "KEYEVENTF_EXTENDEDKEY" not allowed while "strict subs" in use at tmp10
          .pl line 19.
          Execution of tmp10.pl aborted due to compilation errors.



          Could anyone please help me.



          thanks a lot.



          ---------------------------------
          Appel audio GRATUIT partout dans le monde avec le nouveau Yahoo! Messenger
          Téléchargez le ici !

          [Non-text portions of this message have been removed]
        • A Chan
          Hi Amine, I can run your code snippet without any errors. You might want to check if you actually have the Win32::GuiTest package installed properly. Cheers,
          Message 4 of 7 , Oct 10, 2005
          • 0 Attachment
            Hi Amine,

            I can run your code snippet without any errors. You might want to check if you actually have the Win32::GuiTest package installed properly.



            Cheers,



            Al Chan


            amine beghdous <aminedz29@...> wrote:

            Hi All,



            I'm new to perl and Guitest and I'm trying to execute the following perl script:



            #!/usr/bin/perl
            ## Initially generated by Win32-GuiTest Recorder (v1.03)

            ## Pragmas/Directives
            use strict;
            use warnings;




            ## Imports
            use Win32::GuiTest qw/:ALL/;

            $Win32::GuiTest::debug = 0; # Set to "1" to enable debug output.

            ## Main/Core

            # system "start notepad";
            sleep 1;
            while(1) {
            SendRawKey(VK_DOWN, KEYEVENTF_EXTENDEDKEY);
            SendKeys "{PAUSE 200}";
            }

            but i got the error message below:



            Bareword "VK_DOWN" not allowed while "strict subs" in use at tmp10.pl line 19.
            Bareword "KEYEVENTF_EXTENDEDKEY" not allowed while "strict subs" in use at tmp10
            .pl line 19.
            Execution of tmp10.pl aborted due to compilation errors.



            Could anyone please help me.



            thanks a lot.



            ---------------------------------
            Appel audio GRATUIT partout dans le monde avec le nouveau Yahoo! Messenger
            Téléchargez le ici !

            [Non-text portions of this message have been removed]





            SPONSORED LINKS
            Basic programming language C programming language Computer programming languages The c programming language C programming language List of programming languages

            ---------------------------------
            YAHOO! GROUPS LINKS


            Visit your group "perlguitest" on the web.

            To unsubscribe from this group, send an email to:
            perlguitest-unsubscribe@yahoogroups.com

            Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.


            ---------------------------------




            ---------------------------------
            Yahoo! Music Unlimited - Access over 1 million songs. Try it free.

            [Non-text portions of this message have been removed]
          • amine beghdous
            Thank you for your fast reply, Al Now it s working. A Chan a écrit : Hi Amine, I can run your code snippet without any errors. You
            Message 5 of 7 , Oct 11, 2005
            • 0 Attachment
              Thank you for your fast reply, Al
              Now it's working.

              A Chan <achan12301@...> a écrit :
              Hi Amine,

              I can run your code snippet without any errors. You might want to check if you actually have the Win32::GuiTest package installed properly.



              Cheers,



              Al Chan


              amine beghdous <aminedz29@...> wrote:

              Hi All,



              I'm new to perl and Guitest and I'm trying to execute the following perl script:



              #!/usr/bin/perl
              ## Initially generated by Win32-GuiTest Recorder (v1.03)

              ## Pragmas/Directives
              use strict;
              use warnings;




              ## Imports
              use Win32::GuiTest qw/:ALL/;

              $Win32::GuiTest::debug = 0; # Set to "1" to enable debug output.

              ## Main/Core

              # system "start notepad";
              sleep 1;
              while(1) {
              SendRawKey(VK_DOWN, KEYEVENTF_EXTENDEDKEY);
              SendKeys "{PAUSE 200}";
              }

              but i got the error message below:



              Bareword "VK_DOWN" not allowed while "strict subs" in use at tmp10.pl line 19.
              Bareword "KEYEVENTF_EXTENDEDKEY" not allowed while "strict subs" in use at tmp10
              .pl line 19.
              Execution of tmp10.pl aborted due to compilation errors.



              Could anyone please help me.



              thanks a lot.



              ---------------------------------
              Appel audio GRATUIT partout dans le monde avec le nouveau Yahoo! Messenger
              Téléchargez le ici !

              [Non-text portions of this message have been removed]





              SPONSORED LINKS
              Basic programming language C programming language Computer programming languages The c programming language C programming language List of programming languages

              ---------------------------------
              YAHOO! GROUPS LINKS


              Visit your group "perlguitest" on the web.

              To unsubscribe from this group, send an email to:
              perlguitest-unsubscribe@yahoogroups.com

              Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.


              ---------------------------------




              ---------------------------------
              Yahoo! Music Unlimited - Access over 1 million songs. Try it free.

              [Non-text portions of this message have been removed]





              ---------------------------------
              YAHOO! GROUPS LINKS


              Visit your group "perlguitest" on the web.

              To unsubscribe from this group, send an email to:
              perlguitest-unsubscribe@yahoogroups.com

              Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.


              ---------------------------------




              Sincères salutations,

              Amine BEGHDOUS
              06.17.50.92.57
              aminedz29@...


              ---------------------------------
              Appel audio GRATUIT partout dans le monde avec le nouveau Yahoo! Messenger
              Téléchargez le ici !

              [Non-text portions of this message have been removed]
            Your message has been successfully submitted and would be delivered to recipients shortly.