08-13-2008
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..
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
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
2. Shell Programming and Scripting
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
3. Shell Programming and Scripting
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
4. Shell Programming and Scripting
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
5. Shell Programming and Scripting
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
6. Shell Programming and Scripting
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
7. Shell Programming and Scripting
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
8. Shell Programming and Scripting
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
9. Shell Programming and Scripting
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
10. Shell Programming and Scripting
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
LEARN ABOUT OPENSOLARIS
gnome-session-save
gnome-session-save(1) User Commands gnome-session-save(1)
NAME
gnome-session-save - saves or terminates the current GNOME session
SYNOPSIS
gnome-session-save [--gui] [--kill] [--session-name=name] [--silent] [gnome-std-options]
DESCRIPTION
gnome-session-save can be used from a GNOME session to save a snapshot of the currently running applications. This session will be later
restored at your next GNOME startup session.
OPTIONS
The following options are supported:
--gui
If specified, then any errors will be displayed in a dialog box. Otherwise, such messages are displayed to stderr. Note that this
option has no affect any dialogs that the window manager might display.
--kill
Terminates the GNOME session. The session will not be saved if this option is provided, unless the user has configured their session
to always save on logout.
-s, --session-name=name
Set name of session to save.
--silent
Avoids displaying any confirmation or dialogs, including ones that are displayed by the window manager (such as dialogs informing the
user about any windows that cannot save session, or session logout confirmation when the --kill option is also used).
gnome-std-options
Standard options available for use with most GNOME applications. See gnome-std-options(5) for more information.
EXAMPLES
Example 1: Saving the user's current session
example% gnome-session-save
Example 2: Terminating the user's current session
example% gnome-session-save --kill
EXIT STATUS
The following exit values are returned:
0 Application exited successfully
>0 Application exited with failure
FILES
The following files are used by this application:
/usr/bin/gnome-session-save The command-line executable for the application.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Availability |SUNWgnome-session |
+-----------------------------+-----------------------------+
|Interface stability |Volatile |
+-----------------------------+-----------------------------+
SEE ALSO
gnome-session(1), metacity(1), attributes(5), gnome-std-options(5)
NOTES
Written by Brian Cameron, Sun Microsystems Inc., 2003, 2006, 2007.
SunOS 5.11 07 Nov 2007 gnome-session-save(1)