コード例 #1
0
        private void button1_Click(object sender, EventArgs e)
        {
            DisplayOrientation ori = ScreenSetting.GetScreenOrientation();

            if (ori == DisplayOrientation.DmdoDEFAULT)
            {
                ori = DisplayOrientation.Dmdo90;
            }
            else
            {
                ori = DisplayOrientation.DmdoDEFAULT;
            }
            ScreenSetting.Orientation(ori);
        }
コード例 #2
0
ファイル: Program.cs プロジェクト: taisandog/OtherSource
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            DisplayOrientation ori = ScreenSetting.GetScreenOrientation();

            if (ori == DisplayOrientation.DmdoDEFAULT)
            {
                ori = DisplayOrientation.Dmdo90;
            }
            else
            {
                ori = DisplayOrientation.DmdoDEFAULT;
            }
            ScreenSetting.Orientation(ori);

            //Application.Run(new Form1());
        }