473,387 Members | 3,684 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,387 software developers and data experts.

Opening a file(any file)

vdraceil
236 100+
Hi everyone,i'm using vb6.0.I just want to know how to open a file(its path known) on a command button click.If the file is an audio file,it must open in windows media player(the default player),if it is a text file it must open in a notepad,if it is a .doc file it must open in MS Word and so on..I know it can be done,but i dont know how.
Mar 1 '08 #1
5 1074
VACEPROGRAMER
168 100+
I will sen the code. It is at home so i will send about 5 hor. OK??


VxE
Mar 1 '08 #2
Killer42
8,435 Expert 8TB
Tick tick tick...

In fact, I believe this topic has been covered a number of times. Try using the search box up the top for significant words such as "VB", "SHELL", "OPEN" and so on. If you hit the right combination, you should get lucky.
Mar 3 '08 #3
vdraceil
236 100+
Tick tick tick...

In fact, I believe this topic has been covered a number of times. Try using the search box up the top for significant words such as "VB", "SHELL", "OPEN" and so on. If you hit the right combination, you should get lucky.
I couldnt find it killer...u just help me with the concept,i'll write the code on my own..thanx for replying
Mar 22 '08 #4
vdraceil
236 100+
I will sen the code. It is at home so i will send about 5 hor. OK??


VxE

Got the code with u??If so,send it over...
Mar 22 '08 #5
QVeen72
1,445 Expert 1GB
Hi,

Google for "ShellExecuteA" api.. and use the code..

REgards
Veena
Mar 22 '08 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Eric Caron | last post by:
Hi Here's my problem, I create a windows service with Config.xml file. All setup for my service is in this file. I create a windows application to manage these settings (Config.XML File). This...
9
by: ben | last post by:
Hello, This really drives me nuts. Im opening an input file, and Im testing if it was open successfully. Thats it! I know that the file that Im trying to open DOES NOT exist but Im getting NO...
28
by: Madhur | last post by:
Hello what about this nice way to open a file in single line rather than using if and else. #include<stdio.h> void main() { FILE *nd; clrscr();...
7
by: X-Terror | last post by:
How do I open a file (with fopen(), or similar conforming with ANSI C) so I can read/write in file, and if file doesn't exist to be created? Thanks!
9
by: Mark | last post by:
Hello I am trying to set up an open file routine that will open whatever files name is passed with its correct associated application. I have done this (quite easilly) before in VBA and am able...
4
by: Pieter | last post by:
Hi, From my VB.NET 2005 application I need to be able to open Files an Directory's with their default application: - A word-doc must open in word - A excell-document in Excel etc - in case...
5
by: bimeldip | last post by:
Hi, I an tryin to create a html page where users can choose a file and open it however, i keep getting it wrong.So far this is wat i've worked on: (open.html) <html> <head> <title>Opening...
2
by: Tenacious | last post by:
I have a simple asp.net web service that is trying to create or open an existing file in the same directory as the web service. There is no password authentication required for this web service. In...
0
by: =?Utf-8?B?Vmlua2k=?= | last post by:
Hello Everyone, I need to open a text file with .net remoting. This text file resides on another server. My server program running on the server has this method that opens the text file...
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: 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:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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
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
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.