472,792 Members | 4,610 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

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

ASP.NET Button and VB.NET Windows Form EXE

I am using the following command to launch and .NET VB Executable, which is
a simple Windows Form (printCheckClient.exe). I am using a HyperLink Control
and works perfect.
hlPrintChecks.NavigateUrl = "javascript:var newWindow
=window.open('printCheckClient.exe',
1,'height=350,width=350,menubar=no,status=no,toolb ar=no')"

I want to use a standard ASP.NET Button, but not sure what method to use. Is
there a way to accomplish this. I may not need to use the javascript and
open in a new window, or is there a way to launch the .exe directly from the
button. The .exe is located on the web server.

TIA,

Steve Wofford
www.IntraRELY.com
Nov 18 '05 #1
7 2765
you can point to it but you can't have it lauch automatically. Best you will
get it either
1) prompt the user
2) run in the background on the server, but it's not interactive to the
client (ie: a service process on the server)

--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com
"IntraRELY" <In*******@yahoo.com> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
I am using the following command to launch and .NET VB Executable, which is a simple Windows Form (printCheckClient.exe). I am using a HyperLink Control and works perfect.
hlPrintChecks.NavigateUrl = "javascript:var newWindow
=window.open('printCheckClient.exe',
1,'height=350,width=350,menubar=no,status=no,toolb ar=no')"

I want to use a standard ASP.NET Button, but not sure what method to use. Is there a way to accomplish this. I may not need to use the javascript and
open in a new window, or is there a way to launch the .exe directly from the button. The .exe is located on the web server.

TIA,

Steve Wofford
www.IntraRELY.com

Nov 18 '05 #2
Sorry, but I am not sure what you are saying. If I can point it to the exe
how would I do that.?

Steve

"Curt_C [MVP]" <software_AT_darkfalz.com> wrote in message
news:OX**************@TK2MSFTNGP11.phx.gbl...
you can point to it but you can't have it lauch automatically. Best you will get it either
1) prompt the user
2) run in the background on the server, but it's not interactive to the
client (ie: a service process on the server)

--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com
"IntraRELY" <In*******@yahoo.com> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
I am using the following command to launch and .NET VB Executable, which is
a simple Windows Form (printCheckClient.exe). I am using a HyperLink

Control
and works perfect.
hlPrintChecks.NavigateUrl = "javascript:var newWindow
=window.open('printCheckClient.exe',
1,'height=350,width=350,menubar=no,status=no,toolb ar=no')"

I want to use a standard ASP.NET Button, but not sure what method to

use. Is
there a way to accomplish this. I may not need to use the javascript and
open in a new window, or is there a way to launch the .exe directly from

the
button. The .exe is located on the web server.

TIA,

Steve Wofford
www.IntraRELY.com


Nov 18 '05 #3
like this...
http://server/dir/file.exe

that's what I meant.

--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com
"IntraRELY" <In*******@yahoo.com> wrote in message
news:uD******************@TK2MSFTNGP11.phx.gbl...
Sorry, but I am not sure what you are saying. If I can point it to the exe how would I do that.?

Steve

"Curt_C [MVP]" <software_AT_darkfalz.com> wrote in message
news:OX**************@TK2MSFTNGP11.phx.gbl...
you can point to it but you can't have it lauch automatically. Best you

will
get it either
1) prompt the user
2) run in the background on the server, but it's not interactive to the
client (ie: a service process on the server)

--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com
"IntraRELY" <In*******@yahoo.com> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
I am using the following command to launch and .NET VB Executable, which
is
a simple Windows Form (printCheckClient.exe). I am using a HyperLink

Control
and works perfect.
hlPrintChecks.NavigateUrl = "javascript:var newWindow
=window.open('printCheckClient.exe',
1,'height=350,width=350,menubar=no,status=no,toolb ar=no')"

I want to use a standard ASP.NET Button, but not sure what method to use.
Is
there a way to accomplish this. I may not need to use the javascript

and open in a new window, or is there a way to launch the .exe directly

from the
button. The .exe is located on the web server.

TIA,

Steve Wofford
www.IntraRELY.com



Nov 18 '05 #4
Hi Steve,

You asked if there is a more direct way to launch your EXE. Curt's reply is
your answer. I'd like to expand on that answer.

You currently use an <a> tag to run javascript code to open a new window.
You could instead set the <a> tag's HREF to the EXE itself. Then EXE will
run on the client machine with no additional window and no javascript.

Whenever you launch an EXE in a user's browser, the browser will first
prompt the user if they want to allow the program to run. This will apply
if you launch the program in the same window or if you use window.open to
open a new window.

When using window.open, you can specify attributes for the window. Your
sample specifies 'height=350,width=350,menubar=no,status=no,toolbar =no'.
When pointing an <a> tag's HREF directly to the EXE, you cannot specify
window attributes.

* Your current method:
<a href="javascript:var newWindow=window.open('printCheckClient.exe',
1,'height=350,width=350,menubar=no,status=no,toolb ar=no')">test</a>

* Pointing the <a> tag directly to the EXE:
<a href="printCheckClient.exe">test</a>

* You also asked about using a button:
<script language=javascript>
function Button1_Click() {
var newWindow=window.open('printCheckClient.exe',
1,'height=350,width=350,menubar=no,status=no,toolb ar=no');
}
</script>
<INPUT type=button id="Button1" name="Button1" onclick="Button1_Click();"
value="test" />

---
Though the above button sample gets the job done, you asked about using an
ASP.NET button. This gets more complicated. I recommend using an HTML
button rather than an ASP.NET button.

First off, the ASP.NET button is really meant to submit the form. If you
add code to its onclick event, that will be executed and then the form will
be submitted. You can avoid the form submission by having your client
script function return false. For IE browsers, you can also add a line of
code to your onclick event which sets event.returnValue=false;.

Second, if your page also has ASP.NET validation controls, and the button
is set to cause validation, then it gets much more complex. The validation
controls override your onclick event with their own. You can view several
workarounds at http://authors.aspalliance.com/kenc/faq6.aspx.

---
You might also be interested in attributes.add. This allows you to use
server-side code to add the onclick attribute to the button. This applies
to ASP.NET buttons and to HTML buttons if they are set with runat="server".
See:

Code: Setting HTML Attributes for Controls in Web Forms Pages (Visual Basic)
http://msdn.microsoft.com/library/en...desettinghtmla
ttributesforcontrolsinwebformspagesvisualbasic.asp

You can also use server-side code to generate the script executed by the
onclick event. See:

Page.RegisterClientScriptBlock Method
http://msdn.microsoft.com/library/en...webuipageclass
registerclientscriptblocktopic.asp

---
Does this answer your question?

Thank you, Mike
Microsoft, ASP.NET Support Professional

Microsoft highly recommends to all of our customers that they visit the
http://www.microsoft.com/protect site and perform the three straightforward
steps listed to improve your computer's security.

This posting is provided "AS IS", with no warranties, and confers no rights.

--------------------
From: "Curt_C [MVP]" <software_AT_darkfalz.com>
References: <#9**************@tk2msftngp13.phx.gbl> <OX**************@TK2MSFTNGP11.phx.gbl>
<uD**************@TK2MSFTNGP11.phx.gbl> Subject: Re: ASP.NET Button and VB.NET Windows Form EXE
Date: Wed, 14 Jan 2004 14:37:55 -0600
Lines: 68
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
Message-ID: <es**************@TK2MSFTNGP10.phx.gbl>
Newsgroups: microsoft.public.dotnet.framework.aspnet
NNTP-Posting-Host: 208.252.151.83
Path: cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFTN GXS01.phx.gbl!TK2MSFTNGXA0
5.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP10.phx.gb l Xref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.framework.aspnet:202228
X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet

like this...
http://server/dir/file.exe

that's what I meant.

--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com
"IntraRELY" <In*******@yahoo.com> wrote in message
news:uD******************@TK2MSFTNGP11.phx.gbl...
Sorry, but I am not sure what you are saying. If I can point it to the

exe
how would I do that.?

Steve

"Curt_C [MVP]" <software_AT_darkfalz.com> wrote in message
news:OX**************@TK2MSFTNGP11.phx.gbl...
you can point to it but you can't have it lauch automatically. Best you
will
get it either
1) prompt the user
2) run in the background on the server, but it's not interactive to
the client (ie: a service process on the server)

--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com
"IntraRELY" <In*******@yahoo.com> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
> I am using the following command to launch and .NET VB Executable,

which is
> a simple Windows Form (printCheckClient.exe). I am using a HyperLink
Control
> and works perfect.
> hlPrintChecks.NavigateUrl = "javascript:var newWindow
> =window.open('printCheckClient.exe',
> 1,'height=350,width=350,menubar=no,status=no,toolb ar=no')"
>
> I want to use a standard ASP.NET Button, but not sure what method to

use.
Is
> there a way to accomplish this. I may not need to use the javascript and > open in a new window, or is there a way to launch the .exe directly from the
> button. The .exe is located on the web server.
>
> TIA,
>
> Steve Wofford
> www.IntraRELY.com
>
>




Nov 18 '05 #5
Hi Steve,

You asked if there is a more direct way to launch your EXE. Curt's reply is
your answer. I'd like to expand on that answer.

You currently use an <a> tag to run javascript code to open a new window.
You could instead set the <a> tag's HREF to the EXE itself. Then EXE will
run on the client machine with no additional window and no javascript.

Whenever you launch an EXE in a user's browser, the browser will first
prompt the user if they want to allow the program to run. This will apply
if you launch the program in the same window or if you use window.open to
open a new window.

When using window.open, you can specify attributes for the window. Your
sample specifies 'height=350,width=350,menubar=no,status=no,toolbar =no'.
When pointing an <a> tag's HREF directly to the EXE, you cannot specify
window attributes.

* Your current method:
<a href="javascript:var newWindow=window.open('printCheckClient.exe',
1,'height=350,width=350,menubar=no,status=no,toolb ar=no')">test</a>

* Pointing the <a> tag directly to the EXE:
<a href="printCheckClient.exe">test</a>

* You also asked about using a button:
<script language=javascript>
function Button1_Click() {
var newWindow=window.open('printCheckClient.exe',
1,'height=350,width=350,menubar=no,status=no,toolb ar=no');
}
</script>
<INPUT type=button id="Button1" name="Button1" onclick="Button1_Click();"
value="test" />

---
Though the above button sample gets the job done, you asked about using an
ASP.NET button. This gets more complicated. I recommend using an HTML
button rather than an ASP.NET button.

First off, the ASP.NET button is really meant to submit the form. If you
add code to its onclick event, that will be executed and then the form will
be submitted. You can avoid the form submission by having your client
script function return false. For IE browsers, you can also add a line of
code to your onclick event which sets event.returnValue=false;.

Second, if your page also has ASP.NET validation controls, and the button
is set to cause validation, then it gets much more complex. The validation
controls override your onclick event with their own. You can view several
workarounds at http://authors.aspalliance.com/kenc/faq6.aspx.

---
You might also be interested in attributes.add. This allows you to use
server-side code to add the onclick attribute to the button. This applies
to ASP.NET buttons and to HTML buttons if they are set with runat="server".
See:

Code: Setting HTML Attributes for Controls in Web Forms Pages (Visual Basic)
http://msdn.microsoft.com/library/en...desettinghtmla
ttributesforcontrolsinwebformspagesvisualbasic.asp

You can also use server-side code to generate the script executed by the
onclick event. See:

Page.RegisterClientScriptBlock Method
http://msdn.microsoft.com/library/en...webuipageclass
registerclientscriptblocktopic.asp

---
Does this answer your question?

Thank you, Mike
Microsoft, ASP.NET Support Professional

Microsoft highly recommends to all of our customers that they visit the
http://www.microsoft.com/protect site and perform the three straightforward
steps listed to improve your computer's security.

This posting is provided "AS IS", with no warranties, and confers no rights.

--------------------
From: "Curt_C [MVP]" <software_AT_darkfalz.com>
References: <#9**************@tk2msftngp13.phx.gbl> <OX**************@TK2MSFTNGP11.phx.gbl>
<uD**************@TK2MSFTNGP11.phx.gbl> Subject: Re: ASP.NET Button and VB.NET Windows Form EXE
Date: Wed, 14 Jan 2004 14:37:55 -0600
Lines: 68
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
Message-ID: <es**************@TK2MSFTNGP10.phx.gbl>
Newsgroups: microsoft.public.dotnet.framework.aspnet
NNTP-Posting-Host: 208.252.151.83
Path: cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFTN GXS01.phx.gbl!TK2MSFTNGXA0
5.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP10.phx.gb l Xref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.framework.aspnet:202228
X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet

like this...
http://server/dir/file.exe

that's what I meant.

--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com
"IntraRELY" <In*******@yahoo.com> wrote in message
news:uD******************@TK2MSFTNGP11.phx.gbl...
Sorry, but I am not sure what you are saying. If I can point it to the

exe
how would I do that.?

Steve

"Curt_C [MVP]" <software_AT_darkfalz.com> wrote in message
news:OX**************@TK2MSFTNGP11.phx.gbl...
you can point to it but you can't have it lauch automatically. Best you
will
get it either
1) prompt the user
2) run in the background on the server, but it's not interactive to
the client (ie: a service process on the server)

--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com
"IntraRELY" <In*******@yahoo.com> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
> I am using the following command to launch and .NET VB Executable,

which is
> a simple Windows Form (printCheckClient.exe). I am using a HyperLink
Control
> and works perfect.
> hlPrintChecks.NavigateUrl = "javascript:var newWindow
> =window.open('printCheckClient.exe',
> 1,'height=350,width=350,menubar=no,status=no,toolb ar=no')"
>
> I want to use a standard ASP.NET Button, but not sure what method to

use.
Is
> there a way to accomplish this. I may not need to use the javascript and > open in a new window, or is there a way to launch the .exe directly from the
> button. The .exe is located on the web server.
>
> TIA,
>
> Steve Wofford
> www.IntraRELY.com
>
>




Nov 18 '05 #6
Mike,

Great Information...Thanks!

There are really 1 reason why I need an ASP.NET button and is becuase when
clicked the button removes records from a dataGrid and has to redraw the
grid with the correct paging. There is also updates sent to the database. I
looks pretty complicated to move away from the ASP.NET Button. There is no
validataion on the page so there is no problem there. It looks easy enough
to attach some javascript to the button and put it at the end of my routine.

Thanks again to all who posted, but Mike you went out of your way...THANKS.

Steve Wofford
www.IntraRELY.com

""Mike Moore [MSFT]"" <mi****@online.microsoft.com> wrote in message
news:Iw**************@cpmsftngxa07.phx.gbl...
Hi Steve,

You asked if there is a more direct way to launch your EXE. Curt's reply is your answer. I'd like to expand on that answer.

You currently use an <a> tag to run javascript code to open a new window.
You could instead set the <a> tag's HREF to the EXE itself. Then EXE will
run on the client machine with no additional window and no javascript.

Whenever you launch an EXE in a user's browser, the browser will first
prompt the user if they want to allow the program to run. This will apply
if you launch the program in the same window or if you use window.open to
open a new window.

When using window.open, you can specify attributes for the window. Your
sample specifies 'height=350,width=350,menubar=no,status=no,toolbar =no'.
When pointing an <a> tag's HREF directly to the EXE, you cannot specify
window attributes.

* Your current method:
<a href="javascript:var newWindow=window.open('printCheckClient.exe',
1,'height=350,width=350,menubar=no,status=no,toolb ar=no')">test</a>

* Pointing the <a> tag directly to the EXE:
<a href="printCheckClient.exe">test</a>

* You also asked about using a button:
<script language=javascript>
function Button1_Click() {
var newWindow=window.open('printCheckClient.exe',
1,'height=350,width=350,menubar=no,status=no,toolb ar=no');
}
</script>
<INPUT type=button id="Button1" name="Button1" onclick="Button1_Click();"
value="test" />

---
Though the above button sample gets the job done, you asked about using an
ASP.NET button. This gets more complicated. I recommend using an HTML
button rather than an ASP.NET button.

First off, the ASP.NET button is really meant to submit the form. If you
add code to its onclick event, that will be executed and then the form will be submitted. You can avoid the form submission by having your client
script function return false. For IE browsers, you can also add a line of
code to your onclick event which sets event.returnValue=false;.

Second, if your page also has ASP.NET validation controls, and the button
is set to cause validation, then it gets much more complex. The validation
controls override your onclick event with their own. You can view several
workarounds at http://authors.aspalliance.com/kenc/faq6.aspx.

---
You might also be interested in attributes.add. This allows you to use
server-side code to add the onclick attribute to the button. This applies
to ASP.NET buttons and to HTML buttons if they are set with runat="server". See:

Code: Setting HTML Attributes for Controls in Web Forms Pages (Visual Basic) http://msdn.microsoft.com/library/en...desettinghtmla ttributesforcontrolsinwebformspagesvisualbasic.asp

You can also use server-side code to generate the script executed by the
onclick event. See:

Page.RegisterClientScriptBlock Method
http://msdn.microsoft.com/library/en...webuipageclass registerclientscriptblocktopic.asp

---
Does this answer your question?

Thank you, Mike
Microsoft, ASP.NET Support Professional

Microsoft highly recommends to all of our customers that they visit the
http://www.microsoft.com/protect site and perform the three straightforward steps listed to improve your computer's security.

This posting is provided "AS IS", with no warranties, and confers no rights.
--------------------
From: "Curt_C [MVP]" <software_AT_darkfalz.com>
References: <#9**************@tk2msftngp13.phx.gbl> <OX**************@TK2MSFTNGP11.phx.gbl>
<uD**************@TK2MSFTNGP11.phx.gbl>
Subject: Re: ASP.NET Button and VB.NET Windows Form EXE
Date: Wed, 14 Jan 2004 14:37:55 -0600
Lines: 68
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
Message-ID: <es**************@TK2MSFTNGP10.phx.gbl>
Newsgroups: microsoft.public.dotnet.framework.aspnet
NNTP-Posting-Host: 208.252.151.83
Path:

cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFTN GXS01.phx.gbl!TK2MSFTNGXA0 5.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP10.phx.gb l
Xref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.framework.aspnet:202228
X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet

like this...
http://server/dir/file.exe

that's what I meant.

--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com
"IntraRELY" <In*******@yahoo.com> wrote in message
news:uD******************@TK2MSFTNGP11.phx.gbl...
Sorry, but I am not sure what you are saying. If I can point it to the
exe
how would I do that.?

Steve

"Curt_C [MVP]" <software_AT_darkfalz.com> wrote in message
news:OX**************@TK2MSFTNGP11.phx.gbl...
> you can point to it but you can't have it lauch automatically. Best you will
> get it either
> 1) prompt the user
> 2) run in the background on the server, but it's not interactive to the > client (ie: a service process on the server)
>
> --
> Curt Christianson
> Owner/Lead Developer, DF-Software
> www.Darkfalz.com
>
>
> "IntraRELY" <In*******@yahoo.com> wrote in message
> news:%2****************@tk2msftngp13.phx.gbl...
> > I am using the following command to launch and .NET VB Executable,

which
> is
> > a simple Windows Form (printCheckClient.exe). I am using a

HyperLink > Control
> > and works perfect.
> > hlPrintChecks.NavigateUrl = "javascript:var newWindow
> > =window.open('printCheckClient.exe',
> > 1,'height=350,width=350,menubar=no,status=no,toolb ar=no')"
> >
> > I want to use a standard ASP.NET Button, but not sure what method to use.
> Is
> > there a way to accomplish this. I may not need to use the

javascript and
> > open in a new window, or is there a way to launch the .exe
directly from
> the
> > button. The .exe is located on the web server.
> >
> > TIA,
> >
> > Steve Wofford
> > www.IntraRELY.com
> >
> >
>
>


Nov 18 '05 #7
Mike,

Great Information...Thanks!

There are really 1 reason why I need an ASP.NET button and is becuase when
clicked the button removes records from a dataGrid and has to redraw the
grid with the correct paging. There is also updates sent to the database. I
looks pretty complicated to move away from the ASP.NET Button. There is no
validataion on the page so there is no problem there. It looks easy enough
to attach some javascript to the button and put it at the end of my routine.

Thanks again to all who posted, but Mike you went out of your way...THANKS.

Steve Wofford
www.IntraRELY.com

""Mike Moore [MSFT]"" <mi****@online.microsoft.com> wrote in message
news:Iw**************@cpmsftngxa07.phx.gbl...
Hi Steve,

You asked if there is a more direct way to launch your EXE. Curt's reply is your answer. I'd like to expand on that answer.

You currently use an <a> tag to run javascript code to open a new window.
You could instead set the <a> tag's HREF to the EXE itself. Then EXE will
run on the client machine with no additional window and no javascript.

Whenever you launch an EXE in a user's browser, the browser will first
prompt the user if they want to allow the program to run. This will apply
if you launch the program in the same window or if you use window.open to
open a new window.

When using window.open, you can specify attributes for the window. Your
sample specifies 'height=350,width=350,menubar=no,status=no,toolbar =no'.
When pointing an <a> tag's HREF directly to the EXE, you cannot specify
window attributes.

* Your current method:
<a href="javascript:var newWindow=window.open('printCheckClient.exe',
1,'height=350,width=350,menubar=no,status=no,toolb ar=no')">test</a>

* Pointing the <a> tag directly to the EXE:
<a href="printCheckClient.exe">test</a>

* You also asked about using a button:
<script language=javascript>
function Button1_Click() {
var newWindow=window.open('printCheckClient.exe',
1,'height=350,width=350,menubar=no,status=no,toolb ar=no');
}
</script>
<INPUT type=button id="Button1" name="Button1" onclick="Button1_Click();"
value="test" />

---
Though the above button sample gets the job done, you asked about using an
ASP.NET button. This gets more complicated. I recommend using an HTML
button rather than an ASP.NET button.

First off, the ASP.NET button is really meant to submit the form. If you
add code to its onclick event, that will be executed and then the form will be submitted. You can avoid the form submission by having your client
script function return false. For IE browsers, you can also add a line of
code to your onclick event which sets event.returnValue=false;.

Second, if your page also has ASP.NET validation controls, and the button
is set to cause validation, then it gets much more complex. The validation
controls override your onclick event with their own. You can view several
workarounds at http://authors.aspalliance.com/kenc/faq6.aspx.

---
You might also be interested in attributes.add. This allows you to use
server-side code to add the onclick attribute to the button. This applies
to ASP.NET buttons and to HTML buttons if they are set with runat="server". See:

Code: Setting HTML Attributes for Controls in Web Forms Pages (Visual Basic) http://msdn.microsoft.com/library/en...desettinghtmla ttributesforcontrolsinwebformspagesvisualbasic.asp

You can also use server-side code to generate the script executed by the
onclick event. See:

Page.RegisterClientScriptBlock Method
http://msdn.microsoft.com/library/en...webuipageclass registerclientscriptblocktopic.asp

---
Does this answer your question?

Thank you, Mike
Microsoft, ASP.NET Support Professional

Microsoft highly recommends to all of our customers that they visit the
http://www.microsoft.com/protect site and perform the three straightforward steps listed to improve your computer's security.

This posting is provided "AS IS", with no warranties, and confers no rights.
--------------------
From: "Curt_C [MVP]" <software_AT_darkfalz.com>
References: <#9**************@tk2msftngp13.phx.gbl> <OX**************@TK2MSFTNGP11.phx.gbl>
<uD**************@TK2MSFTNGP11.phx.gbl>
Subject: Re: ASP.NET Button and VB.NET Windows Form EXE
Date: Wed, 14 Jan 2004 14:37:55 -0600
Lines: 68
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
Message-ID: <es**************@TK2MSFTNGP10.phx.gbl>
Newsgroups: microsoft.public.dotnet.framework.aspnet
NNTP-Posting-Host: 208.252.151.83
Path:

cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFTN GXS01.phx.gbl!TK2MSFTNGXA0 5.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP10.phx.gb l
Xref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.framework.aspnet:202228
X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet

like this...
http://server/dir/file.exe

that's what I meant.

--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com
"IntraRELY" <In*******@yahoo.com> wrote in message
news:uD******************@TK2MSFTNGP11.phx.gbl...
Sorry, but I am not sure what you are saying. If I can point it to the
exe
how would I do that.?

Steve

"Curt_C [MVP]" <software_AT_darkfalz.com> wrote in message
news:OX**************@TK2MSFTNGP11.phx.gbl...
> you can point to it but you can't have it lauch automatically. Best you will
> get it either
> 1) prompt the user
> 2) run in the background on the server, but it's not interactive to the > client (ie: a service process on the server)
>
> --
> Curt Christianson
> Owner/Lead Developer, DF-Software
> www.Darkfalz.com
>
>
> "IntraRELY" <In*******@yahoo.com> wrote in message
> news:%2****************@tk2msftngp13.phx.gbl...
> > I am using the following command to launch and .NET VB Executable,

which
> is
> > a simple Windows Form (printCheckClient.exe). I am using a

HyperLink > Control
> > and works perfect.
> > hlPrintChecks.NavigateUrl = "javascript:var newWindow
> > =window.open('printCheckClient.exe',
> > 1,'height=350,width=350,menubar=no,status=no,toolb ar=no')"
> >
> > I want to use a standard ASP.NET Button, but not sure what method to use.
> Is
> > there a way to accomplish this. I may not need to use the

javascript and
> > open in a new window, or is there a way to launch the .exe
directly from
> the
> > button. The .exe is located on the web server.
> >
> > TIA,
> >
> > Steve Wofford
> > www.IntraRELY.com
> >
> >
>
>


Nov 18 '05 #8

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

Similar topics

5
by: RAJ | last post by:
hi plz tell me how to know "how window is going to close"... i have to right code for X button of forms... plz telll me thanks bye
1
by: Mullin Yu | last post by:
I want to create a C# GUI application that will start a new console application, e.g. console.exe when clicking a button. Then, if click a button, it will kill a specific console application. Am...
4
by: Arif Çimen | last post by:
Hi to everybody, I have chnged a button text in design mode. But After compiling and executing the program the text of the button do not change to new value. Any Ideas? Thaks for helps.
4
by: Dmitry Korolyov [MVP] | last post by:
When we use btnSubmit.Attributes = "javascript: this.disabled=true;" to make the button disabled and prevent users from clicking it again while form data still posting, there is no longer...
18
by: Colin McGuire | last post by:
Hi - this was posted last weekend and unfortunately not resolved. The solutions that were posted almost worked but after another 5 days of working on the code everynight, I am not further ahead....
3
by: Neil Wallace | last post by:
Hi, This is an odd one. I've been struggling to get "double click" to work well for my controls. The same event handler works perfectly for buttons, but not for labels. Can anyone tell me...
5
by: Wonder | last post by:
How can I create or use the msgobx to show a message without a default button. The user has explicity to click on the button, so the msgbox closes it. Thanks,
14
by: Kevin | last post by:
A couple of easy questions here hopefully. I've been working on two different database projects which make use of multiple forms. 1. Where's the best/recommended placement for command buttons...
7
by: Marcolino | last post by:
Hi all, I need to add a custom button to title bar on a form in addition of a standard button. (Minimize/Maximize, close etc.) I need also to handle OnClick event of this button. I looked around...
3
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 2 August 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
0
by: erikbower65 | last post by:
Using CodiumAI's pr-agent is simple and powerful. Follow these steps: 1. Install CodiumAI CLI: Ensure Node.js is installed, then run 'npm install -g codiumai' in the terminal. 2. Connect to...
0
by: kcodez | last post by:
As a H5 game development enthusiast, I recently wrote a very interesting little game - Toy Claw ((http://claw.kjeek.com/))。Here I will summarize and share the development experience here, and hope it...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Sept 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
0
by: Taofi | last post by:
I try to insert a new record but the error message says the number of query names and destination fields are not the same This are my field names ID, Budgeted, Actual, Status and Differences ...
5
by: DJRhino | last post by:
Private Sub CboDrawingID_BeforeUpdate(Cancel As Integer) If = 310029923 Or 310030138 Or 310030152 Or 310030346 Or 310030348 Or _ 310030356 Or 310030359 Or 310030362 Or...
0
by: lllomh | last post by:
Define the method first this.state = { buttonBackgroundColor: 'green', isBlinking: false, // A new status is added to identify whether the button is blinking or not } autoStart=()=>{
0
by: lllomh | last post by:
How does React native implement an English player?
2
by: DJRhino | last post by:
Was curious if anyone else was having this same issue or not.... I was just Up/Down graded to windows 11 and now my access combo boxes are not acting right. With win 10 I could start typing...

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.