コード例 #1
0
ファイル: Program.cs プロジェクト: kingofcrabs/Biobanking
 static void Main(string[] args)
 {
     while (true)
     {
         Console.WriteLine("Please input height.");
         string sHeight = Console.ReadLine();
         while (sHeight == "")
         {
             sHeight = Console.ReadLine();
         }
         MappingCalculator calculator = new MappingCalculator(Utility.GetExeFolder() + Settings.stringRes.calibFileName);
         double            h          = double.Parse(sHeight);
         //var tipVol = calculator.GetTipVolumeFromHeight(h);
         var vol = calculator.GetVolumeFromHeight(h);
         Console.WriteLine(string.Format("volume is:{1}", vol));
         Console.WriteLine("Press x to exit!");
         if (Console.ReadKey().Key == ConsoleKey.X)
         {
             Console.WriteLine();
             break;
         }
     }
 }
コード例 #2
0
ファイル: Program.cs プロジェクト: kingofcrabs/Biobanking
 static void Main(string[] args)
 {
     while(true)
     {
         Console.WriteLine("Please input height.");
         string sHeight = Console.ReadLine();
         while (sHeight == "")
             sHeight = Console.ReadLine();
         MappingCalculator calculator = new MappingCalculator(Utility.GetExeFolder() + Settings.stringRes.calibFileName);
         double h = double.Parse(sHeight);
         //var tipVol = calculator.GetTipVolumeFromHeight(h);
         var vol = calculator.GetVolumeFromHeight(h);
         Console.WriteLine(string.Format("volume is:{1}",vol));
         Console.WriteLine("Press x to exit!");
         if (Console.ReadKey().Key == ConsoleKey.X)
         {
             Console.WriteLine();
             break;
         }
     }
 }