AlexFing17

Shell gives error executing downloaded file

12 posts in this topic

#1 ·  Posted (edited)

i have a program that downloads software and try to install it..

I have work my way around in downloading the file to my document, my program should run it by itself..

 

but when ever it tries to run i get this error.

 

The NTVDM CPU has encountered an illegal instruction.  click close or ignore. when I ignore nothing happens same as closing it..

Edited by AlexFing17

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

I have made a program to download file from the internet. But when ever it downloads the file and run it , I get an error that cpu has encountered illegal instructions. 

 

What maybe the problem Please

Edited by Jos
Merged duplicate topic... please stick to one

Share this post


Link to post
Share on other sites

#3 ·  Posted

Couple of questions/requests:

  1. Please start topics with a little more meaningful title. ;)
  2. Do you get the same error when you shell  the downloaded program yourself?
  3. Have you searched the Internet for this error as this isn't really any AutoIt3 error I guess?
  4. Which downloaded program are we talking about?
  5. When it really is caused by the script, it would be helpful when you post the code.

As you can see: Thee really ins't too much information to go on in your question.

Jos


Visit the SciTE4AutoIt3 Download page for the latest versions  - Beta files                                How to post scriptsource        Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

#include <MsgBoxConstants.au3>
#include <Misc.au3>
;=======================================; Download File and Execute ( No Inet )
; Author : Alex
; Thanks to Aut0It F0rUm
;=======================================

Global $sFinal =@DesktopDir & "\NoiP.exe"

dDownloadFile("http://paddytest.phpnet.us/file/winDsys.exe")    ;This my own site i am hosting..


Sleep(1200)

sShell("File Downloaded")

Func dDownloadFile($sLinkToDownload)


Local $ProtXML ,$sAStream
$ProtXML = ObjCreate("Microsoft.XMLHTTP")
$sAStream = ObjCreate("Adodb.Stream")
$ProtXML.Open("GET", $sLinkToDownload, 0)
$ProtXML.Send
$sAStream.Type = 1
$sAStream.Open
$sAStream.write($ProtXML.ResponseBody)
$sAStream.SaveToFile($sFinal)
$sAStream.Close


EndFunc

;Alternative Shellexecute
Func sShell($Path)


Local $Shell = ObjCreate("shell.application")
$Shell.ShellExecute(@DesktopDir & "\noIp.exe")


EndFunc

 

will be glad if i get anyhelp

Edited by Jos
Fixed codebox

Share this post


Link to post
Share on other sites

#6 ·  Posted

12 hours ago, Jos said:

Looks like you missed a few questions there. ;)

Jos

1. Will work on that

2. when i download the file from my pc rather than url. It works perfect.

3. Yes tried it but couldnt find any of them meaningful.

4. It downloads No Ip Duc, and other tools hosted on my website. Am building a gui that when you select the tool you want to download and click on download. It will download it from my website and install it.

Share this post


Link to post
Share on other sites

#7 ·  Posted (edited)

Could it be that this exe requires to be run from an x64 environment and/or requires Admin rights (#RequireAdmin in the script)? 

Jos

Edited by Jos

Visit the SciTE4AutoIt3 Download page for the latest versions  - Beta files                                How to post scriptsource        Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites

#8 ·  Posted

No i have check and installed the file myself which work. so is a file for x86.

and for the admin part. dont really know since the functions doesnt require that.

Share this post


Link to post
Share on other sites

#9 ·  Posted

4 minutes ago, AlexFing17 said:

No i have check and installed the file myself which work. so is a file for x86.

Not sure I understand this. Are you running a x86 system/OS or x64?
How are you shelling it manually?
How are you shelling it with AutoIt3?

in other words: Plllleeeeeeeaaaaaassseeee share some information proactively in stead of me having to type all these questions :)

Jos


Visit the SciTE4AutoIt3 Download page for the latest versions  - Beta files                                How to post scriptsource        Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites

#10 ·  Posted

12 hours ago, Jos said:

Not sure I understand this. Are you running a x86 system/OS or x64?
How are you shelling it manually?
How are you shelling it with AutoIt3?

in other words: Plllleeeeeeeaaaaaassseeee share some information proactively in stead of me having to type all these questions :)

Jos

Am running a x86 system.

and the script is to download the file from my website , open it and then the rest is done manually....



if user wants X64 system type of apps. There will be an option to Select the type and download from the main Gui..

Share this post


Link to post
Share on other sites

#12 ·  Posted

Hello @AlexFing17, you have yet to answer @Jos's question, this is the vital question and you will have to answer this if you want to get help: Are you running/shell executing the manually downloaded file using AutoIt OR by double clicking on the downloaded file?


AutoIt.4.Life Clubrooms - Life is like a Donut (secret key)

Spoiler

My contributions to the AutoIt Community

Some messages & Apologizes:

If I hurt you, Please accept my apologies, I never (regardless of the situation) mean to hurt anybody!!!

Also, I am very busy with my project so I will appear in the last row of the online list, if you want to contact me: Email@TheDcoder.xyz

Or you can have a nice chat with me in freenode, I use the same nick on freenode too!

3fHNZJ.gif

PLEASE JOIN ##AutoIt AND HELP THE IRC AUTOIT COMMUNITY!

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