Hi Mates,

After a long searching i got the solution.

Instead of using complicated functions and methods, i use simple code
to retrieve the text from a Web Dialog.

require 'watir/ie'
require 'watir\contrib\enabled_popup'
require 'watir/dialog'
require 'watir/winClicker'

@ie = Watir::IE.new
@ie.goto("http://10.1.193.109/itrade/Login.aspx";)
@ie.maximize
@ie.text_field(:name,"txtUserName").set("wcorp")
@ie.text_field(:name,"txtPassword").set("wcorp123")
@ie.button(:name,"btnSubmit").click
@ie.form(:id,"form1").table(:id,"tbl0").cell(:id,"el6").fire_event
("onMouseOver")
@ie.form(:id,"form1").table(:id,"tbl7").cell(:id,"el57").click
@ie.frame(:id,"plFrame").table(:id,"PendingPane1_tblPP").button
(:id,"PendingPane1_btnNew").click
@ie.frame(:id,"wfFrame").button
(:id,"PageActionPane_btnSubmit").click_no_wait

hwnd = @ie.enabled_popup(10)
@ie1 = @ie.modal_dialog

puts @ie1.text

It retrieves the Web Dialog's text correctly..

Thanks all for your replies..




On Dec 8, 3:39 pm, Prince3105 <[EMAIL PROTECTED]> wrote:
> Hi Friends,
> I have searched enough, but i couldn't get the Modal dialog's error
> message, so mates please throw some light on this issue. I tried
> "AutoIT.WinGetText" but no use.
> Thanks.
>
> On Dec 1, 3:32 pm, Prince3105 <[EMAIL PROTECTED]> wrote:
>
> > when i execute the function , popup_text[0] returns nil. Still i am
> > searching for a solution and trying all methods in WinClicker class
> > but not yet received a solution. So please guys give some ways to
> > reach the target.
>
> > Thanks,
> > Prince3105
>
> > On Dec 1, 9:20 am, "wesley chen" <[EMAIL PROTECTED]> wrote:
>
> > > In face, you absolutely can search quite great solutions for the problem 
> > > in
> > > the group.
>
> > > Thanks.
> > > Wesley Chen.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Watir General" group.
To post to this group, send email to watir-general@googlegroups.com
Before posting, please read the following guidelines: 
http://wiki.openqa.org/display/WTR/Support
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/watir-general
-~----------~----~----~----~------~----~------~--~---

Reply via email to