Hi,
Is someone able to assist in helping understand how to get this C# example working through my proxy server. I note there is a code sample at http://code.google.com/apis/gdata/articles/proxy%5Fsetup.html#dotnet, that provides some direction, however I'm having trouble regarding how to apply this to the DocListExporter example. In other words:
How do I apply the code concept here (with proxy):
CalendarService service = new CalendarService("CalendarSampleApp");
GDataRequestFactory requestFactory = (GDataRequestFactory)
service.RequestFactory;
WebProxy myProxy = new WebProxy("http://my.proxy.example.com:3128/",true);
// potentially, setup credentials on the proxy here
myProxy.Credentials = CredentialCache.DefaultCredentials;
myProxy.UseDefaultCredentials = true;
requestFactory.Proxy = myProxy;
To the following code from the example:
GoogleClientLogin loginDialog = new GoogleClientLogin(new DocumentsService("GoogleDocumentsSample"), "[email protected]");
if (loginDialog.ShowDialog() == DialogResult.OK)
{
RequestSettings settings = new RequestSettings("GoogleDocumentsSample", loginDialog.Credentials);
settings.AutoPaging = true;
settings.PageSize = 100;
if (settings != null)
{
this.request = new DocumentsRequest(settings);
this.Text = "Successfully logged in";
Feed<Document> feed = this.request.GetEverything();
// this takes care of paging the results in
foreach (Document entry in feed.Entries)
{
all.Add(entry);
}
Also if you know the syntax for how to include the actual proxy username/password that would be cool too.
thanks