CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Feb 2000
    Location
    Bangalore
    Posts
    4

    How to open *.cpl files onClick

    How can I open and CPL file through visual basic i tried using shell (Shell("C:\windows\system\modem.cpl") but in vain , but i could able to open exe files using the above command can anybody help me out.
    Natraj
    [email protected]



  2. #2
    Join Date
    Jan 2000
    Location
    Olen, Belgium
    Posts
    2,477

    Re: How to open *.cpl files onClick

    What you are doing using the shell command is the same like typing something in the Run box, in you start menu. If you want to open a file to read it, then use the Open statement. If you want to open the file in it's default application, then use the ShellExecute API, an example code can be found at http://vbcode.webhostme.com/en/code.asp?id=101

    Tom Cannaerts
    [email protected]

    The best way to escape a problem, is to solve it.
    Tom Cannaerts
    email: [email protected]
    www.tom.be (dutch site)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured