VB6 Shell Files?

Discussion in 'OT Technology' started by Fase, Jul 27, 2006.

  1. Fase

    Fase Your Face, In A Pickle Jar.

    Joined:
    Apr 6, 2004
    Messages:
    29,540
    Likes Received:
    0
    Location:
    Windsor, Ont, Canada.
    I know how to Shell Open .exes, but can't seem to Shell open files. Like say press a button and a text file on C:\ opens.
     
  2. Slid.

    Slid. I'm a guy.

    Joined:
    Oct 25, 2001
    Messages:
    1,928
    Likes Received:
    0
    Location:
    NH
    Had the same problem in .NET, shell doesn't seem to work with file extensions. The following works for .NET:

    System.Diagnostics.Process.Start("c:\text.txt")
     
  3. Slid.

    Slid. I'm a guy.

    Joined:
    Oct 25, 2001
    Messages:
    1,928
    Likes Received:
    0
    Location:
    NH
  4. Fase

    Fase Your Face, In A Pickle Jar.

    Joined:
    Apr 6, 2004
    Messages:
    29,540
    Likes Received:
    0
    Location:
    Windsor, Ont, Canada.
    Telling me System is an invalid qualifier for VB6 :(
     
  5. Fase

    Fase Your Face, In A Pickle Jar.

    Joined:
    Apr 6, 2004
    Messages:
    29,540
    Likes Received:
    0
    Location:
    Windsor, Ont, Canada.
  6. Slid.

    Slid. I'm a guy.

    Joined:
    Oct 25, 2001
    Messages:
    1,928
    Likes Received:
    0
    Location:
    NH
    You don't need one.
     
  7. Slid.

    Slid. I'm a guy.

    Joined:
    Oct 25, 2001
    Messages:
    1,928
    Likes Received:
    0
    Location:
    NH
  8. Fase

    Fase Your Face, In A Pickle Jar.

    Joined:
    Apr 6, 2004
    Messages:
    29,540
    Likes Received:
    0
    Location:
    Windsor, Ont, Canada.
  9. Fase

    Fase Your Face, In A Pickle Jar.

    Joined:
    Apr 6, 2004
    Messages:
    29,540
    Likes Received:
    0
    Location:
    Windsor, Ont, Canada.
  10. Fase

    Fase Your Face, In A Pickle Jar.

    Joined:
    Apr 6, 2004
    Messages:
    29,540
    Likes Received:
    0
    Location:
    Windsor, Ont, Canada.
    I GOT IT!

    Shell "C:\Program Files\Microsoft Office\OFFICE11\EXCEL.exe C:\Extracted.csv", vbNormalFocus


    Thanks man ;)
     
  11. deusexaethera

    deusexaethera OT Supporter

    Joined:
    Jan 27, 2005
    Messages:
    19,712
    Likes Received:
    0
    Go here. It lists almost all of the Win32 API function calls available through VB6 and VB.NET:

    www.allapi.net

    (btw, all VB.NET does, besides change the whole fucking language, is it includes all of these Win32 API function calls as part of the language instead of making you include them manually.)
     
  12. Fase

    Fase Your Face, In A Pickle Jar.

    Joined:
    Apr 6, 2004
    Messages:
    29,540
    Likes Received:
    0
    Location:
    Windsor, Ont, Canada.
    Yeah I learnt on .Net and now I'm working with VB6 TT
     
  13. Slid.

    Slid. I'm a guy.

    Joined:
    Oct 25, 2001
    Messages:
    1,928
    Likes Received:
    0
    Location:
    NH
    For future reference: with experts-exchange you don't need to subscribe to view the answers, to view the answers without subscribing do this:

    1) Do *not* click on the big yellow/orange "View Solution" button.
    2) Scroll the browser down until you see answers.
    3) Profit.

    --

    If you view a page more than once you'll be forced to subscribe (they place a cookie on your computer, clear cookies if you really need to look again). If you click their big round "View Solution" button you get the same cookie, screwing yourself.
     
  14. Fase

    Fase Your Face, In A Pickle Jar.

    Joined:
    Apr 6, 2004
    Messages:
    29,540
    Likes Received:
    0
    Location:
    Windsor, Ont, Canada.
    Ah, the cookies. Thanks. It's working now.
     

Share This Page