Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / General / June 2005

Tip: Looking for answers? Try searching our database.

Opening a File in VB.Net

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Mario - 27 Jun 2005 13:36 GMT
I am trying to Open an exe file.

       Dim p As String
       p = "C:\Program Files\hello.exe"

       File.Open(p, FileMode.Append)
       Me.Visible = False

But nothing is happening. Any help or Knowledge about this would be
aprreciated
Peter van der Goes - 27 Jun 2005 13:58 GMT
>I am trying to Open an exe file.
>
[quoted text clipped - 6 lines]
> But nothing is happening. Any help or Knowledge about this would be
> aprreciated

What did you expect to happen as a result of this code? You have opened a
file for output in a mode that will append new data (when written) to
existing data already in the file. Are you trying to write additional binary
data to the file?

If you are trying to write to a file, look here:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vbcn7/html/vats
kchoosingamongfileiooptionsinvisualbasicnet.asp


OTOH, if you are trying to execute the file:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vblr7/html/vafc
tshell.asp


Signature

Peter [MVP Visual Developer]
Jack of all trades, master of none.


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.