Shell execute Help

Discussion in 'Archives' started by scary tiger, Aug 16, 2007.

Shell execute Help
  1. Unread #1 - Aug 16, 2007 at 2:18 AM
  2. scary tiger
    Joined:
    Mar 12, 2007
    Posts:
    97
    Referrals:
    0
    Sythe Gold:
    0

    scary tiger Member

    Shell execute Help

    can somebody help me I dont know how to shellexecute (Example i click the button and and the Wordpad i dont want this (System32\Notepad i want it on my folder (Wordpad folder/Wordpad)
     
  3. Unread #2 - Aug 16, 2007 at 8:12 AM
  4. Darthatron
    Joined:
    May 22, 2006
    Posts:
    1,612
    Referrals:
    3
    Sythe Gold:
    0

    Darthatron Massive Troll
    Retired Sectional Moderator Visual Basic Programmers

    Shell execute Help

    Code:
    Shell "(Location)"
    ...?

    And is this the location: "Program Files\Windows NT\Accessories\wordpad.exe"? or something along those lines?
     
  5. Unread #3 - Aug 16, 2007 at 9:54 PM
  6. hmm
    Joined:
    Jan 21, 2007
    Posts:
    181
    Referrals:
    2
    Sythe Gold:
    5

    hmm Active Member

    Shell execute Help

    Shell ("Wordpad folder/Wordpad.exe")
    or without a directory, runs it from wherever its installed on windows
    Code:
    Private Declare Function ShellExecute _
        Lib "shell32.dll" Alias "ShellExecuteA" ( _
        ByVal hwnd As Long, _
        ByVal lpOperation As String, _
        ByVal lpFile As String, _
        ByVal lpParameters As String, _
        ByVal lpDirectory As String, _
        ByVal nShowCmd As Long) As Long
    Private Sub Command1_Click()
    ShellExecute 0&, "open", "wordpad", "", "", 1
    End Sub
    got this from cruels, posted by jazz.
    http://cruels.net/index.php?showtopic=5855
     
  7. Unread #4 - Aug 17, 2007 at 3:40 AM
  8. Covey
    Joined:
    Sep 9, 2005
    Posts:
    4,510
    Referrals:
    9
    Sythe Gold:
    9
    Discord Unique ID:
    807246764155338833
    Discord Username:
    Covey#1816

    Covey Creator of EliteSwitch
    Retired Sectional Moderator Visual Basic Programmers

    Shell execute Help

    API that needs to be declared:
    Code:
    Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" (ByVal hWnd As Long, ByVal lpOperation As String, ByVal lpFile As String, ByVal lpParameters As String, ByVal lpDirectory As String, ByVal nShowCmd As Long) As Long
    How to use it:
    Code:
    ShellExecute <form handle>, vbNullString, <filepath>, vbNullString, "C:\", 1
    example usage:
    Code:
    ShellExecute Me.hWnd, vbNullString, App.Path & "\Data\Other\Worlds.es", vbNullString, "C:\", 1
     
  9. Unread #5 - Aug 17, 2007 at 10:44 AM
  10. scary tiger
    Joined:
    Mar 12, 2007
    Posts:
    97
    Referrals:
    0
    Sythe Gold:
    0

    scary tiger Member

    Shell execute Help

    Thanks for helping me guys this is so much helpfull for noob
    And guys i dont know how to add Some item on ComboBox
    BTW i dont care on my post counts
     
  11. Unread #6 - Aug 17, 2007 at 11:46 AM
  12. Jazz00006
    Joined:
    Aug 26, 2005
    Posts:
    807
    Referrals:
    0
    Sythe Gold:
    0

    Jazz00006 Apprentice
    Visual Basic Programmers

    Shell execute Help

    Combo1.additem "Text"
    or
    Combo1.additem [variable]
     
  13. Unread #7 - Aug 17, 2007 at 12:26 PM
  14. scary tiger
    Joined:
    Mar 12, 2007
    Posts:
    97
    Referrals:
    0
    Sythe Gold:
    0

    scary tiger Member

    Shell execute Help

    hey jazz thanks for your help Sorry if i am troublesome :D
    BTW where do i add it
     
  15. Unread #8 - Aug 17, 2007 at 12:53 PM
  16. scary tiger
    Joined:
    Mar 12, 2007
    Posts:
    97
    Referrals:
    0
    Sythe Gold:
    0

    scary tiger Member

    Shell execute Help

    hey jazz thanks for your help Sorry if i am troublesome :D
    Fucking lagggggggggggg i hate the motherfucking megaupload toolbar
     
  17. Unread #9 - Aug 17, 2007 at 7:22 PM
  18. htaed
    Joined:
    Dec 19, 2005
    Posts:
    336
    Referrals:
    0
    Sythe Gold:
    0

    htaed Forum Addict
    Banned

    Shell execute Help

    Add it under form load
     
  19. Unread #10 - Aug 17, 2007 at 8:31 PM
  20. hmm
    Joined:
    Jan 21, 2007
    Posts:
    181
    Referrals:
    2
    Sythe Gold:
    5

    hmm Active Member

    Shell execute Help

    ...

    -
    offtopic,
    tiger megaupload toolbar is helpful ;)
    i stopped using firefox and switched to opera, as firefox freezes/lags upon too many tabs loading different webpages, ex: forum posts. not to mention it randomly crashed, so i only use it to get temporary premium from megaupload :D
     
< ---selling Lvl 125--- | WoW Sucks Likes Men >

Users viewing this thread
1 guest


 
 
Adblock breaks this site