Read popup message and save it in file


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Read popup message and save it in file
# 1  
Old 08-13-2008
Question Read popup message and save it in file

Hi,
I am trying to automate one of the application using IE:Auotmation in perl
My web application has few text fields and 2 buttons "Save Changes" and "Discard Changes".I have written code to enter values to the text fields fetching from input file and click the button "Save Changes".As soon as "save changes" button is clicked pop up message will appear in another window saying "Request acknowledged-No Errors Reported" .I am stuck up in writing code to read this message and put it in some text file .Please some one help how to proceed.I will be very thankful to u.
HI, I have written a script to get the text from PopupWindow.But when i run it is showing error in IEAutomation.pm like this - -Use of uninitialized value $counter in numeric le(<=) at E:/Perl/site
+/lib/win32/IEAutomation.pm line 537
-Can't call method "title" on an undefined value at E:/Perl/site/lib/w
+in32/IEAutomation.pm line 542.

Following is my perl script -
#!/usr/bin/perl
use Win32::OLE;
use Win32::IEAutomation;
$IE = Win32::OLE->new("InternetExplorer.Application")
|| die "Could not start Internet Explorer.Application\n";
$IE = Win32::IEAutomation->new( visible => 1, maximize => 2);
$IE->gotoURL('http://10.255.114.191/snmpconfig.html');
$IE->getButton('caption:',"Configure SNMP v1/v2c" )->Click;
open(OUT, "E:/test/input.txt") || die;
@lines = <OUT>;
foreach $value (@lines)
{
$IE->getTextBox('name:',"get_comm_name")->SetValue("$value");
$IE->getButton('caption:',"Apply")->Click;
sleep 5;
my $popup = $ie->getPopupWindow("Request Acknowledged-Phaser 4510DT");
$popup->getTable('id:', "headingtext");
print $popup;
}
close OUT;

Please anyone give me solution for this

Last edited by jyo123.jyothi; 08-13-2008 at 03:23 AM..
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Read a file and save every word in a variable to use

Hello there so i have a txt file containing word like "one two three four plus four five six". I want to save every word in the file into a variable, and then use that variable to generate real numbers and apply the arithmetic value on them. example: the txt files becomes 123 + 456 and... (10 Replies)
Discussion started by: azaiiez
10 Replies

2. Shell Programming and Scripting

Read a file name from a text file and save it in a variable

i have a text file consists of different file names like: line 1: lib/libIMb.so message broker file line 2: lil/imbdfg.lil message broker file i need to extract libIMb.so and imbdfg.lil files from those lines and save them in a variable. so that i can search for... (9 Replies)
Discussion started by: santosh2626
9 Replies

3. Shell Programming and Scripting

cannot get to read from file and save to file

how can i get this script to read users input from file and save the users input if it is not in the file? #!/bin/sh echo -n "filename:" read filename for i in 1 2 3 4 5 do echo -n "Enter filename:" read lineoftext echo "$lineoftext" >> $filename done (1 Reply)
Discussion started by: noob
1 Replies

4. Shell Programming and Scripting

Read file and for each line replace two variables, add strings and save output in another file

Hi All, I have a file, let's call it "info.tmp" that contains data like this .. ABC123456 PCX333445 BCD789833 I need to read "info.tmp" and for each line add strings in a way that the final output is put /logs/ua/dummy.trigger 'AAA00001.FTP.XXX.BLA03A01.xxxxxx(+1)' where XXX... (5 Replies)
Discussion started by: Andy_ARG
5 Replies

5. Shell Programming and Scripting

Help w/ script to read file and parse log message

Hi, I am working on the script to parsing the specific message like "aaaa" in multiple log files like N1-***,N2-***,N3-***... The script is to find the list of lof files which contains the message "aaaa" and export the list into excel filE. Can anyone give help? Thanks (2 Replies)
Discussion started by: shyork2001
2 Replies

6. Shell Programming and Scripting

popup message

file:///C:/DOCUME%7E1/eelavazh/LOCALS%7E1/Temp/moz-screenshot-1.jpgHI,, I am new to the shell scripting and trying to be adopted soon...Can u please suggest me how do we populate a message when the following condition fails...... Thanks and Regards, Ela success250=`grep -c... (0 Replies)
Discussion started by: elavv
0 Replies

7. Shell Programming and Scripting

call a popup message from the shell script

Hi , this is my first querry in this forum and I am new bee to the shell scripting..Please have a glance on my query and give ur valuable suggestions . I have a crown job which performs one function,If the job has done successfully we need to send message to some group as "SUCCESSFUL" or else we... (0 Replies)
Discussion started by: elavv
0 Replies

8. Shell Programming and Scripting

read file and output message

hi, I have a baby.txt file with two type of message: xxxxxxxx is missing xxxxxxxxxxx is not missing xxxx is missing xxxxxxxx is not missing xxxxxxxx is not missing For the above, I need to read file and get all "xxxx is missing" and write into baby_missing.txt. If no message "xxxxx is... (12 Replies)
Discussion started by: happyv
12 Replies

9. Shell Programming and Scripting

Read file from within AWK and save $1 to a variable

Hi I am very new to NAWK programming so this question is probably going to sound really stupid: I have a NAWK script which contains a DO loop. During each loop it runs a FORTRAN program which in turn generates two output files , each one containing 2 integer variables. I would appreciate it... (8 Replies)
Discussion started by: robbiegregg
8 Replies

10. UNIX for Dummies Questions & Answers

samba popup message

I would like to display a popup message to my clients when they connect to my samba share explaining certain file restricitions and maintenance instructions. How do I go about this method? Right now I'm sharing linux with mac clients and pc's, but can only display a message with my mac clients. ... (4 Replies)
Discussion started by: benzo
4 Replies
Login or Register to Ask a Question