SoftTree Technologies SoftTree Technologies
Technical Support Forums
RegisterSearchFAQMemberlistUsergroupsLog in
Ras Dialer Error

 
Reply to topic    SoftTree Technologies Forum Index » 24x7 Scheduler, Event Server, Automation Suite View previous topic
View next topic
Ras Dialer Error
Author Message
Michael Turbett



Joined: 18 Mar 2004
Posts: 4

Post Ras Dialer Error Reply with quote

Hello

I'm trying to use the Rasdial to connect to a PPP dial-up server and am getting the following error:
RAS Dialer Error: ERROR_NOT_ENOUGH_MEMORY

Note - The phone connection is being made, but the subsequent commands are not being processed.
I can actually open up a dos command prompt and manually ftp files and take advantage of the open Ras connection.

Below is the code I am using.
We have Windows 2000 as the operating system

Let me know how I can get this to work.
Thanks
Michael

This is the JAL Code
////////////////////////////////////////////////////////////
// 24x7 Scheduler 3.4.17
// Job Template: FTP download (known file names)
// Generated on 17-March-2004 10:30
////////////////////////////////////////////////////////////

// Download file(s) from FTP server.

Dim my_date string
Dim my_file string
Dim my_pos number
Dim( connection, number )
dim my_dir string
dim my_found boolean

// Create a new file name using the current date to archive yesterday's file
Today( my_date )
Pos( my_date, "/", 1, my_pos )
Replace( my_date, my_pos, 1, "_", my_date )

Pos( my_date, "/", 1, my_pos )
Replace( my_date, my_pos, 1, "_", my_date )

Concat( "c:\\archive\\arch_", my_date, my_file )

FileExists( "C:\\PNCLB\\filename.txt", my_found )

If( my_found, MOVE_FILE, MOVE_COMPLETED )

MOVE_FILE:
// my_file is the name of the archive file
FileMove( "C:\\PNCLB\\filename.txt", my_file )
goto MOVE_COMPLETED

MOVE_COMPLETED:

// establish RAS connection
RASDial( "PNC", "user", "", connection )

FTPGetFile "100...", "user", "password", "file", "c:\\PNCLB\\filename.txt"

// terminate RAS connection
RASHangUp( connection )


Wed Mar 17, 2004 5:33 pm View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7968

Post Re: Ras Dialer Error Reply with quote

ERROR_NOT_ENOUGH_MEMORY is usually misleading (it comes from Windows, not from 24x7). This error indicates the connection cannot be made. I guess in old Windows 3.0/3.1 days some programmer coded a generic error "not enough memory" for all "unknown" reasons. Anyway, if you have a valid connection setup it should appear as an icon in the Windows Start Menu/Settings/Network and Dial-up Connections/PNC. Click on this item manually and check if it can connect with the given user name/password. If it works it should work with RASDial.

Another tip, here is how you can get the file name using just one line of code

Before:
Dim my_date string
Dim my_file string
Dim my_pos number
Today( my_date )
Pos( my_date, "/", 1, my_pos )
Replace( my_date, my_pos, 1, "_", my_date )
Pos( my_date, "/", 1, my_pos )
Replace( my_date, my_pos, 1, "_", my_date )
Concat( "c:\\archive\\arch_", my_date, my_file )

After:
Dim( my_file, string, "c:\\archive\\arch_@T"mm_dd_yyyy"" )

: Hello

: I'm trying to use the Rasdial to connect to a PPP dial-up server and am
: getting the following error: RAS Dialer Error: ERROR_NOT_ENOUGH_MEMORY

: Note - The phone connection is being made, but the subsequent commands are
: not being processed.
: I can actually open up a dos command prompt and manually ftp files and take
: advantage of the open Ras connection.

: Below is the code I am using.
: We have Windows 2000 as the operating system

: Let me know how I can get this to work.
: Thanks
: Michael

: This is the JAL Code
: ////////////////////////////////////////////////////////////
: // 24x7 Scheduler 3.4.17
: // Job Template: FTP download (known file names)
: // Generated on 17-March-2004 10:30
: ////////////////////////////////////////////////////////////

: // Download file(s) from FTP server.

: Dim my_date string
: Dim my_file string
: Dim my_pos number
: Dim( connection, number )
: dim my_dir string
: dim my_found boolean

: // Create a new file name using the current date to archive yesterday's file
: Today( my_date )
: Pos( my_date, "/", 1, my_pos )
: Replace( my_date, my_pos, 1, "_", my_date )

: Pos( my_date, "/", 1, my_pos )
: Replace( my_date, my_pos, 1, "_", my_date )

: Concat( "c:\\archive\\arch_", my_date, my_file )

: FileExists( "C:\\PNCLB\\filename.txt", my_found )

: If( my_found, MOVE_FILE, MOVE_COMPLETED )

: MOVE_FILE: // my_file is the name of the archive file
: FileMove( "C:\\PNCLB\\filename.txt", my_file )
: goto MOVE_COMPLETED

: MOVE_COMPLETED: // establish RAS connection
: RASDial( "PNC", "user", "", connection )

: FTPGetFile "100...", "user", "password",
: "file", "c:\\PNCLB\\filename.txt"

: // terminate RAS connection
: RASHangUp( connection )

Thu Mar 18, 2004 10:01 am View user's profile Send private message
Michael Turbett



Joined: 18 Mar 2004
Posts: 4

Post Re: Ras Dialer Error Reply with quote

Hello

I am able to use dial-up networking connection manually and establish a valid connection.
I can then manually FTP files.
I still am getting the not enough memory error message when I use this dial-up connection thru the Rasdial JAL command.

Your JAL statement requires a userid and pswd, however the service I am dialing into does not require a password.
I suspect the error may be in that area, how can I pass a null value as a password.


Fri Mar 19, 2004 3:01 pm View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7968

Post Re: Ras Dialer Error Reply with quote

It does not support NULL passwords. Are you currently passing an empty string for the password?

Instead of calling RasDial/RasHangup commands you can use the following

Dim( pid, number )
RunAndWait( "rasdial.exe [connection name here]", "", 0, pid )
... do what you need to do here ...
RunAndWait( "rasdial.exe [connection name here] /DISCONNECT", "", 0, pid )

For more info run rasdial.exe /? from DOS command line

: Hello

: I am able to use dial-up networking connection manually and establish a valid
: connection.
: I can then manually FTP files.
: I still am getting the not enough memory error message when I use this
: dial-up connection thru the Rasdial JAL command.

: Your JAL statement requires a userid and pswd, however the service I am
: dialing into does not require a password.
: I suspect the error may be in that area, how can I pass a null value as a
: password.

Fri Mar 19, 2004 4:03 pm View user's profile Send private message
Display posts from previous:    
Reply to topic    SoftTree Technologies Forum Index » 24x7 Scheduler, Event Server, Automation Suite All times are GMT - 4 Hours
Page 1 of 1

 
Jump to: 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


 

 

Powered by phpBB © 2001, 2005 phpBB Group
Design by Freestyle XL / Flowers Online.