Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C#
I have an Windows Forms application that effectively manages workflow on files in a set of predefined folders on a shared drive. i.e users can check files out and check them in and move them to QA etc, which phisically moves the files within the predefined folder structure.
 
However, at the moment this will obviously only work with a single project (and the single set of folders that i have coded into the program).
 
What i'd like to be able to do, is have a File menu item that is 'Create new Project'. When selected, a dialog box pops up asking for the project name and maybe a couple of other bits of info, then it creates the folder structure for that new project and away i go.
 
The user obviously also needs the option to choose which project to work with, and therefore which folder structure.
 
I have no idea where to start with this, so any pointers would be very useful. Thanks in advance.
Posted 7-Feb-13 5:01am
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

There are many ways to design your application. The following is one "scenario". Look at other applications that your users have. See if any of their design paradigms align with your application type. Use what you judge to be the best ideas from them to design your user interaction processes.
 
One example
Create a new form that you open with ShowDialog in the click event of the Create New Project menu item. In the new form, use the OpenFileDialog control to allow the user to select the file or directory, then the user fills values in various form controls to define the new project values. When the user clicks the OK button or Create Project button, INSERT the data into your database and close the form to return to your main program. You may want your main program to display a list of all available projects or provide a search capability to find and display selected projects. That is a matter of how you want your program to interact with the user. How would you want it to act if you were the user?
 
Use the MenuStrip or (the older) MainMenu control from the Toolbox to create menu items.
 
MenuStrip
Provides a menu system for a form.
 
MainMenu
Represents the menu structure of a form. Although MenuStrip replaces and adds functionality to the MainMenu control of previous versions, MainMenu is retained for both backward compatibility and future use if you choose.
 

Use the OpenFileDialog control to allow use to select a file or directory.
 
OpenFileDialog
Represents a common dialog box that allows a user to specify a filename for one or more files to open.
  Permalink  
v5
Comments
DaedalusAero at 7-Feb-13 10:36am
   
Thanks Mike, but my question was more to do with how to structure the program - I should have been more specific. How should my program deal with the New Project click event? Perhaps open a new form where the user enters project name etc? Then what? How does my program deal with creating this new project template. Then how does it programatically give me that project as an option the next time the user starts the application?
Mike Meinz at 7-Feb-13 12:14pm
   
I added further clarification to the Solution. If this answers your question, please Accept the solution so the question gets marked as answered.
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 3

choose MenuStrip from the toolbox
then write create new project in the text
 
after that add a new windows form
and under the text of creat new ptoject
in the first form
calling the creation form with object
 

like
 
CreateProjectClass cp=new CreateProjectClass();
cp.show();
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 DamithSL 440
1 OriginalGriff 194
2 BillWoodruff 170
3 Zoltán Zörgő 165
4 Maciej Los 163
0 OriginalGriff 7,934
1 DamithSL 6,084
2 Sergey Alexandrovich Kryukov 5,449
3 Maciej Los 5,174
4 Kornfeld Eliyahu Peter 4,539


Advertise | Privacy | Mobile
Web04 | 2.8.141223.1 | Last Updated 7 Feb 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100