My method is to create a new AdWordsUser instance for that user. 
AdWordsUser has a constructor that takes a dictionary with key-value pairs 
- the values in that dictionary will override the values in app.config.

For instance:
            MyUser = new AdWordsUser(new Dictionary<string, string>
            {
                { "ClientCustomerId", MyCustomerId }
            });

Note: You can also pass other key-values pairs of setting you want to 
override. For instance,if you have batch-program working every night or so, 
you way also want to pass a RefreshToken so your program does not have to 
deal with logging in.

This is my preferred way. I know another way: after creating a service 
using your AdWordsUser, you can change its CientCustomerId. I can't 
remember now where, but some debugging will reveal where every service 
stores its ClientCustomerId. However, I don't know how to proceed with 
reports.

Hope this helps.
On Thursday, November 29, 2018 at 8:37:51 AM UTC+1, [email protected] 
wrote:
>
> Hi 
>
> I am using DotNet client library c# to download performance report and 
> also other activity related to this for my customer account,  but when i 
> want to do the same for my other customer
>
> every time i have to got app.config and change ClientCustomerId(<add 
> key="ClientCustomerId" value="xxx-xxx-xxxx"/>).
>
> Can i pass it from c# code ? instead of app.config
>

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/f3e6418c-a2aa-441f-acb8-8fecffe0152a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
  • ... vibhesh
    • ... 'Peter Oliquino (AdWords API Team)' via AdWords API and Google Ads API Forum
    • ... Zweitze
      • ... 'Peter Oliquino (AdWords API Team)' via AdWords API and Google Ads API Forum
      • ... vibhesh

Reply via email to