Hi Josh

1) Yes, it is intentional as I first believed that by placing the jar files 
under the libs folder that they would get their respective classpath 
automatically.

2) I've updated the build file as follows:

implementation 'com.google.api-ads:ads-lib:3.12.0'
implementation 'com.google.api-ads:adwords-axis:3.12.0'

I still have the RemoteException problem..

Kind regards
Richard

Den onsdag 7 mars 2018 kl. 15:10:42 UTC+1 skrev Josh Radcliff (AdWords API 
Team):
>
> Hi Richard,
>
> Thanks for sending over that info. I noticed two things about your 
> *dependencies* section:
>
> 1. The dependencies for the Google Ads APIs Client Library for Java are 
> commented out:
>
>     //implementation 'com.google.api-ads:ads-lib:3.10.0'
>     //implementation 'com.google.api-ads:adwords-axis:1.38.0'
>
> Was that intentional, and was that the state of the config when you tried 
> to run the example? With those two lines commented out, none of the 
> library's classes will be on the classpath.
>
> 2. The versions specified for the two Google Ads APIs Client Library for 
> Java do not match. For example, if you're using *3.10.0* for *ads-lib*, 
> you should also use *3.10.0* for *adwords-axis*. Although Maven requires 
> separate versions for each dependency, in practice we always keep all of 
> our Maven artifacts on the same version. The latest version for the library 
> is 3.12.0 <https://github.com/googleads/googleads-java-lib/releases>.
>
> Thanks,
> Josh, AdWords API Team
>
> On Wednesday, March 7, 2018 at 3:07:15 AM UTC-5, goldenmaza wrote:
>>
>> Hi Josh
>>
>> According to the controlpanel I have Java 8 Update 162.
>>
>> build.gradle under app folder:
>> apply plugin: 'com.android.application'
>>
>> android {
>>     compileSdkVersion 26
>>     buildToolsVersion "26.0.2"
>>     defaultConfig {
>>         applicationId "yada.yada"
>>         minSdkVersion 23
>>         targetSdkVersion 26
>>         versionCode 1
>>         versionName "1.0"
>>         testInstrumentationRunner 
>> "android.support.test.runner.AndroidJUnitRunner"
>>     }
>>     buildTypes {
>>         debug {
>>             minifyEnabled false
>>             proguardFiles getDefaultProguardFile('proguard-android.txt'), 
>> 'proguard-rules.pro'
>>         }
>>         release {
>>             minifyEnabled false
>>             proguardFiles getDefaultProguardFile('proguard-android.txt'), 
>> 'proguard-rules.pro'
>>         }
>>     }
>> }
>>
>> repositories {
>>     jcenter()
>>     google()
>> }
>>
>>
>> dependencies {
>>     implementation fileTree(include: ['*.jar'], dir: 'libs')
>>     implementation 'com.android.support:design:26.0.2'
>>     implementation 'com.android.support:appcompat-v7:26.0.2'
>>     implementation 'com.google.android.gms:play-services-maps:11.8.0'
>>     //implementation 'com.google.api-ads:ads-lib:3.10.0'
>>     //implementation 'com.google.api-ads:adwords-axis:1.38.0'
>>     implementation 'com.android.support:appcompat-v7:26.0.2'
>>     implementation 
>> 'com.android.support.constraint:constraint-layout:1.0.2'
>>     testImplementation 'junit:junit:4.12'
>> }
>>
>> Thank you for your time! :)
>>
>> Kind regards
>> Richard
>>
>> Den tisdag 6 mars 2018 kl. 22:36:16 UTC+1 skrev Josh Radcliff (AdWords 
>> API Team):
>>>
>>> Hi Richard,
>>>
>>> Would you mind sharing your Gradle config so I can see how you're 
>>> bringing in the library dependencies? Also, just to rule certain things 
>>> out, could you let me know which version of Java you're using?
>>>
>>> Thanks,
>>> Josh, AdWords API Team
>>>
>>> On Tuesday, March 6, 2018 at 3:26:52 AM UTC-5, goldenmaza wrote:
>>>>
>>>> Hi Josh
>>>>
>>>> As I currently sit with Android Studio/Gradle, I would prefer 
>>>> continuing using these, I can skip Gradle for the next project but for now 
>>>> I would like to learn how to solve this Gradle issue.
>>>>
>>>> Oh, by placing the files under the libs folder you set the classpath(s) 
>>>> manually?
>>>>
>>>> The part about the archive I have done already (my other forum post 
>>>> with Dhanya Sundararaju (AdWords API Team) as he suggested the same). But 
>>>> that does not solve the issue I got
>>>> as a result of this inclusion of jar files.
>>>>
>>>> Thank you for your time! :)
>>>>
>>>> Kind regards
>>>> Richard
>>>>
>>>> Den måndag 5 mars 2018 kl. 17:57:57 UTC+1 skrev Josh Radcliff (AdWords 
>>>> API Team):
>>>>>
>>>>> Hi Richard,
>>>>>
>>>>> Thanks - that definitely helps! Could you let me know how you're 
>>>>> managing your dependencies? For example, are you using Maven, Gradle, or 
>>>>> just setting your classpath manually (e.g., by copying dependencies to a 
>>>>> lib folder)?
>>>>>
>>>>> I ask because the error that java.rmi.RemoteException is not in your 
>>>>> classpath indicates that you are missing some key dependencies. If it 
>>>>> helps, you can see the list of dependencies to add for Maven here in 
>>>>> the README 
>>>>> <https://github.com/googleads/googleads-java-lib#maven-artifacts>. If 
>>>>> you aren't using Maven, you can download the 
>>>>> *adwords-axis-jars-and-examples *archive on the releases page 
>>>>> <https://github.com/googleads/googleads-java-lib/releases>, which 
>>>>> contains a *lib* folder with all required dependencies.
>>>>>
>>>>> Thanks,
>>>>> Josh, AdWords API Team
>>>>>
>>>>> On Monday, March 5, 2018 at 9:41:33 AM UTC-5, goldenmaza wrote:
>>>>>>
>>>>>> Hi Josh
>>>>>>
>>>>>> Thank you for your time! :)
>>>>>>
>>>>>> Code and errors are as follows:
>>>>>>
>>>>>> try {
>>>>>>     adWordsHandler = new AdWordsHandler(context);
>>>>>>     adWordsHandler.callAdWordsAPI();
>>>>>>     sales = adWordsHandler.getEntries();
>>>>>>     resourceHandler.addResources(Sale.class.getName(), sales);
>>>>>> } catch (RemoteException e) {
>>>>>>     e.printStackTrace();
>>>>>> } catch (ApiException e) {
>>>>>>     e.printStackTrace();
>>>>>> } catch (Exception e) {
>>>>>>     e.printStackTrace();
>>>>>> }
>>>>>>
>>>>>> public void callAdWordsAPI() throws Exception, ApiException {
>>>>>> ...
>>>>>> AdGroupAdPage entries = adService.get(selector);
>>>>>> ...
>>>>>> }
>>>>>>
>>>>>> Error:(104, 9) error: cannot access RemoteException
>>>>>> class file for java.rmi.RemoteException not found
>>>>>>
>>>>>> Error:(61, 52) error: incompatible types: ApiException cannot be 
>>>>>> converted to Throwable
>>>>>>
>>>>>> Error:(89, 46) error: cannot access Remote
>>>>>> class file for java.rmi.Remote not found
>>>>>>
>>>>>> Take care! :)
>>>>>>
>>>>>> Kind regards
>>>>>> Richard
>>>>>>
>>>>>>
>>>>>> Den måndag 5 mars 2018 kl. 15:06:46 UTC+1 skrev Josh Radcliff 
>>>>>> (AdWords API Team):
>>>>>>>
>>>>>>> Hi Richard,
>>>>>>>
>>>>>>> Could you share the error you're getting from the compiler? I want 
>>>>>>> to make sure this is the same issue as mentioned below, so it would be 
>>>>>>> helpful to have more details for your particular case.
>>>>>>>
>>>>>>> Thanks,
>>>>>>> Josh, AdWords API Team
>>>>>>>
>>>>>>> On Sunday, March 4, 2018 at 5:03:59 PM UTC-5, goldenmaza wrote:
>>>>>>>>
>>>>>>>> Hello Josh
>>>>>>>>
>>>>>>>> I know you answered this a while ago but I have the same problem. 
>>>>>>>> I've read 
>>>>>>>> https://docs.oracle.com/javase/8/docs/technotes/tools/windows/classpath.html
>>>>>>>>  
>>>>>>>> and even if this page explains
>>>>>>>> what a classpath is, it was not written for Google AdWords API. So 
>>>>>>>> what do I need to do regarding this classpath issue? What file(s)? I 
>>>>>>>> also 
>>>>>>>> sit with Android Studio.
>>>>>>>>
>>>>>>>> Kind regards
>>>>>>>> Richard
>>>>>>>>
>>>>>>>> Den tisdag 12 maj 2015 kl. 15:47:23 UTC+2 skrev Josh Radcliff 
>>>>>>>> (AdWords API Team):
>>>>>>>>>
>>>>>>>>> Hi,
>>>>>>>>>
>>>>>>>>> That error suggests that your classpath is not configured 
>>>>>>>>> correctly. Please check out the section of our README on 
>>>>>>>>> configuring dependencies 
>>>>>>>>> <https://github.com/googleads/googleads-java-lib#for-using-jars> and 
>>>>>>>>> let me know if you still have questions.
>>>>>>>>>
>>>>>>>>> Thanks,
>>>>>>>>> Josh, AdWords API Team
>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and Google+:
https://googleadsdeveloper.blogspot.com/
https://plus.google.com/+GoogleAdsDevelopers/posts
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

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
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
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/5bb144b8-44f3-440b-b955-911127f17485%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
  • Re: GetIdeas exam... goldenmaza
    • Re: GetIdeas... 'Josh Radcliff (AdWords API Team)' via AdWords API Forum
      • Re: GetI... goldenmaza
        • Re: ... 'Josh Radcliff (AdWords API Team)' via AdWords API Forum
          • ... goldenmaza
            • ... 'Josh Radcliff (AdWords API Team)' via AdWords API Forum
              • ... goldenmaza
                • ... 'Josh Radcliff (AdWords API Team)' via AdWords API Forum
                • ... goldenmaza
                • ... 'Josh Radcliff (AdWords API Team)' via AdWords API Forum
                • ... goldenmaza
                • ... 'Josh Radcliff (AdWords API Team)' via AdWords API Forum
                • ... goldenmaza
                • ... 'Josh Radcliff (AdWords API Team)' via AdWords API Forum
                • ... goldenmaza
                • ... 'Josh Radcliff (AdWords API Team)' via AdWords API Forum
                • ... goldenmaza
                • ... 'Josh Radcliff (AdWords API Team)' via AdWords API Forum

Reply via email to