Jump to content
Sign in to follow this  
Besn

Another ftp problem

Recommended Posts

Besn

code:

#Include <FTPEx.au3>

#Include <WinAPI.au3>

$server = "server"

$username = "username"

$pass = "password"

$Open = _FTP_Open('MyFTP Control')

$Conn = _FTP_Connect($Open, $server, $username, $pass)

$Ftpp = _FTP_FilePut($Conn, 'C:\test.txt', '\test.txt')

If @error Then

$err = _WinAPI_GetLastError()

MsgBox(0, "", $err)

Exit

EndIf

$Ftpc = _FTP_Close($Open)

I got 12003 code meaning:

ERROR_INTERNET_EXTENDED_ERROR

An extended error was returned from the server. This is

typically a string or buffer containing a verbose error

message. Call InternetGetLastResponseInfo to retrieve the

error text.

Permits are okay, it works via simple ftp client (IE) anyone?

Thanks.

Share this post


Link to post
Share on other sites
LurchMan

MS Article that might help you:

http://support.microsoft.com/kb/q168492/


Dating a girl is just like writing software. Everything's going to work just fine in the testing lab (dating), but as soon as you have contract with a customer (marriage), then your program (life) is going to be facing new situations you never expected. You'll be forced to patch the code (admit you're wrong) and then the code (wife) will just end up all bloated and unmaintainable in the end.

Share this post


Link to post
Share on other sites
Besn

Thanks LurchMan, triend right away with flag set, tried with ascii and binary and every single one listed flag in autoit help, didnt work still getting 12003 error code.

Share this post


Link to post
Share on other sites
LurchMan

Use $INTERNET_FLAG_PASSIVE. I looked in the FTPex.au3 and at the top that's one of the constants and that's the one that MS was talking about.


Dating a girl is just like writing software. Everything's going to work just fine in the testing lab (dating), but as soon as you have contract with a customer (marriage), then your program (life) is going to be facing new situations you never expected. You'll be forced to patch the code (admit you're wrong) and then the code (wife) will just end up all bloated and unmaintainable in the end.

Share this post


Link to post
Share on other sites
Besn

I added passive flag everywhere..

$Open = _FTP_Open('MyFTP Control', 1, "", "", $INTERNET_FLAG_PASSIVE)

$Conn = _FTP_Connect($Open, $server, $username, $pass, 0, 0, 1, $INTERNET_FLAG_PASSIVE)

$Ftpp = _FTP_FilePut($Conn, 'C:\test.txt', '\test.txt', $INTERNET_FLAG_PASSIVE)

If @error Then

$err = _WinAPI_GetLastError()

MsgBox(0, "", $err)

Exit

EndIf

$Ftpc = _FTP_Close($Open)

and still no changes, 12003

Share this post


Link to post
Share on other sites
LurchMan

Hopefully someone comes along that will know more. That's the extent of my knowledge.


Dating a girl is just like writing software. Everything's going to work just fine in the testing lab (dating), but as soon as you have contract with a customer (marriage), then your program (life) is going to be facing new situations you never expected. You'll be forced to patch the code (admit you're wrong) and then the code (wife) will just end up all bloated and unmaintainable in the end.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.