473,480 Members | 1,755 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

OpenFile Stupid question

What Class.Method should be used to Open a file on the file system
so that the appropriate program is run and the file loaded into it.
Just like as if the user double clicked the file in file viewer.
i.e. if I Open a .doc file and MSWord is set to open .doc files Word
comes up with the file loaded and the file is writable.

Thanks,

JIM
Nov 15 '05 #1
2 2457
You need Process class. Look at the example given in the documentation of
Process.StartInfo property.

"james" <no****@hypercon.net> wrote in message
news:%2****************@TK2MSFTNGP12.phx.gbl...
What Class.Method should be used to Open a file on the file system
so that the appropriate program is run and the file loaded into it.
Just like as if the user double clicked the file in file viewer.
i.e. if I Open a .doc file and MSWord is set to open .doc files Word
comes up with the file loaded and the file is writable.

Thanks,

JIM

Nov 15 '05 #2
That's what I was looking for, thanks.

When you don't know the class/method name
you can search all day long and not find it.

JIM

"Val Savvateev" <vs********@meridium.com_NO_SPAM> wrote in message
news:Ol**************@tk2msftngp13.phx.gbl...
You need Process class. Look at the example given in the documentation of
Process.StartInfo property.

"james" <no****@hypercon.net> wrote in message
news:%2****************@TK2MSFTNGP12.phx.gbl...
What Class.Method should be used to Open a file on the file system
so that the appropriate program is run and the file loaded into it.
Just like as if the user double clicked the file in file viewer.
i.e. if I Open a .doc file and MSWord is set to open .doc files Word
comes up with the file loaded and the file is writable.

Thanks,

JIM


Nov 15 '05 #3

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

Similar topics

119
4507
by: rhat | last post by:
I heard that beta 2 now makes ASP.NET xhtml compliant. Can anyone shed some light on what this will change and it will break stuff as converting HTML to XHTML pages DO break things. see,...
4
6211
by: dave | last post by:
I have an app that uses the OpenFile Dialog class. When I invoke the ShowDialog method, the hourglass appears and just stays. The dialog window never opens. I created a test form with an...
1
1288
by: Mr Gordonz | last post by:
Hi All, I am trying to replicate the functionality of the HTML FileField control (<INPUT type="file">). It does everything I need but for one thing: I can't programmatically set the value of...
1
1363
by: Fabiano | last post by:
Please, i need to create an webpage that allows user to upload a file to server. I looked up at webcontrols that allow something like this but didn't found anything, just the HTML Control. I...
6
1594
by: Adam Smith | last post by:
I have posted this and similar questions repeatedly and can't even raise a single response. I am being led to believe that this then 'Must be a stupid question' although people say that there is no...
1
1239
by: Sean Campbell | last post by:
Hi all! I have a problem with the OpenFile dialog that I use in my program. I created a Browse button to allow for the selection of a text file that is processed by my program. The Browse...
0
2027
by: dieter grobler | last post by:
Hi there, I wanted to know if there is a way to specify the default location the OpenFileDialog shows when the browse button is pressed on the FileUpload Control. i.e "c:\program files\". I know...
2
3391
by: asenthil | last post by:
Hai... i'm triying to open a file in read mode using the following method.. HFILE hFile; hFile=OpenFile("D:\ss.doc",lpReOpenBuff,OF_READ); i cant undestand what is the 2nd parameter is... ...
4
4228
by: Marco Trapanese | last post by:
Hi! I show an OpenFile Dialog with: dlgOpen.ShowDialog() but I'd like to change the default view among Detail, Thumbnail, Icons, ect. Users change the view mode by this button: ...
0
1119
by: jaeden99 | last post by:
I have created a datagrid filled with information from the database. When a user clicks on a particular cell (this cell contains drive letter and file name), I would like to be able to open the...
0
7044
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
7045
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
6944
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
1
4782
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4483
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
2995
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
2985
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
563
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
182
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.