eBook authors eBook Software - create and publish your own ebooks
Create your own eBooks
Learn How To Create, Publish & Market E-Books
E-Book Creation Software
Add sophisticated multimedia to your E-Books
Create E-Book covers in minutes
E-Book Marketing & Promotion made easy
Search engine for E-Books
Interviews with eBook authors
Tools for building better eBooks
Archived Message:

embedded exes won't run with ini files

brainsci I have an embedded exe in my ebook.  Because this exe is run differently in different cases, opening different sound files, I use a batch file with a command to open the exe with an INI file, that tells it which sound files to play.

So now we have a BAT file telling the exe to open with specific paramters.  So far, so good.  It works.  You can embed batch files just like executables.

The problem is that with winXP, win2000, and winVISTA, the batch files runs, but the exe does not launch.   Sometimes.

However, if you create a new account on the system, and then run the ebook from the new user account, it works just fine.

A 'simple' exe will run just fine.  By this I mean an exe that does not get input from an INI file.

Does anyone here know of any differences between a new user account and an administrator account that would prevent an INI file from performing as it should?

BTW, telling me that the embeded executable scripts are not intended for use with INI files is NOT a 'fix' (I've been over that one with a local geek who claims to be the master of all things scriptable).  

They work with non-admin users - why shouldn't they work with administrators accounts?

Posted on: 6:07 pm on May 31, 2007
brainsci One additional note:
The batch file, ini file, executable and sound files work just fine when they are run outside run outside of the ebook (including the user accounts where they won't run when they are packed in the ebook).

Posted on: 8:47 pm on May 31, 2007
rlemire brainsci;

Most of this problem is caused by the fact that Activ E-Book uses the Internet Explorer browser engine to perform it's magic. Why is this relevant? There are a number of security issues that develop when certain types of programs are run from inside a browser. It could be that you've stepped across a permission boundary with the process your using.

It might be better if you could store your "ini" information in a JavaScript Array and run your "exe" program from inside Activ E-Book without using a "Bat" file. Or you might read the "ini" information using Activ E-Book and then run the program with Activ E-Book again without the "Bat" file.

If you need to run the "exe" program external to Activ E-Book control you might look at "WSH" (Window Scripting Host) for a solution. WSH can do many things outside of the Browser permission envelope.


Posted on: 9:55 pm on May 31, 2007
brainsci I use too many ini files to put them in a javaScript array.

I cannot run the exe, with the INI config information, without using a BAT file.  There is no way to format the command that I can see.  Any ideas?  Besides, the BAT file runs - the exe it invokes doesn't run.

Also, the security settings are the same for the administrator as they are for the second account, but it runs from the latter, but not the former.  Nevertheless, I'll look into that, though I don't have much hope for it as a soultion.  Do you suppose the INI file could be mis-read as an activeX script?

Posted on: 10:23 pm on May 31, 2007
rlemire brainsci;

How many ini files do you have ( less than 10000 )?

To run an exe file from within Activ E-Book you could use a command that looks something like:

window.external.ActivRun("##RUN('{ebook}\\someprogram.exe config_information')";  (all one line)

You mentioned that your "Bat" file runs OK outside of your eBook but not when it is run inside your eBook. My answer said that your "Browser" security might be causing the problem because Activ E-Books run in a Browser window. This becomes relevant because it depends on which "USER" account is running the eBook and how the (Internet Explorer) permissions for that "USER" is set up.

Problems also develop when you try to read or write to files ( i.e. INI files ) using Vista. See my web pagehttp://hyprlock.comfor a link that describes how to run eBooks in Vista.

I do not think the INI file is being mis-read as an activeX script.


Posted on: 11:04 pm on May 31, 2007

List All Archived Forums

Copyright © 2000-2018, Answers 2000 Limited.

With any business, it is up to the individual owner of said business to ensure the success of the business. You may make more or less than any sample figures or results that might be quoted on our web sites or other publications. All business involves risk, and many businesses do not succeed. Further, Answers 2000 Limited does NOT represent that any particular individual or business is typical, or that any results or experiences achieved by any particular individual/business is necessarily typical.

Disclosure: Our company's websites' content (including this website's content) includes advertisements for our own company's websites, products, and services, and for other organization's websites, products, and services. In the case of links to other organization's websites, our company may receive a payment, (1) if you purchase products or services, or (2) if you sign-up for third party offers, after following links from this website. Unless specifically otherwise stated, information about other organization's products and services, is based on information provided by that organization, the product/service vendor, and/or publicly available information - and should not be taken to mean that we have used the product/service in question. Additionally, our company's websites contain some adverts which we are paid to display, but whose content is not selected by us, such as Google AdSense ads. For more detailed information, please see Advertising/Endorsements Disclosures

Our sites use cookies, some of which may already be set on your computer. Use of our site constitutes consent for this. For details, please see Privacy.

Click privacy for information about our company's privacy, data collection and data retention policies, and your rights.

Contact Us    About and Terms Of Use    Privacy    Advertising/Endorsements Disclosures