0

I am trying to implement AdColony ads into a new app I'm writing. I have followed the SDK integration guide, but am getting cant resolve symbol issues.

Per the guide I have added the following to my manifest:

<activity android:name="com.jirbo.adcolony.AdColonyOverlay"
android:configChanges="keyboardHidden|orientation|screenSize"
android:theme="@android:style/Theme.Translucent.NoTitleBar.Fullscreen" />

<activity android:name="com.jirbo.adcolony.AdColonyFullscreen"
android:configChanges="keyboardHidden|orientation|screenSize"
android:theme="@android:style/Theme.Black.NoTitleBar.Fullscreen" />

<activity android:name="com.jirbo.adcolony.AdColonyBrowser"
android:configChanges="keyboardHidden|orientation|screenSize"
android:theme="@android:style/Theme.Black.NoTitleBar.Fullscreen" />

In my manifest all 3 have the same issue, in the android:name= field,everything but com is red and hovering says "Cannot resolve symbol 'jirbo'", "Cannot resolve symbol 'adcolony'", "Cannot resolve symbol 'AdColonyOverlay'", etc etc.

Manifest Screenshot

I have added the SDK libs to my projects libs folder. I also have the issue in my activity.

import com.jirbo.adcolony.*;

In that, the jirbo gives the cannot resolve symbol issue. Import Screenshot

Dependencies in build.gradle: gradle

Per comment, added to gradle, tried with both direct copy/paste leaving as

compile name: 'fyber-mediation-adcolony-[version]' , ext: 'aar'

as well as

compile name: 'fyber-mediation-adcolony-2.2.2' , ext: 'aar'

neither works, throws the following error on sync: gradle error

  • Have you tried restarting Android Studio or Cleaning project? Show me if you have `compile name: 'fyber-mediation-adcolony-[version]' , ext: 'aar'` on your gradle – Skizo-ozᴉʞS ツ Jun 08 '15 at 15:14
  • I have restarted Android Studio, done an invalidate and restart, and cleaned project. I don't have that line in gradle as their setup guide does not say to do so. I will add it and see if that fixes it. – DEF Software Solutions Jun 08 '15 at 15:21
  • editing OP to show gradle – DEF Software Solutions Jun 08 '15 at 15:31
  • Have you read [this](http://developer.fyber.com/content/android/rewarded-video/adding-networks/adcolony/)? or saw [this](https://github.com/AdColony/AdColony-Android-SDK/wiki/API-Details)? – Skizo-ozᴉʞS ツ Jun 08 '15 at 15:38
  • followed instructions in first link and now have even more errors lol, starting to think i should just go with an ad service that actually gives proper setup instructions – DEF Software Solutions Jun 08 '15 at 16:08

2 Answers2

0

I was having the same problem. I simply ignored the "red jirbo" and ran the app on device. It ran successfully and AdColony log said:

I/AdColony: ==== Configuring AdColony 2.3.5 with app/zone ids: ====
I/AdColony: <app ID used in AdColony.configure()>
I/AdColony: <zone ID used in AdColony.configure()>

Unfortunately, the "jirbo" and class "AdColony" are still red - but it simply works!

Edit: Clicking on "Sync Project with Gradle Files" in Android Studio fixed it! (The icon on the left of "AVD Manager")

Mohit Singh
  • 1,452
  • 1
  • 18
  • 27
0

Just add ' maven { url "https://adcolony.bintray.com/AdColony" } ' to you project gradle under repositories

  • This post isn't an actual attempt at answering the question. Please note StackOverflow doesn't work like a discussion forum, it is a Q&A site where every post is either a question or an answer to a question. Posts can also have comments - small sentences like this one - that can be used to critique or request clarification from an author. This should be either a comment or a new question – ρяσѕρєя K Jul 21 '19 at 13:10