in reply to Win32::IE::Mechanize from unix????

This is most likely a permissions/account problem. What user does your (Windows) ssh server run as?

Does this user have a desktop and is it logged in? Without a desktop (on which to launch and display IE), nothing will work.

Does this user have permissions to launch IE? You can check that by logging in via ssh and manually launching iexplore.exe.

Does this user have permissions to use OLE objects? This is an integral point of Windows, but I've seen some systems (mis)configured to disallow even DCOM and local COM.

More error messages and the actual code might also help us to help you, but if the script works when used directly but doesn't when launched through ssh, all fingers point to ssh as the culprit.

Replies are listed 'Best First'.
Re^2: Win32::IE::Mechanize from unix????
by monkster (Sexton) on Apr 15, 2008 at 09:15 UTC
    Thanks for the reply. I ll check those things out.
    The following is the code I am trying
    use Win32::IE::Mechanize; use Time::HiRes; my $ie = Win32::IE::Mechanize->new( visible => 1 ); $url = 'http://www.yahoo.com/'; $ie->get( $url ); sleep(5); print $ie->content; $ie->close;
    There is no error message as such. The output is the content of the standard "This Page cannot be Displayed" screen.
Re^2: Win32::IE::Mechanize from unix????
by monkster (Sexton) on Apr 16, 2008 at 04:23 UTC
    I looked into the questions asked by me and found this

    >Does this user have a desktop and is it logged in? Without a desktop (on which to launch and display IE), nothing will work.

    Nope, the user will connect to SSH server running on Windows (WinSSHD) from a unix machine using open ssh client. He will have access to command prompt of the SSH server running on Windows. Also in this scenario, user will not be able to get to desktop as ssh access is completely a CLI.

    >Does this user have permissions to launch IE? You can check that by logging in via ssh and manually launching iexplore.exe.

    Yes, user has rights and could launch iexplore.exe after doing ssh to windows machine.

    >Does this user have permissions to use OLE objects? This is an integral point of Windows, but I've seen some systems (mis)configured to disallow even DCOM and local COM.

    yes as same scripts works fine when we run it from same Windows machine which is running SSH server.