Results 1 to 9 of 9

Thread: [VS 2015] Command line to start with new project ready to use?

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Dec 2011
    Posts
    194

    [VS 2015] Command line to start with new project ready to use?

    Is there a Command line param to start VS with a new project ready to use? (Windows Forms Application or any other template)
    On Error GoTo Hell

  2. #2
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    110,299

    Re: [VS 2015] Command line to start with new project ready to use?

    Just like many, many Windows programs, if you want to know what commandline arguments the VS executable supports then run it from a commandline with the '/?' argument. I very much doubt that what you want is available though, as there's no guarantee that any particular project template is installed in any particular VS instance.

  3. #3

    Thread Starter
    Addicted Member
    Join Date
    Dec 2011
    Posts
    194

    Re: [VS 2015] Command line to start with new project ready to use?

    I have visited this page https://msdn.microsoft.com/en-us/library/xee0c8y7.aspx before asking, i was hoping there is something not listed or workaround
    On Error GoTo Hell

  4. #4
    Sinecure devotee
    Join Date
    Aug 2013
    Location
    Southern Tier NY
    Posts
    6,582

    Re: [VS 2015] Command line to start with new project ready to use?

    Since there are so many project types, what would "starting with a new project ready for use" mean? What would be the sub directory and name for the default project?

    I think if you just changed the startup option to show the "New Project" dialog, that should be close to what you want. When VS starts you would be presented with the dialog and you click OK, and you should have a default project ready to go.
    The "default project" would be whatever type project you selected the last time you ran. So if you do WinForm programs, then a WinForm project should be selected and pressing OK will open a new default Winform project.
    If you previously selected a wpf project, then a wpf project will be preselected and hitting OK will load a new wpf project.

    I don't have 2015 on this machine, but in 2010 you selected the Options menu under Tools, then selected the "Show all Settings" checkbox, then expanded the Environment branch and select Startup. Then change the "At startup: option to "Show New Project dialog box".

    I assume 2015 would have something similar.
    Last edited by passel; Nov 20th, 2017 at 01:43 AM.

  5. #5

    Thread Starter
    Addicted Member
    Join Date
    Dec 2011
    Posts
    194

    Re: [VS 2015] Command line to start with new project ready to use?

    Quote Originally Posted by passel View Post
    I don't have 2015 on this machine, but in 2010 you selected the Options menu under Tools, then selected the "Show all Settings" checkbox, then expanded the Environment branch and select Startup. Then change the "At startup: option to "Show New Project dialog box".

    I assume 2015 would have something similar.
    Thank you! It's better than nothing.
    On Error GoTo Hell

  6. #6
    Member
    Join Date
    Oct 2016
    Posts
    32

    Re: [VS 2015] Command line to start with new project ready to use?

    You could make a program which creates the project files needed. I am doing that now (actually already done this specific part just not the whole program) as a collaboration program for my group. Since most of the files in a project is text based you only need to take note of the structure and what to change. After you figure that out just write the respective files to disk and bam done. Take note though that some parts require GUID and so those you have to generate.

  7. #7
    You don't want to know.
    Join Date
    Aug 2010
    Posts
    4,578

    Re: [VS 2015] Command line to start with new project ready to use?

    Not really, particularly if you're planning on using VS.

    If you're writing .NET Standard applications with Visual Studio Code instead, you can use command-line tools to generate project structures. I'm pretty sure "dotnet cli" starts a wizard for a new command-line project. Tooling doesn't yet have a GUI framework for netstandard though, so odds are it doesn't matter to you.
    This answer is wrong. You should be using TableAdapter and Dictionaries instead.

  8. #8
    Wall Poster TysonLPrice's Avatar
    Join Date
    Sep 2002
    Location
    Columbus, Ohio
    Posts
    3,834

    Re: [VS 2015] Command line to start with new project ready to use?

    I didn't dig very deep but look at this:

    Run a Solution

    You can automatically run a solution from the command line using the /run switch. The following is an example of running a solution from the command line:

    C:\> devenv /run HacksWinSample.sln
    When this command is run, the IDE will open and automatically jump into debug mode loading your application. You can also use the /runexit switch, which will launch your applications and minimize the IDE. When you close your application, the IDE will be closed as well.
    From here:

    http://archive.oreilly.com/pub/h/5186

    And somehow incorporate with this?

    "C:\Program Files\Microsoft Visual Studio 8\Common7\IDE\devenv.exe"

    I'm just spit balling
    Please remember next time...elections matter!

  9. #9
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    110,299

    Re: [VS 2015] Command line to start with new project ready to use?

    @TysonLPrice, I don't think that helps because that is for an existing solution, where it appears that the OP wants a new solution and project created automatically.

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