Skip to content
⌘ NSIS Forum Archive

inetc plugin not working

27 posts

mario_tiska#

inetc plugin not working

i just updated my version of nsis form 2.16 to 2.18 and i dont know why i cant get inetc to download simple files.

it used to work perfectly i even went back to 2.16 and nothing happened. i keep getting the "File Open Error", i know the file is there and the address is good.

whats really annoying is that im using exactly the SAME code that used to work before updating nsis.

help, anybody?
mario_tiska#
here goes...

i guess yo can change the inetc::get parameters to any file instead of the variables set, i did it but it didnt do anything different.
mario_tiska#
nope. it wasnt that, i checked out the example thats originaly packed with the plugin, tested it and it didnt work. so im guessing that something is wrong on my machine.

im attaching the plugin and the example script.
Takhir#
dll version is latest. Retested on XP / LAN - OK. 2003 Server LAN + Dial-up - OK. What about XP firewall settings on your comp?
mario_tiska#
everything is smooth now, after reinstalling nsis, pushing some buttons and rebooting a dozen times something finaly did the trick. thx!
Afrow UK#
That is strange!
I have had that error myself though, but it was when I was missing the /END. Basically the plugin takes values from the stack and interprets them as download URL's. /END will stop it parsing the NSIS stack for more parameters.

-Stu
Takhir#
kichik asked for multiple files download, but I am not sure this is a good feature. A bit faster very seldom and lot of troubles for all other users...
mario_tiska#edited
i just noticed that NOT using the silent mode made all the difference.

the problem wasn't updating nsis, it was updating inetc. i cheked out the change log in the source code for inetc and as i expected silent mode has recent changes. am i the only one having problems with silent mode?
mario_tiska#
Takhir, here is inetc.debug.log.
Takhir#
plug-in exited with code=File Open Error, in most cases this is result of messed parameters in the command line. Can you attach script that creates download problem with silent mode enabled - debug log shows NOT silent mode. You wrote above that silent mode is error source.
mario_tiska#
maybe i didnt make my self clear. the problem comes when i use silent mode. if i use something else (for example: caption or banner), there is no problem, no file open error.

here is the .nsi file and the debug log.
Takhir#
Last Inetc build has a bit changed parameters format, /silent comes without additional text http://nsis.sourceforge.net/Inetc_plug-in 🙂
Your code should work with additional /caption key word after /silent or without caption text at all (/silent "http://...)
Takhir#
I forgot to note - use DetailPrint before plug-in call if you want set 'progress text' in the silent mode.
Xokar#
Can someone post an example of the working /SILENT code, because I can't for the life of me get this working!

Here's my code:

Inetc::get /SILENT "ftp://$Username:$Password@$Server/../../var/file.xml" "$TEMP\file.xml" /END
Takhir#
Hm.. This works:
Name "Inetc ftp authentication Test"
OutFile "ftp_gnu.exe"
!include "MUI.nsh"
!define MUI_ICON "${NSISDIR}\Contrib\Graphics\Icons\modern-install-colorful.ico"
!insertmacro MUI_PAGE_INSTFILES
!insertmacro MUI_LANGUAGE "English"

Section "Dummy Section" SecDummy

inetc::get /silent "ftp://anonymous:a.b.com@ftp.gnu.org/MISSING-FILES" "$EXEDIR\MISSING-FILES" /end
Pop $0 # return value = exit code, "OK" if OK
MessageBox MB_OK "Download Status: $0"

SectionEnd
Xokar#
Ah I think I see the problem now, it's writing the file, but doesn't ever stop. I end up with a file that has the same text repeated over and over again until I kill the program.

Is there a newer release of Inetc?
Takhir#
It was May 21 version with endless download, aren't it? If so, what ftp server you used ? Can I reproduces your situation?
Xokar#
Yep, it was the latest version that I had problems with.

I was connecting to a Solaris 10 UNIX FTP server, but it's not online so I'm not sure how you'll reproduce it.
justme123#
Hi,

like mario tiska i've got an error when using the /SILENT option with inetc:😛ost

this code fails with 'Connection error'

inetc:😛ost /SILENT "email=$emailAddress" "http://xxx" "$EXEDIR\out.htm" /END
this works but flashes 'connecting' and progressbar for a second

inetc:😛ost "email=$emailAddress" "http://xxx" "$EXEDIR\out.htm" /END
this works but uses get

inetc::get /SILENT "http://xxx?email=$emailAddress" "$EXEDIR\email.htm" /END
fwiw, post also fails with /NOCANCEL and/or /TIMEOUT.

Versions:
nsis: 2.45
os: win XP sp3
inetc: latest (inetc.dll created 2008-09-01)

how do you use post together with /SILENT?

regards, justme123
Takhir#

inetc:😛ost TEXT2POST [other_parameters, for example /SILENT] URL FILE [/END]