Rachit95 / google-api-for-dotnet

Automatically exported from code.google.com/p/google-api-for-dotnet
0 stars 0 forks source link

Failed to Get Response #30

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Using C#.Net
2. Using GoogleTranslateAPI 0.3
3. string result = client.Translate("translating texts to Thai", 
Language.English, Language.Thai);

What is the expected output? What do you see instead?
It should translate the text to Thai --> Expected Result: 
แปลข้อความไทย

What version of the product are you using? On what operating system?
Windows XP + Visual Studio 2005 + GoogleTranslateAPI 0.3

Please provide any additional information below.

Original issue reported on code.google.com by leonardo...@pdic.com on 10 Nov 2009 at 3:27

GoogleCodeExporter commented 8 years ago
I have found the solution by myself.

I have included the Proxy Settings to my project, once the network I'm 
currently 
working is behind proxy's security.

find a copy of the code below:

            System.Net.WebProxy Proxy = new System.Net.WebProxy("192.168.0.1", 8080);
            Proxy.UseDefaultCredentials = true;
            Proxy.Credentials = System.Net.CredentialCache.DefaultCredentials;

            System.Net.WebRequest.DefaultWebProxy = Proxy;

Original comment by leonardo...@pdic.com on 10 Nov 2009 at 4:14

GoogleCodeExporter commented 8 years ago

Original comment by iron9li...@gmail.com on 12 Nov 2009 at 3:57