473,390 Members | 1,629 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,390 software developers and data experts.

Running File from HTML with Parameters

I have a unique requirement to run an executable file from withing a
HTML document. The HTML is actually embedded in an email sent as a
notification to a user of our application. I need to include a link in
the HTML which launches the application (exe) with command line
parameters.

The Application and users are all within our Intranet - the
application is accessible through a network dirve. I understand to
enable this to happen, a user must select to open file from current
location, and verify they wish to run it - both of which are fine.

I can launch the exe through the following:
<a href="file:\\ServName\Folder\AppName.exe">Launch App Screen XY</a>

However, the email notification will need to specify a start
screen/state, e.g:
<a href="file:\\ServName\Folder\AppName.exe%20X%20Y"> Launch App Screen
XY</a>

This results in a 'Cannot Find Server, Page Cannot be Displayed
Error'. If I cut the EXACT same Address and paste into a new browser,
then the application launches fine, with command line parameters
making it through to the application....So it seems there is nothing
wrong with the URL, but the fact that it is being called from a
hyperlink is causing some problem...

Any Thoughts?
Cheers,
Brad.
Jul 20 '05 #1
4 11001
"Brad Smith" <ch**********@yahoo.com.au> wrote in message
news:43*************************@posting.google.co m...
I can launch the exe through the following:
<a href="file:\\ServName\Folder\AppName.exe">Launch App Screen XY</a>

However, the email notification will need to specify a start
screen/state, e.g:
<a href="file:\\ServName\Folder\AppName.exe%20X%20Y"> Launch App Screen
XY</a>


Try running a batch file instead. When you call the batch file, it won't
require parameters and then the first line of the batch file can call your
application with parameters.

Jonathan
--
http://www.snook.ca/
Jul 20 '05 #2
Had thought of that but the parameters are not static, they are
different for each email notification.

A solution is to have a batch file generated along with the HTML which
has the dynamic parameters, however creating another file isn't the
best solution - I was hoping for something a little cleaner...

"Jonathan Snook" <go***************@snook.ca> wrote in message news:<08**********************@news01.bloor.is.net .cable.rogers.com>...
"Brad Smith" <ch**********@yahoo.com.au> wrote in message
news:43*************************@posting.google.co m...
I can launch the exe through the following:
<a href="file:\\ServName\Folder\AppName.exe">Launch App Screen XY</a>

However, the email notification will need to specify a start
screen/state, e.g:
<a href="file:\\ServName\Folder\AppName.exe%20X%20Y"> Launch App Screen
XY</a>


Try running a batch file instead. When you call the batch file, it won't
require parameters and then the first line of the batch file can call your
application with parameters.

Jonathan

Jul 20 '05 #3
ch**********@yahoo.com.au (Brad Smith) wrote in message news:<43*************************@posting.google.c om>...
I can launch the exe through the following:
<a href="file:\\ServName\Folder\AppName.exe">Launch App Screen XY</a>


That's invalid syntax; you're supposed to use forward slashes in URIs
regardless of the convention in the local operating system. Also, I
don't think it's proper to use LAN hosts after a double slash in a
"file" URI; the correct syntax, I believe, is to have five slashes
before the local host, the first three to indicate that it's in the
local network instead of out on the Internet, and the next two to
indicate a LAN host.
Jul 20 '05 #4
Either way result in the same problem - the parameters not being
passed to the application. IE 5.5 does recognise both formats as being
local.

da*@tobias.name (Daniel R. Tobias) wrote in message news:<aa**************************@posting.google. com>...
ch**********@yahoo.com.au (Brad Smith) wrote in message news:<43*************************@posting.google.c om>...
I can launch the exe through the following:
<a href="file:\\ServName\Folder\AppName.exe">Launch App Screen XY</a>


That's invalid syntax; you're supposed to use forward slashes in URIs
regardless of the convention in the local operating system. Also, I
don't think it's proper to use LAN hosts after a double slash in a
"file" URI; the correct syntax, I believe, is to have five slashes
before the local host, the first three to indicate that it's in the
local network instead of out on the Internet, and the next two to
indicate a LAN host.

Jul 20 '05 #5

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

Similar topics

7
by: Christopher Brandsdal | last post by:
Hi! I have a problem running my code on 2000 server and iis5.0. The code runs perfectly on my localhost (xp iis5.1) but when i run it on 2000 server iis5.0 I get this error: ...
2
by: bbxrider | last post by:
for win2k adv server/iis5.0 trying to run an external program from my asp routine that has multiple parameters, see following set shell = server.createobject("wscript.shell") shell.Run...
11
by: Steve Hoyer | last post by:
I am trying to deploy my first asp.net app to our webserver (2K server, IIS 5) My start page comes up and you can get to the subsequent pages that are tied into our sql server (2K). Each page...
4
by: Tosch | last post by:
If a user starts a second instance of my application I want to pass the specified parameters to a already running instance of the application and the terminate the second instance. I know how to...
12
by: Bill Nguyen | last post by:
What's the VB syntax to run the CR report using the following SP? I use CrystalreportViewer and ReportDocument. Thanks Bill Here's the SP in SQLserver 2K: CREATE proc mysp_ReportSubmission...
3
by: Phil Stanton | last post by:
I have a number of queries which use code for the output of 1 or more fields. For example Address:GetAddress(AddressID, True, 60) Address ID Points to an Address in a table - Address Line1, Line...
1
by: shyaminf | last post by:
hi everybody! iam facing a problem with the transfer of file using servlet programming. i have a code for uploading a file. but i'm unable to execute it using tomcat5.5 server. kindly help me how to...
3
by: pozze | last post by:
Hi, I've just made the change from ASP to .net. I have a file (code below) that saves a user submitted file to a MS SQL 2005 database. It collects the file name, file size, file type, and lastly...
1
by: =?Utf-8?B?Q2lhcmFuIE8nJ0Rvbm5lbGw=?= | last post by:
On reflection, you could possibly make the app a self extracting zip file which extracts the EXE and a settings file and then starts the app, then when you app closes, it can repack the settings...
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: 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
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
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.