|
How do I execute an application from ASP.net?
For instance, I have a web app on my server. When I visit it at http://localhost/default.aspx and click on a button, I want notepad to pop up or some other program. I've tried:
Process commandPrompt = Process.Start("notepad.exe");
which does run notepad, but it's not visible.
Any ideas?
Thanks
|
|
|
|
|
friendlyghost wrote:
For instance, I have a web app on my server. When I visit it at http://localhost/default.aspx and click on a button, I want notepad to pop up or some other program. I've tried:
Process commandPrompt = Process.Start("notepad.exe");
which does run notepad, but it's not visible.
(We need an FAQ for this question!)
Casper, you need to first understand the client/server model that the web uses.
The ASP.NET code (the C#, VB.NET etc. in the ASPX and code behind) is run on the server side, not the client side.
So when you execute a Process.Start command it is being executed on the server, not the client. No execute commands are being sent back along over TCP/IP to the client browser.
Also what you are wanting to do is quite dangerous. If web pages can start firing off Process.Start commands on the client side then security is shot to hell. You could fire off a format c:\ /q if that was the case... Not good.
What you can do, I think, is use an ActiveX component embedded in the page which starts off the process on the client side. Not sure of the details, but that is how you would do it. Look up how to run C# on the client side which can be done, but which requires the client to have the .NET Framework installed.
Paul Watson Bluegrass Cape Town, South Africa Ray Cassick wrote: Well I am not female, not gay and I am not Paul Watson
|
|
|
|
|
If anyone is interested, here are two very handy Favelets.
Zoom In
Zoom Out
Basically they give Internet Explorer the same text zooming features as Mozilla. It works on sites that even set rigid font-sizes (like CP.)
Just drag those two links onto your IE link bar and say Yes to the warnings (but no to drugs.)
Then whenever you need to zoom in or out, just click the links!
I got these favelets from Yourhtmlsource.com[^] and this post follows on from a rant I had with Shog9.
Enjoy!
Paul Watson Bluegrass Cape Town, South Africa Ray Cassick wrote: Well I am not female, not gay and I am not Paul Watson
|
|
|
|
|
That is really terrific.
Albeit the fact that Zoom-in/Zoom-out option exists for Images as part of IE Power Toys, a simple JavaScript trick is able to do this trick of Zooming In/Zooming Out of Text.
That's great!!!
Deepak
Deepak Kumar Vasudevan
http://deepak.portland.co.uk/
|
|
|
|
|
Can anyone gimme a few links where I can start learning about iframe.
Thanks in advance........
|
|
|
|
|
|
|
|
|
We have a form that we do not want to submit until validation has already been performed. Our question is - can we call a dll either using VBScript or Javascript from a button. We need to create the instance of the object at this point, and then the public function. This way if there is a problem with the data the form is still on the screen, and has not been submitted yet.
Does anyone have any experience of this? Thankyou
|
|
|
|
|
Prepare an ActiveX control, for instance named validator. Embed this ActiveX in your web page using the <object tag. Then, whenever you need to call exposed methods with javascript or vbscript code, call methods with prototypes of the form validator_methodname(params).
You'll find easily more info on that, just googleup with the "_onclick" keyword.
Back to real work : D-23.
|
|
|
|
|
Thank you very much S.Rod for your prompt reply. I am considering object method some thing like:
<object id="chtTest" width="248" height="192
" classid="CLSID:FC25B780-75BE-11CF-8B01-444553540000">
<param name="_ExtentX" value="6562" />
<param name="_ExtentY" value="5080" />
<param name="Rows" value="4" />
<param name="Columns" value="3" />
<param name="ChartType" value="1" />
<param name="Data[0][0]" value="9" />
<param name="Data[0][1]" value="10" />
<param name="Data[0][2]" value="11" />
<param name="Data[1][0]" value="7" />
<param name="Data[1][1]" value="11" />
<param name="Data[1][2]" value="12" />
<param name="Data[2][0]" value="6" />
<param name="Data[2][1]" value="12" />
<param name="Data[2][2]" value="13" />
<param name="Data[3][0]" value="11" />
<param name="Data[3][1]" value="13" />
<param name="Data[3][2]" value="14" />
<param name="HorizontalAxis" value="0" />
<param name="VerticalAxis" value="0" />
<param name="hgridStyle" value="0" />
<param name="vgridStyle" value="0" />
<param name="ColorScheme" value="0" />
<param name="BackStyle" value="1" />
<param name="Scale" value="100" />
<param name="DisplayLegend" value="0" />
<param name="BackColor" value="16777215" />
<param name="ForeColor" value="32768" />
Wish me luck .
Thank you again
|
|
|
|
|
OK, so I know I have mentioned before that I am going to start doing some HTML and DHTML. I now pretty much have the new machine installed the way I want so I will be honest.
I want to do some of that DOM stuff where I support multiple browsers so my question is...
Should I used Netscape or Mozilla and which version of them?
Michael Martin
Australia
mjm68@tpg.com.au
"I personally love it because I can get as down and dirty as I want on the backend, while also being able to dabble with fun scripting and presentation games on the front end."
- Chris Maunder 15/07/2002
|
|
|
|
|
Michael Martin wrote:
Should I used Netscape or Mozilla and which version of them?
Netscape 6 and up (6.1, 6.2, 7 and coming 8) all use Mozilla as it's base. So to a 99% degree you need not worry. i.e. The HTML, CSS and JavaScript will all render and function the same in these two browsers because the engines are the same (there are some differences but so minor you probably won't ever run into them.)
Anything before Nestcape 6 though is a totally different story of course. Avoid Netscape 4.x like you avoid your mother in law. i.e. like the plague.
As for which version of Mozilla, go with 1.0.
Paul Watson Bluegrass Cape Town, South Africa Ray Cassick wrote: Well I am not female, not gay and I am not Paul Watson
|
|
|
|
|
Thanks for the response Paul. I am currently downloading Mozilla 1.0.1 and will follow that up with 1.1. Decided against touching 1.2 as that is Beta.
I have Netscape 7 on a CD from a magazine though I will check their website to see if there is a newer version available.
I you were a wannabe web developer like me and had the choice of Mozilla and Netscape which one would you install to use along side Internet Explorer 6 SP1?
Michael Martin
Australia
mjm68@tpg.com.au
"I personally love it because I can get as down and dirty as I want on the backend, while also being able to dabble with fun scripting and presentation games on the front end."
- Chris Maunder 15/07/2002
|
|
|
|
|
Michael Martin wrote:
I you were a wannabe web developer like me and had the choice of Mozilla and Netscape which one would you install to use along side Internet Explorer 6 SP1?
Mozilla 1.0
But if you were looking into real world, practical web development then you should seriously get as many browsers as you can. I have 6 versions of Netscape 4, 4 versions of Internet Explorer, 3 versions of Mozilla, 2 versions of Opera, Netscape 6 and Netscape 7 plus three AOL versions. Plus I now have that Phoenix browser, and I had Knoqueror but not once in 5 years has any client moaned that their site looks funny on Konqueror (only because they never heard of it.)
Then we have the Mac in the corner with all it's browsers (F5 to F15 all are hot keyed to a different browser)
Paul Watson Bluegrass Cape Town, South Africa Ray Cassick wrote: Well I am not female, not gay and I am not Paul Watson
|
|
|
|
|
Paul Watson wrote:
4 versions of Internet Explorer
Jeesh.
How did you manage to install them on one machine?
Cheers,
Simon
"VB.NET ... the STD of choice", me, internal company memo
|
|
|
|
|
SimonS wrote:
How did you manage to install them on one machine?
Hapinness is VMWare
That app rocks! I have got all Windows OS versions installed and alt-tabbing between them is just wonderful.
Paul Watson Bluegrass Cape Town, South Africa Ray Cassick wrote: Well I am not female, not gay and I am not Paul Watson
|
|
|
|
|
Paul Watson wrote:
Mozilla 1.0
Anything in particular wrong with Mozilla 1.1?
Michael Martin
Australia
mjm68@tpg.com.au
"I personally love it because I can get as down and dirty as I want on the backend, while also being able to dabble with fun scripting and presentation games on the front end."
- Chris Maunder 15/07/2002
|
|
|
|
|
Michael Martin wrote:
Anything in particular wrong with Mozilla 1.1?
Oh no, obviously it is better than Mozilla 1.0
The thing though is Mozilla 1.0 is the more widely used of the versions and is closer to Netscape 6. So when doing cross-browser testing it is better to check Mozilla 1.0 than go with Mozilla 1.1.
Get both if you are serious
Paul Watson Bluegrass Cape Town, South Africa Ray Cassick wrote: Well I am not female, not gay and I am not Paul Watson
|
|
|
|
|
Paul Watson wrote:
The thing though is Mozilla 1.0 is the more widely used of the versions and is closer to Netscape 6. So when doing cross-browser testing it is better to check Mozilla 1.0 than go with Mozilla 1.1.
Truth be told I think I really just want to get a grip on the whole DHTML thing I was reading about in that handbook (which I finally finished by the way). I didn't get his explanations on tables, have no real grasp of the DOM (and the differences between how it works with different browsers) and also a lot of the techniques for formatting and making pop-up thingies (sorry to get all technical on you there).
I don't think I will ever become a web guru (though won't stop myself if I do) but I have been in such a rut lately I need to get out of it. I haven't looked at anything technical for probably over 6 months.
I plan to do some (D)HTML as I hate not knowing anything about it and think that I can see changes I make pretty much immediately. Then I will move on to C++ 6 again and learn stuff I didn't do before after getting back to where I was before. Then on to databases again (done them since 89 but nothing in the past 12 months). After that I need to look into completing my degree as well as getting a job (of any kind) which by then I hope will see me controlling my life again.
So there is a little peek into my warped mind.
I downloaded 1.0.1 and 1.1, I will probably go with 1.1 as I won't be building anything that needs to work with too many different browsers. Just so I can understand and work with the two different paradigms of HTML standard interpretations.
Michael Martin
Australia
mjm68@tpg.com.au
"I personally love it because I can get as down and dirty as I want on the backend, while also being able to dabble with fun scripting and presentation games on the front end."
- Chris Maunder 15/07/2002
|
|
|
|
|
Did anyone here try for this product:
http://www.fulcrumweb.com/accuflow.html[^]
I think it's well worth trying,but I can't setup it on my win2000 server.
this is my signature for forums quoted from shog*9:
I can't help but feel, somewhere deep within that withered, bitter, scheming person, there is a small child, frightened, looking a way out.
|
|
|
|
|
Is there a nice and simple way to clear out the contents of a DataGrid with something like a .Clear() method?
For example, with a DropDownList named ddl you can easily clear the its contents by saying:
ddl.Items.Clear();
Is there some way that I can easily remove what is displayed in a DataGrid ?
I realize that there is a bit of a difference between a DataGrid and a DropDownList because with a DropDownList the values are basically being streamed into the list and there is not a strong tie to its datasource ... and about the exact opposite is true for a DataGrid .
But still ... there's gotta be a way ...
|
|
|
|
|
Really for the ASP.NET forums, but all you need to do is un-databind it
DataGrid1.DataSource = null;
DataGrid1.DataBind();
"I dont have a life, I have a program."
|
|
|
|
|
Hi:
I have a DataGrid Page say Page1 that shows me the List of orders that have not been billed yet and also a column at the last which is a hyperlink to the page that will help me create the bill for the order.
Now when i click the create-bill hyperlink the page works i can go ahead and create the bill.This is done on a seperate page that opens up say Page2.
But what i alsowant is once the bill is made out and entered into the DB i want this pending bill entry to go out of the DataGrid.That is i want the datagrid on page1 to refresh itself when there is a button click event on the page2 that makes the bill.
Any suggestions on how to do this.Thanks In Advance
Regards
Pradhip.S
Why Need Parking lots in Bars when Drunken Driving is Prohibited
|
|
|
|