Hi there. I'm attempting to use Win32::RASE to automate the creation of a dial-up connection.

I've read the docs for the module, and it seems it hasn't been updated for a while - since 2000, I believe. It only mentions successfully running on Windows NT, nothing higher.

However, it seems to be a wrapper for Win32::API calls to the rasapi32.dll functions, which in theory are supposed to work on every win32 version.

I'm trying to use it on Windows 2000; I'm getting some odd behaviour. If I use the standard syntax as described in the documentation, sometimes it creates the connectoid as indicated, but othertimes it doesn't even do that. Even if it successfully creates a connectoid, it always dies immediately after with an "application error" - saying something about an instruction at some hex address tried to reference an instruction at some other hex address, and the memory could not be "written".

I stuck some print statements into RASE.pm just to clarify, and sure enough, if I try to call the sub RaseCreateEntry() with appropriate arguments, the sub appears to be dying right after the following snippet:

$RasSetEntryProperties ||= new("rasapi32", "RasSetEntryProperties", [P +,P,P,N,P,N], N); my $ret = $RasSetEntryProperties->Call($PHONEBOOK||0, $props->{name}, $RASENTRY, length($RASENTRY),0,0);

Anyone have any thoughts on what I can try to correct this? I suppose I can experiment with using the Win32::API directly with the RAS* functions - I haven't done that before, but no time like the present to learn, I suppose :)


In reply to Win32::RASE problems by mabman

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.