コード例 #1
0
        public const string endpoint        = "https://westus.api.cognitive.microsoft.com"; // You must use the same Azure region that you generated your subscription keys for.  Free trial subscription keys are generated in the westus region.

        static void Main(string[] args)
        {
            OCRSample.RunAsync(endpoint, subscriptionKey).Wait(5000);

            Console.WriteLine("\nPress ENTER to exit.");
            Console.ReadLine();
        }
コード例 #2
0
        static async Task Main(string[] args)
        {
            await OCRSample.RunAsync(endpoint, subscriptionKey);

            Console.WriteLine("\nPress ENTER to exit.");
            Console.ReadLine();
        }
コード例 #3
0
        public const string endpoint        = "https://westus.api.cognitive.microsoft.com"; // You must use the same Azure region that you generated your subscription keys for.  Free trial subscription keys are generated in the westus region.

        static void Main(string[] args)
        {
            try
            {
                OCRSample.RunAsync(endpoint, subscriptionKey).Wait(5000);
            }
            catch (Exception e)
            {
                Console.WriteLine(e.Message);
            }

            Console.WriteLine("\nPress ENTER to exit.");
            Console.ReadLine();
        }
コード例 #4
0
ファイル: Program.cs プロジェクト: Jono120/ComputerVision
        static void Main(string[] args)
        {
            // Add your Computer Vision subscription key and endpoint to your environment variables
            string subscriptionKey = Environment.GetEnvironmentVariable("45c714d75ff847fd8e45719009d766d6");
            string endpoint        = Environment.GetEnvironmentVariable("https://australiaeast.api.cognitive.microsoft.com/");

            try
            {
                OCRSample.RunAsync(endpoint, subscriptionKey).Wait(5000);
            }
            catch (Exception e)
            {
                Console.WriteLine(e.Message);
            }

            Console.WriteLine("\nPress ENTER to exit.");
            Console.ReadLine();
        }
コード例 #5
0
        static void Main(string[] args)
        {
            // Add your Computer Vision subscription key and endpoint to your environment variables
            string subscriptionKey = Environment.GetEnvironmentVariable("COMPUTER_VISION_SUBSCRIPTION_KEY");
            string endpoint        = Environment.GetEnvironmentVariable("COMPUTER_VISION_ENDPOINT");

            try
            {
                OCRSample.RunAsync(endpoint, subscriptionKey).Wait(5000);
            }
            catch (Exception e)
            {
                Console.WriteLine(e.Message);
            }

            Console.WriteLine("\nPress ENTER to exit.");
            Console.ReadLine();
        }