Results 1 to 12 of 12
  1. #1
    mnpeepno2's Avatar
    Join Date
    Dec 2009
    Gender
    male
    Location
    In a barren wasteland
    Posts
    905
    Reputation
    10
    Thanks
    81

    [Help]special functions[Solved]

    does anyone know how to do a special function?

    EX:
    you open up your program in safe mode through -h so a shortcut would be:
    C:\BLABLABLA\program.exe -h

    how do i make my program recognize the "-h"?


    -----------------------------------------------

    My site: here
    My Blog: here
    My member's area: here
    Minecraft Sever Forum: here


    Minecraft Servers:

    Public:



    Private:



  2. #2
    Blubb1337's Avatar
    Join Date
    Sep 2009
    Gender
    male
    Location
    Germany
    Posts
    5,915
    Reputation
    161
    Thanks
    3,108
    I simply know this:

    Shell("C:\BLABLABLA\program.exe -h")

    or

    Shell(""C:\BLABLABLA\program.exe" " & "-h")



  3. #3
    Hassan's Avatar
    Join Date
    May 2010
    Gender
    male
    Location
    System.Threading.Tasks
    Posts
    4,764
    Reputation
    495
    Thanks
    2,133
    My Mood
    Dead
    On the load event of the form, put the following code:

    [php]For Each argument As String In Environment.GetCommandLineArgs()

    Console.WriteLine(argument)

    Next argument[/php]

    This will display every argument passed to the application and you can decide how to handle them.

    For example if the parameter is " -u" then you can use it to call an update for your application. Depends upon you.

  4. The Following User Says Thank You to Hassan For This Useful Post:

    mnpeepno2 (05-06-2010)

  5. #4
    mnpeepno2's Avatar
    Join Date
    Dec 2009
    Gender
    male
    Location
    In a barren wasteland
    Posts
    905
    Reputation
    10
    Thanks
    81
    oh ok,

    WORKS


    -----------------------------------------------

    My site: here
    My Blog: here
    My member's area: here
    Minecraft Sever Forum: here


    Minecraft Servers:

    Public:



    Private:



  6. #5
    NextGen1's Avatar
    Join Date
    Dec 2009
    Gender
    male
    Location
    Not sure really.
    Posts
    6,312
    Reputation
    382
    Thanks
    3,019
    My Mood
    Amazed
    Marked Solved, avoid posting in ....


     


     


     



    The Most complete application MPGH will ever offer - 68%




  7. #6
    mnpeepno2's Avatar
    Join Date
    Dec 2009
    Gender
    male
    Location
    In a barren wasteland
    Posts
    905
    Reputation
    10
    Thanks
    81
    i got one more issue, how do i open a program in "-h" mode

    EX:
    C:\BLABLABLA\Program.exe -h

    process.start(application.excutablepath & " -h") = Win32 cannot find the application...


    -----------------------------------------------

    My site: here
    My Blog: here
    My member's area: here
    Minecraft Sever Forum: here


    Minecraft Servers:

    Public:



    Private:



  8. #7
    Hassan's Avatar
    Join Date
    May 2010
    Gender
    male
    Location
    System.Threading.Tasks
    Posts
    4,764
    Reputation
    495
    Thanks
    2,133
    My Mood
    Dead
    Quote Originally Posted by mnpeepno2 View Post
    i got one more issue, how do i open a program in "-h" mode

    EX:
    C:\BLABLABLA\Program.exe -h

    process.start(application.excutablepath & " -h") = Win32 cannot find the application...
    Try using Shell command:

    Code:
    Shell (application.excutablepath & " -h")
    Let me know if it works or not !!

  9. The Following User Says Thank You to Hassan For This Useful Post:

    mnpeepno2 (05-06-2010)

  10. #8
    Blubb1337's Avatar
    Join Date
    Sep 2009
    Gender
    male
    Location
    Germany
    Posts
    5,915
    Reputation
    161
    Thanks
    3,108
    This is what I've written above >_>



  11. The Following User Says Thank You to Blubb1337 For This Useful Post:

    mnpeepno2 (05-06-2010)

  12. #9
    MvRouC12's Avatar
    Join Date
    Feb 2010
    Gender
    male
    Location
    Stalking Choobs
    Posts
    1,690
    Reputation
    13
    Thanks
    246
    My Mood
    Amused
    Shell works for me. should work for him. lol

    ---

    Off Topic:

    i love just entering random conversations

    [IMG]https://i986.photobucke*****m/albums/ae345/TripleSixPf/Okami-MvRouC12.jpg[/IMG]
    Quote Originally Posted by m_t_h View Post


    By stop playing AVA untill brasilian server comes.

    Do you guys really need to ruin EVERY game?
    [IMG]https://i175.photobucke*****m/albums/w148/Guitarman1157/dontforget.gif[/IMG]

  13. #10
    mnpeepno2's Avatar
    Join Date
    Dec 2009
    Gender
    male
    Location
    In a barren wasteland
    Posts
    905
    Reputation
    10
    Thanks
    81
    yep works!


    -----------------------------------------------

    My site: here
    My Blog: here
    My member's area: here
    Minecraft Sever Forum: here


    Minecraft Servers:

    Public:



    Private:



  14. #11
    NextGen1's Avatar
    Join Date
    Dec 2009
    Gender
    male
    Location
    Not sure really.
    Posts
    6,312
    Reputation
    382
    Thanks
    3,019
    My Mood
    Amazed
    Solved, for future questions in this regard, programatically use shell

    or if you want to get further into it you can shell cmd and pass certain code, similar to batching, so really it is to what extent.


    [php]
    Shell("cmd.exe /C ECHO Y| cacls C:\Folder\" , AppWinStyle.Hide, True)
    [/php]

    So in either case...

    Solved Again :/


     


     


     



    The Most complete application MPGH will ever offer - 68%




  15. #12
    mnpeepno2's Avatar
    Join Date
    Dec 2009
    Gender
    male
    Location
    In a barren wasteland
    Posts
    905
    Reputation
    10
    Thanks
    81
    here is what i came up with
    [php]
    Dim arguments As [String]() = Environment.GetCommandLineArgs()
    Console.WriteLine("GetCommandLineArgs: {0}", [String].Join(", ", arguments))
    If arguments.Length = 2 Then
    Else
    SplashScreen1.Show()
    End If
    [/php]


    -----------------------------------------------

    My site: here
    My Blog: here
    My member's area: here
    Minecraft Sever Forum: here


    Minecraft Servers:

    Public:



    Private:



Similar Threads

  1. [Help Request] Help me to solve this ? :#
    By josias008 in forum Combat Arms Help
    Replies: 9
    Last Post: 08-06-2011, 12:05 AM
  2. [HELP] Print Function & Print Preview[Solved]
    By Jàzzà_ in forum Visual Basic Programming
    Replies: 3
    Last Post: 02-07-2011, 04:37 PM
  3. [Help]Search File Function[Solved]
    By ppl2pass in forum Visual Basic Programming
    Replies: 1
    Last Post: 06-09-2010, 07:50 AM
  4. [Help] Missing Tabs [Solved]
    By zmansquared in forum Visual Basic Programming
    Replies: 18
    Last Post: 03-11-2010, 06:25 PM
  5. [Help]Custom GUI[Solved]
    By martijno0o0 in forum Visual Basic Programming
    Replies: 1
    Last Post: 03-07-2010, 06:43 AM