473,385 Members | 1,872 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

how to execute .hta from IE ?

Hi!

I need to read a registry entry(path of a file) from a .htm file. On
doing so it gives an alert "ActiveX maybe harmful..". To avoid this, I
wanted to try a hta file instead. All the files including the htm files
will be used locally & will have nothing to do with the internet.

I was hoping I could have the user just open an htm file, which
executes the hta ( this .hta will in return give the path read from the
registry).

Is there some way this could be done? Any help appreciated!
Thank you.

Jul 10 '06 #1
3 4512
An********@gmail.com said the following on 7/10/2006 2:56 PM:
Hi!

I need to read a registry entry(path of a file) from a .htm file.
No can do in an Internet Environment.
On doing so it gives an alert "ActiveX maybe harmful..".
Yep, as it should.
To avoid this, I wanted to try a hta file instead.
So far so good.
All the files including the htm files will be used locally & will
have nothing to do with the internet.
First time that ActiveX warning comes up, you give it permission and all
is fine.
I was hoping I could have the user just open an htm file, which
executes the hta ( this .hta will in return give the path read from the
registry).
See above, then the .hta isn't needed.

--
Randy
comp.lang.javascript FAQ - http://jibbering.com/faq & newsgroup weekly
Temporarily at: http://members.aol.com/_ht_a/hikksnotathome/cljfaq/
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
Jul 10 '06 #2

An********@gmail.com wrote:
I need to read a registry entry(path of a file) from a .htm file. On
doing so it gives an alert "ActiveX maybe harmful..". To avoid this, I
wanted to try a hta file instead. All the files including the htm files
will be used locally & will have nothing to do with the internet.
Have you tried simply renaming that .htm file to .hta ? A lot of
times, that's all you need to do.

Then you don't have to worry about trying to access .hta info from a
..htm file, which I'm not sure is possible these days anyway. (I just
went through this entire .hta ordeal a few months ago, but have had
major surgery since then and my memory isn't so good ;-)

Cheers, Kev

Jul 10 '06 #3
Thanks Kevin!

the problem is, I have to make a chm file ( which needs some data, for
which i need to read the registry).

I couldn't find a way to include .hta in a chm file. Any idea??
Kevin Darling wrote:
An********@gmail.com wrote:
I need to read a registry entry(path of a file) from a .htm file. On
doing so it gives an alert "ActiveX maybe harmful..". To avoid this, I
wanted to try a hta file instead. All the files including the htm files
will be used locally & will have nothing to do with the internet.

Have you tried simply renaming that .htm file to .hta ? A lot of
times, that's all you need to do.

Then you don't have to worry about trying to access .hta info from a
.htm file, which I'm not sure is possible these days anyway. (I just
went through this entire .hta ordeal a few months ago, but have had
major surgery since then and my memory isn't so good ;-)

Cheers, Kev
Jul 10 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Tim Williams | last post by:
I'm trying to write a simple python program to access a MySQL database. I'm having a problem with using MySQLdb to get the results of a SQL command in a cursor. Sometimes the cursor.execute works,...
2
by: Matt | last post by:
I want to exexute stored procedure in ASP, but it has error "Microsoft VBScript compilation (0x800A0401) Expected end of statement" on line (1). The stored procedure "sp_emp" contain "select *...
7
by: William Gill | last post by:
I have been trying to pass parameters as indicated in the api. when I use: sql= 'select * from %s where cusid = %s ' % name,recID) Cursor.execute(sql) it works fine, but when I try : sql=...
9
by: PyPK | last post by:
Hi if I have a function called tmp=0 def execute(): tmp = tmp+1 return tmp also I have def func1(): execute() ....
5
by: Gustavo Randich | last post by:
Hello, I'm writing an automatic SQL parser and translator from Informix to DB2. Now I'm faced with one of the most difficult things to translate, the "foreach execute procedure" functionality...
2
by: Norman Fritag | last post by:
Hi there The below code executes some queries. As newbie I was wondering weather you are better of using connection execute or command execute to execute queries? I am asking as...
2
by: Dune | last post by:
I'm trying to execute an aspx page by calling Server.Execute. The aspx page I'm trying to execute is in a different web app from the aspx page containing the Server.Execute statement. A slightly...
8
by: johnlichtenstein | last post by:
I am using cx_Oracle and MySQLdb to pull a lot of data from some tables and I find that the cursor.execute method uses a lot of memory that never gets garbage collected. Using fetchmany instead of...
1
by: gglegrp112 | last post by:
Is it possible to send an array as a parameter for an execute method in dbapi2 module? I'm using adodbapi and try to perfrom the following SQL query: select * from item where storeid in ('01',...
9
by: RN1 | last post by:
When a server encounters the line Response.Redirect("abcd.asp") in a ASP script, the server tells the browser that it has to be redirected to another page (which is abcd.asp, in this case)....
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.