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

Re: SendKeys - Reserved characters (~)

Expand Messages
  • Piotr Kaluski
    I tend to disagree. I think the current approach is consistent with escaping characters in strings. n is a next line , but you can t expect this to work:
    Message 1 of 7 , Sep 19, 2005
    • 0 Attachment
      I tend to disagree. I think the current approach is consistent with
      escaping characters in strings. "\n" is a "next line", but you can't
      expect this to work:
      $string = "n"
      print "\$string";

      You have to explicitly state what do you escape:
      $string = "\n";
      print "$string";

      I am not trying to convince anyone that this is the best solution
      possible. My point is that SendKeys behaviour is consistent.

      -Piotr

      --- In perlguitest@yahoogroups.com, Nahum Cohen <nahum.cohen@g...>
      wrote:
      > This work indeed, but we miss the point: I don't know what is the
      scalar
      > data.
      > An optional work-around can be to check every character for the
      reserved
      > keys .. but this is only a work-around...
      >
      >
      >
      > On 9/19/05, Ernesto Guisado <erngui@a...> wrote:
      > >
      > > > use Win32::GuiTest qw(SendKeys);
      > > > $foo = '~test';
      > > > Win32::GuiTest::SendKeys("{$foo}");
      > >
      > > This should work:
      > >
      > > use Win32::GuiTest qw(SendKeys);
      > > Win32::GuiTest::SendKeys("{~}test");
      > >
      > > Cheers,
      > > E.
      > > --
      > > http://erngui.com
      > >
      > >
      > >
      > >
      > >
      > >
      > > Yahoo! Groups Links
      > >
      > >
      > >
      > >
      > >
      > >
      > >
      >
      >
      > [Non-text portions of this message have been removed]
    • negedi
      it is perl...use regexpr...should be simple :-) ... scalar ... reserved
      Message 2 of 7 , Sep 19, 2005
      • 0 Attachment
        it is perl...use regexpr...should be simple :-)

        --- In perlguitest@yahoogroups.com, Nahum Cohen <nahum.cohen@g...>
        wrote:
        > This work indeed, but we miss the point: I don't know what is the
        scalar
        > data.
        > An optional work-around can be to check every character for the
        reserved
        > keys .. but this is only a work-around...
        >
        >
        >
        > On 9/19/05, Ernesto Guisado <erngui@a...> wrote:
        > >
        > > > use Win32::GuiTest qw(SendKeys);
        > > > $foo = '~test';
        > > > Win32::GuiTest::SendKeys("{$foo}");
        > >
        > > This should work:
        > >
        > > use Win32::GuiTest qw(SendKeys);
        > > Win32::GuiTest::SendKeys("{~}test");
        > >
        > > Cheers,
        > > E.
        > > --
        > > http://erngui.com
        > >
        > >
        > >
        > >
        > >
        > >
        > > Yahoo! Groups Links
        > >
        > >
        > >
        > >
        > >
        > >
        > >
        >
        >
        > [Non-text portions of this message have been removed]
      Your message has been successfully submitted and would be delivered to recipients shortly.