예제 #1
0
    static void Main()
    {
        StoredProcDemo spd = new StoredProcDemo();

        // run a simple stored procedure
        spd.RunStoredProc();

        // run a stored procedure that takes a parameter
        spd.RunStoredProcParams();
    }
예제 #2
0
        static void Main()
        {
            Console.WriteLine("Starting Program...");
            Console.WriteLine("----------------------------------------");
            /************************************************Store Procedure Example*************************************************/
            //TODO: Connect to db so program can run
            StoredProcDemo spd = new StoredProcDemo();

            // run a simple stored procedure
            //!! spd.RunStoredProc();

            // run a stored procedure that takes a parameter
            //!! spd.RunStoredProcParams();
            /************************************************************************************************************************/


            /************************************************XML Deserialize using LINQ Example**************************************/
            XMLDeserializeLINQ xmlDeserialize = new XMLDeserializeLINQ();

            xmlDeserialize.startDeserialization();
            Console.WriteLine("****************************");
            /************************************************************************************************************************/


            /************************************************Loops Examples**********************************************************/
            Loops loop = new Loops();

            loop.forLoop();
            loop.whileLoop();
            loop.doWhileLoop();
            loop.nestedLoop();
            Console.WriteLine("****************************");
            /*************************************************************************************************************************/


            /************************************************Enum Example**********************************************************/
            Enums enumExample = new Enums();

            enumExample.displayEnumValues();
            Console.WriteLine("****************************");
            /*************************************************************************************************************************/


            /*************************************************Struct example**********************************************************/
            Structure structExample = new Structure();

            structExample.displayStructure();
            Console.WriteLine("****************************");
            /*************************************************************************************************************************/


            /*************************************************Array/Foreach example**********************************************************/
            ArrayAndForeach arrayExample = new ArrayAndForeach();

            arrayExample.displayArray();
            Console.WriteLine("****************************");
            /*************************************************************************************************************************/


            /*************************************************Array/Foreach example**********************************************************/
            MultiThreading multiThread = new MultiThreading();
            //multiThread.startSleepyThread();
            //multiThread.startAbortingThread();
            //Console.WriteLine("****************************");
            /*************************************************************************************************************************/


            /*************************************************Data Manipulation example**********************************************************/
            DataManipulation myData = new DataManipulation();
            var results             = myData.getData();

            foreach (var character in results)
            {
                Console.WriteLine("Name: {0}", character.name);
                Console.WriteLine("height: {0}", character.height);
                Console.WriteLine("Mass: {0}", character.mass);
                Console.WriteLine("Hair Color: {0}", character.hair_color);
                Console.WriteLine("Skin Color: {0}", character.skin_color);
                Console.WriteLine("Eye Color: {0}", character.eye_color);
                Console.WriteLine("Gender: {0}", character.gender);
                Console.WriteLine("Home World: {0}", character.homeworld);
                Console.WriteLine("*------*");
            }
            Console.WriteLine("****************************");
            /*************************************************************************************************************************/
        }