public Window1() { InitializeComponent(); restClient = new RestServiceClient(); restClient.Proxy.Credentials = CredentialCache.DefaultCredentials; restClient.ServerUrl = Properties.Settings.Default.ServerAddress; if (String.IsNullOrEmpty(Properties.Settings.Default.ApplicationId) || String.IsNullOrEmpty(Properties.Settings.Default.Password)) { changeAppIdAndPwd(); } restClient.ApplicationId = Properties.Settings.Default.ApplicationId; restClient.Password = Properties.Settings.Default.Password; restClientAsync = new RestServiceClientAsync(restClient); restClientAsync.UploadFileCompleted += UploadCompleted; restClientAsync.TaskProcessingCompleted += ProcessingCompleted; restClientAsync.DownloadFileCompleted += DownloadCompleted; restClientAsync.ListTasksCompleted += TaskListObtained; fieldLevelImage.RegionSelected += fieldSelected; }
public NamecardRecognizer() { this._restClientAsync = new RestServiceClientAsync(this._restClient); this._restClientAsync.UploadFileCompleted += UploadCompleted; this._restClientAsync.TaskProcessingCompleted += ProcessingCompleted; this._restClientAsync.DownloadFileCompleted += DownloadCompleted; this._settings = GetBusCardProcessingSettings(); }
public ProcessingPage() { InitializeComponent(); RestServiceClient syncClient = new RestServiceClient(); // !!!! Provide your credentials here !!!! syncClient.ApplicationId = ""; syncClient.Password = ""; abbyyClient = new RestServiceClientAsync(syncClient); abbyyClient.UploadFileCompleted += UploadCompleted; abbyyClient.TaskProcessingCompleted += ProcessingCompleted; abbyyClient.DownloadFileCompleted += DownloadCompleted; }
public ProcessingPage() { InitializeComponent(); RestServiceClient syncClient = new RestServiceClient(); #error Please provide application id and password and remove this line !!! // Name of application you created syncClient.ApplicationId = ""; // Password should be sent to your e-mail after application was created syncClient.Password = ""; abbyyClient = new RestServiceClientAsync(syncClient); abbyyClient.UploadFileCompleted += UploadCompleted; abbyyClient.TaskProcessingCompleted += ProcessingCompleted; abbyyClient.DownloadFileCompleted += DownloadCompleted; }
public MainWindow() { InitializeComponent(); restClient = new RestServiceClient(); restClient.Proxy.Credentials = CredentialCache.DefaultCredentials; restClient.ServerUrl = Properties.Settings.Default.ServerAddress; restClient.ApplicationId = Properties.Settings.Default.ApplicationId; restClient.Password = Properties.Settings.Default.Password; restClientAsync = new RestServiceClientAsync(restClient); restClientAsync.UploadFileCompleted += UploadCompleted; restClientAsync.TaskProcessingCompleted += ProcessingCompleted; restClientAsync.DownloadFileCompleted += DownloadCompleted; restClientAsync.ListTasksCompleted += TaskListObtained; }
public Test() { restClient = new RestServiceClient(); restClient.ServerUrl = Properties.Settings.Default.ServerAddress; restClient.Proxy.Credentials = CredentialCache.DefaultCredentials; if (!String.IsNullOrEmpty(Properties.Settings.Default.ApplicationId)) { restClient.ApplicationId = Properties.Settings.Default.ApplicationId; } if (!String.IsNullOrEmpty(Properties.Settings.Default.Password)) { restClient.Password = Properties.Settings.Default.Password; } restClientAsync = new RestServiceClientAsync(restClient); Console.WriteLine(String.Format("Application id: {0}\n", restClient.ApplicationId)); }
public ProcessingPage() { InitializeComponent(); RestServiceClient syncClient = new RestServiceClient(); #error Please provide application id and password and remove this line !!! // To create an application and obtain a password, // register at http://cloud.ocrsdk.com/Account/Register // More info on getting your application id and password at // http://ocrsdk.com/documentation/faq/#faq3 // Name of application you created syncClient.ApplicationId = ""; // Password should be sent to your e-mail after application was created syncClient.Password = ""; abbyyClient = new RestServiceClientAsync(syncClient); abbyyClient.UploadFileCompleted += UploadCompleted; abbyyClient.TaskProcessingCompleted += ProcessingCompleted; abbyyClient.DownloadFileCompleted += DownloadCompleted; }