예제 #1
0
        public ActionResult About()
        {
            // ViewBag.Message = "Your application description page.";
            Hello             hello = new Hello();
            ExampleDictionary ed    = new ExampleDictionary();

            ed.Example();
            ViewBag.Message = hello.GetHello();
            return(View());
        }
        public ActionResult Contact()
        {
            //ViewBag.Message = "Your contact page.";

            ExampleDictionary exampleDictionary = new ExampleDictionary();

            exampleDictionary.Example();

            return(View());
        }
예제 #3
0
        public ActionResult About()
        {
            Hello hello = new Hello();

            ViewBag.Message = hello.GetHello();
            ExampleDictionary ed = new ExampleDictionary();

            ed.Example();

            return(View());
        }
예제 #4
0
        public ActionResult About()
        {
            //ViewBag.Message = "Your application description page.";
            Hello hello = new Hello();

            ViewBag.Message = hello.GetHello();

            //this following two lane are about dictionary method
            ExampleDictionary ed = new ExampleDictionary();

            ed.Example();

            return(View());
        }
        public ActionResult About()
        {
            ViewBag.Message = "Your application description page.";
            ViewBag.Message = "This is my first c# program.";
            HelloWorld.Hello h = new HelloWorld.Hello();
            ViewBag.Message = h.GetHello();
            ExampleDictionary ed = new ExampleDictionary();

            ed.Example();



            return(View());
        }
        public ActionResult About()
        {
            // I commented this line out
            //ViewBag.Message = "Your application description page.";
            // I created an instance of the Hello object
            Hello hello = new Hello();

            // I assigned the ViewBag.Message to the result
            ViewBag.Message = hello.GetHello();

            ExampleDictionary ed = new ExampleDictionary();

            ed.Example();

            return(View());
        }
        // 这是个about function. 在网页里有体现。  先运行about里的
        public ActionResult About()
        {
            Hello hello = new HelloWorld.Hello();

            //通过get method来调用这个class的内容
            ViewBag.Message = hello.GetHello();



            ExampleDictionary ed = new ExampleDictionary();

            //作用是 debug。确认上面的code没问题  因为code是从上到下run的
            ed.Example();



            return(View());
        }