Hi, Could you also open a feature request at http://code.google.com/p/google-api-adwords-dotnet/issues/list to make the library more com interop friendly? I have seen classic ASP developers also ask similar questions in the past, may be having a com-interop wrapper library for AdWords .NET library can benefit some of them.
Cheers, Anash P. Oommen, AdWords API Advisor. On Tuesday, 22 May 2012 21:20:42 UTC+5:30, groucho wrote: > > Hi, > > Thanks for your answer. You're right and actually the main issue is about > static classes (like AdWordsService.v201109_1.CreateAccountService) that > are not handled by COM and VBA. > > Your solution will certainly work, and should be not to hard to code (I'm > not a .NET developer, but it seems reachable). > > Thanks, > > - DB. > > Le mardi 22 mai 2012 16:21:33 UTC+2, Anash P. Oommen a écrit : >> >> Hi, >> >> I've never tried doing com interop with the AdWords API .NET library, but >> I think you will have better chances of making it work if you were to write >> a simple com-interop utility library in VB.NET/C# that uses the client >> library to perform tasks and call that utility library from VBA. If you use >> the library as such, I suspect you will have issues when VBA tries to call >> overloaded constructors, methods, etc. VBA isn't as object-oriented as >> VB.NET. >> >> See http://jumbloid.blogspot.in/2009/12/making-net-dll-com-visible.html for >> details on how to write a comvisible assembly. >> >> Cheers, >> Anash P. Oommen, >> AdWords API Advisor. >> >> On Sunday, 20 May 2012 23:34:06 UTC+5:30, groucho wrote: >>> >>> Hi all, >>> >>> Another question concerning VBA access to Adwords API in the forum. I >>> hope I could write a complete walkthrough for VBA user after that. >>> >>> I've recompiled the Common and Adwords librairies with COM visibility, >>> and trying to make a simple AccountCreation example conversion from VB to >>> VBA but I can't (don't know more exactly) how to call from VBA the >>> ServiceSignature AdWordsService.v201109_1.CreateAccountService. I >>> believe it's more a VB2VBA language conversion problem (object >>> instantiation) than a API issue. >>> >>> Private Sub CommandButton1_Click() >>> >>> Dim user As Google_AdWords.AdWordsUser >>> >>> Set user = New Google_AdWords.AdWordsUser >>> >>> ' Get the CreateAccountService. >>> Dim createAccountService As >>> Google_AdWords.Google_Api_Ads_AdWords_v201109_1_CreateAccountService >>> >>> Set createAccountService = user.GetService(...) >>> >>> The original code is : >>> >>> Dim createAccountService As CreateAccountService = >>> user.GetService( _ >>> AdWordsService.v201109_1.CreateAccountService) >>> >>> Does anyone know how to go from the VB to the VBA code ? >>> >>> Very precise question, but it seems to be my last issue before using >>> adwords api from VBA (Excel, Access)... >>> >>> Thanks for your help ! >>> >>> - DB. >>> >> -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and discussion group: http://adwordsapi.blogspot.com http://groups.google.com/group/adwords-api =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ You received this message because you are subscribed to the Google Groups "AdWords API Forum" group. To post to this group, send email to adwords-api@googlegroups.com To unsubscribe from this group, send email to adwords-api+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/adwords-api?hl=en