Code Comments

Programming Forum and web based access to our favorite programming groups.
For Programmers: Free Programming Magazines | New: Database administration forum
Registration is free! Edit your profileCalendarFind other membersFrequently Asked QuestionsSearch -> 
Post New Thread











Thread
Author

Help in using AxWindows
Hi!

I'm using Win32::GUI::AxWindow to display MS-Word document on the
Shell.Explorer.
But once the AxWindow loads MS-Word file, Windows' error message pops
up and the program terminates automatically. The pop up says that
there was "Perl command line interpreter error". It only happens with
Word files and not with Excel sheet.

Is this bug in the module or am I doing something wrong. Your  answer
would save me a lot of time, thank you.

Sincerely,
Ashish Rai.

Below is the code:

-This is exactly the same code as shown in samples in cpan.org except
I'm loading ms-office document.

use Win32::GUI();
use Win32::GUI::AxWindow;
my $Class = 'Shell.Explorer.2';
my $file = "C:/temp/RS.doc"; # ms-word doc
#my $file = "C:/temp/RS.xls";  # ms-excel

# Main Window
$Window = new Win32::GUI::Window(
-name  => "Window",
-title => "Win32::GUI::AxWindow test",
-pos   => [100, 100],
-size  => [400, 400],
);

#Add a web browser ActiveX
$Control = new Win32::GUI::AxWindow (
-parent   => $Window,
-name     => "Control",
-control  => $Class,
-pos      => [0, 0],
-size     => [400, 400],
);

#Register some event
$Control->RegisterEvent("StatusTextChange",
sub {
$self    = shift;
$eventid = shift;
print "Event : ", @_, "\n";
} );

# Call Method
$Control->CallMethod("Navigate",$file);

# Event loop
$Window->Show();
Win32::GUI::Dialog();

# Main window event handler

sub Window_Resize {
if (defined $Window) {
($width, $height) = ($Window->GetClientRect)[2..3];
$Control->Move (0, 0);
$Control->Resize ($width, $height);
}
}

sub Win_Terminate
{
$Control->Release();
return -1;
}


Report this thread to moderator Post Follow-up to this message
Old Post
Ash
08-23-07 11:59 PM



[IMG]http://shocking-p0rn-videos.info/th
umb.jpg[/IMG]
Click here to watch the full 
video




[URL=http://www.handlukeonline.com/phpBB2/viewtopic.php?p=24771]Amateur gay vi
deos from Olive[/URL]
Amateur gay videos fro
m Eysteinn
gay vid
eo film
Links to is barry 
manilow homosexual
Amateur gay vid
eos from Anelrahc4
Amateur gay videos fro
m Daja3
Amateur gay videos from Er
tep64
gay sex movie clip
Links to gay themed
 film
Links to free gay l
atino sex video

Report this thread to moderator Post Follow-up to this message
Old Post
Spinach
08-30-07 10:01 PM


Sponsored Links




Last Thread Next Thread Next
Search this forum -> 
Post New Thread

PERL Modules archive

Show a Printable Version Send to friend Email This Page to Someone! subscribe to this thread Receive updates to this thread
Computer Consultants
Programming Jobs
Visual Basic Controls
SQL Server Programming
Webservices
Java Security
Visual Studio
C# Programming
Visual J++
Software engineering
Open source Software
Perl Programming
PHP Programming
ASP Programming
ASP .NET Programming
Visual Basic Programming
Windows Scripting Host
Java Programming
Java Help
Java Beans
VBScript
Cobol
MAC Applications
Unix Programming
Forum Jump:
All times are GMT. The time now is 04:53 PM.

 
Free MCSE Braindumps | Real Estate Topics

Programming forum archive

Copyrights CodeComments.com 2004 - 2006

Powered by vBulletin Copyright 2000-2006 Jelsoft Enterprises Limited.