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

258RE: [perlguitest] Re: SetFocus

Expand Messages
  • Maricel Ciupitu
    Jun 27, 2003
      Hi All,

      The SetFocus is working nice, really a good job. No more SendKeys("{TAB}").
      I can set focus on many controls, set text for this controls, get text from other controls and so on. My problem is a grid control ( class name GXWND ) from which I can not get the text that it contains and so I am not able to determine if the tested program ( a Clarify client) is working corectly.I tried to send WM_COPY to copy to clipboard or WM_GETTEXTLENGTD and WM_GETTEXT or GetWindowText but no success.

      Can you help ?
      Regards,
      Maricel

      -----Original Message-----
      From: Ernesto Guisado [mailto:erngui@...]
      Sent: Monday, June 23, 2003 5:17 PM
      To: perlguitest@yahoogroups.com
      Subject: [perlguitest] Re: SetFocus


      I messed up the upload :-(

      The change I wanted in guitest.xs is:

      HWND
      SetFocus(hWnd)
      HWND hWnd
      CODE:
      AttachWin(hWnd, TRUE);
      RETVAL = SetFocus(hWnd);
      AttachWin(hWnd, FALSE);
      OUTPUT:
      RETVAL

      Sadly haven't got a compiler handy at the moment. I'll upload again
      in some hours time...

      Regards,
      Ernesto.
      -- Ernesto Guisado http://triumvir.org


      --- In perlguitest@yahoogroups.com, "Maricel Ciupitu"
      <maricel.ciupitu@c...> wrote:
      > Hi Ernesto,
      >
      > I made some diff between 1.49.2 and 1.50 and it seems there are no
      differences.
      > Anyhow I tested my program with 1.50 and no results.
      > Here are a sample code:
      >
      >
      > my $SW_SHOWMAX=3;
      > my $SW_SHOWNORM=1;
      > my $CB_SHOWDROPDOWN=0x014F ;
      >
      > # Obtain handle to UIEditor window
      > my (@w) = WaitForWin(5,0, "^UIEDITOR", ""); # my function which
      waits 5 seconds
      > my $w_uie=$w[0];
      >
      > SetForegroundWindow($w_uie) if scalar @windows == 1;
      > #SetActiveWindow($w_uie);
      > ShowWindow($w_uie, $SW_SHOWNORM) ;
      >
      > MenuSelect("&File|&Open|&Form",$w_uie) or die "?? MenuSelect";
      > sleep 2;
      > SetForegroundWindow($w_uie);
      >
      > my ($comb1,$comb2);
      > #----------- Obtain handles to Comboboxes
      >
      > @w = WaitForWin(5,$w_uie,undef , "ComboBox");
      > for $w (@w) {
      > print "$w=",@t=GetComboContents($w),"\n";
      > $comb1=$w if $t[0]=~/Title/i ;
      > $comb2=$w if $t[0]=~/starts/i ;
      > }
      > # comb1 and comb2 are OK
      > sleep 2;
      > SetForegroundWindow($w_uie);
      > SetActiveWindow($w_uie);
      >
      > SetFocus($comb1); # NOT WORKING
      > #$s=SendMessage($comb1,$CB_SHOWDROPDOWN,$SW_SHOWNORM,0);
      > #print "Send=$s\n";
      > SendKeys("I");
      >
      > SetFocus($comb2); # NOT WORKING
      > SendKeys("=");
      >
      > -----Original Message-----
      > From: Ernesto Guisado [mailto:erngui@a...]
      > Sent: Sunday, June 22, 2003 3:16 PM
      > To: perlguitest@yahoogroups.com
      > Subject: [perlguitest] Re: SetFocus
      >
      >
      > Hi,
      >
      > the docs for SetFocus on MSDN say "The window must be attached to
      the
      > calling thread's message queue."
      >
      > I've released a patch to see if I can get it to work... Could you
      > give the following file in the Files section a try:
      >
      > Win32-GuiTest--setfocus-1.50.zip
      >
      > Thanks,
      > Ernesto.
      > --
      > Ernesto Guisado http://triumvir.org
      >
      >
      > --- In perlguitest@yahoogroups.com, "Maricel Ciupitu"
      > <maricel.ciupitu@c...> wrote:
      > > Hi Gurus,
      > >
      > > I am trying to avoid using Sendkyes( {TAB}..) to put focus on
      some
      > controls and instead use SetFocus to be more confident on which
      > control I am sending keys but this seems to not functioning.
      > > Any ideas ?
      > > Tks,
      > > Maricel
      > >
      > >
      > > ------------------------------------------------------------------
      --
      > -----------
      > > The content of this communication is classified as Mobifon SA
      > Romania Confidential and Proprietary Information.The content of
      this
      > communication is intended solely for the use of the individual or
      > entity to whom it is addressed and others authorized to receive it.
      > If you are not the intended recipient you are hereby notified that
      > any disclosure, copying, distribution or taking any action in
      > reliance on the contents of this information is strictly prohibited
      > and may be unlawful. If you have received this communication in
      > error, please notify us immediately by responding to this
      > communication then delete it from your system. We appreciate your
      > assistance in preserving the confidentiality of our correspondence.
      > Thank you.
      > >
      > > Prezentul mesaj constituie o Informatie confidentiala si este
      > proprietatea exclusiva a MobiFon S.A.. Mesajul se adreseaza numai
      > persoanei fizice sau juridice mentionata ca destinatara, precum si
      > altor persoane autorizate sa-l primeasca. In cazul in care nu
      sunteti
      > destinatarul vizat, va aducem la cunostinta ca dezvaluirea,
      copierea,
      > distribuirea sau initierea unor actiuni pe baza prezentei
      informatii
      > sunt strict interzise si atrag raspunderea civila si penala. Daca
      ati
      > primit acest mesaj dintr-o eroare, va rugam sa ne anuntati imediat,
      > ca raspuns la mesajul de fata, si sa-l stergeti apoi din sistemul
      > dvs. Apreciem si va multumim pentru sprijinul acordat in pastrarea
      > confidentialitatii corespondentei noastre.
      > > ------------------------------------------------------------------
      --
      > -----------
      >
      >
      > Yahoo! Groups Sponsor
      >
      >
      >
      > 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.
      >
      >
      > --------------------------------------------------------------------
      -----------
      > The content of this communication is classified as Mobifon SA
      Romania Confidential and Proprietary Information.The content of this
      communication is intended solely for the use of the individual or
      entity to whom it is addressed and others authorized to receive it.
      If you are not the intended recipient you are hereby notified that
      any disclosure, copying, distribution or taking any action in
      reliance on the contents of this information is strictly prohibited
      and may be unlawful. If you have received this communication in
      error, please notify us immediately by responding to this
      communication then delete it from your system. We appreciate your
      assistance in preserving the confidentiality of our correspondence.
      Thank you.
      >
      > Prezentul mesaj constituie o Informatie confidentiala si este
      proprietatea exclusiva a MobiFon S.A.. Mesajul se adreseaza numai
      persoanei fizice sau juridice mentionata ca destinatara, precum si
      altor persoane autorizate sa-l primeasca. In cazul in care nu sunteti
      destinatarul vizat, va aducem la cunostinta ca dezvaluirea, copierea,
      distribuirea sau initierea unor actiuni pe baza prezentei informatii
      sunt strict interzise si atrag raspunderea civila si penala. Daca ati
      primit acest mesaj dintr-o eroare, va rugam sa ne anuntati imediat,
      ca raspuns la mesajul de fata, si sa-l stergeti apoi din sistemul
      dvs. Apreciem si va multumim pentru sprijinul acordat in pastrarea
      confidentialitatii corespondentei noastre.
      > --------------------------------------------------------------------
      -----------


      Yahoo! Groups Sponsor
      ADVERTISEMENT




      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.


      -------------------------------------------------------------------------------
      The content of this communication is classified as Mobifon SA Romania Confidential and Proprietary Information.The content of this communication is intended solely for the use of the individual or entity to whom it is addressed and others authorized to receive it. If you are not the intended recipient you are hereby notified that any disclosure, copying, distribution or taking any action in reliance on the contents of this information is strictly prohibited and may be unlawful. If you have received this communication in error, please notify us immediately by responding to this communication then delete it from your system. We appreciate your assistance in preserving the confidentiality of our correspondence. Thank you.

      Prezentul mesaj constituie o Informatie confidentiala si este proprietatea exclusiva a MobiFon S.A.. Mesajul se adreseaza numai persoanei fizice sau juridice mentionata ca destinatara, precum si altor persoane autorizate sa-l primeasca. In cazul in care nu sunteti destinatarul vizat, va aducem la cunostinta ca dezvaluirea, copierea, distribuirea sau initierea unor actiuni pe baza prezentei informatii sunt strict interzise si atrag raspunderea civila si penala. Daca ati primit acest mesaj dintr-o eroare, va rugam sa ne anuntati imediat, ca raspuns la mesajul de fata, si sa-l stergeti apoi din sistemul dvs. Apreciem si va multumim pentru sprijinul acordat in pastrarea confidentialitatii corespondentei noastre.
      -------------------------------------------------------------------------------
    • Show all 10 messages in this topic