Main.Controllers.CategoriesController.Create C# (CSharp) Method

Create() public method

public Create ( ) : System.Web.Mvc.ActionResult
return System.Web.Mvc.ActionResult
        public ActionResult Create()
        {
            return View();
        }

Same methods

CategoriesController::Create ( [ Include = "CategoryID,CategoryName")]Categorycategory ) : System.Web.Mvc.ActionResult

Usage Example

        public void testCreate()
        {
            CategoriesController categoriesController = new CategoriesController();
            ActionResult create1 = categoriesController.Create();

            Category category = new Category();
            category.CategoryID = 5;
            category.CategoryName = "Clothing";

            ActionResult create2 = categoriesController.Create(category);
        }