Download the free trial version
Basic4android Video
Features
Tutorials and manuals
Showcase
Screenshots

Go Back   Android Development Forum - Basic4android > Basic4android > Additional libraries and official updates
Documentation Wiki Register Members List B4P Search Today's Posts Mark Forums Read

Additional libraries and official updates Users contributed libraries and official updates. This forum is open for licensed users only.

Google Analytics library

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 08-15-2011, 01:43 PM
Erel's Avatar
Administrator
 
Join Date: Apr 2007
Posts: 15,689
Awards Showcase
Basic4ppc Founder 
Total Awards: 1
Default Google Analytics library

The attached library allows you to add the power of Google Analytics to your application and track its usage.
In order to use this library you should download the native analytics library: Downloads - Google Analytics for Mobile - Google Code
Unzip the zip file and copy libGoogleAnalytics.jar to your internal libraries folder.
You will need to reference both Analytics and libGoogleAnalytics libraries.
See the formal Google documentation for more information: Google Analytics SDK for Android - Google Analytics for Mobile - Google Code

Installation instructions:
- Unzip the attached file and copy all three files to the internal libraries folder (default): C:\Program Files\Anywhere Software\Basic4android\Libraries
Also copy the native jar file as mentioned above.
Attached Files
File Type: zip Analytics.zip (2.6 KB, 451 views)
Reply With Quote
  #2 (permalink)  
Old 08-15-2011, 04:45 PM
Basic4ppc Veteran
 
Join Date: Jun 2011
Posts: 298
Default

As a side note, and no reflection in this new library - but would this increase bandwidth usage of the app?
Reply With Quote
  #3 (permalink)  
Old 08-15-2011, 05:20 PM
Erel's Avatar
Administrator
 
Join Date: Apr 2007
Posts: 15,689
Awards Showcase
Basic4ppc Founder 
Total Awards: 1
Default

Yes. The analytics code sends information to Google servers. You can however manually send the information. This allows you to only send information when the device is connected over WIFI for example.
Reply With Quote
  #4 (permalink)  
Old 08-25-2011, 08:15 AM
Basic4ppc Veteran
 
Join Date: Sep 2007
Posts: 480
Default

Cannot get it to work, gives me some errors. Do you have a sample?
Reply With Quote
  #5 (permalink)  
Old 08-25-2011, 03:17 PM
Erel's Avatar
Administrator
 
Join Date: Apr 2007
Posts: 15,689
Awards Showcase
Basic4ppc Founder 
Total Awards: 1
Default

Which error do you get?
There is an example here: Basic4android - Analytics
Reply With Quote
  #6 (permalink)  
Old 08-26-2011, 07:50 AM
Basic4ppc Veteran
 
Join Date: Sep 2007
Posts: 480
Default

Hi,

I'm using the trackevent stuff and during compilation I get the following error:

tracker.TrackEvent (\
javac 1.6.0_17
src\nl\openhanced\com\analytics\main.java:228: cannot find symbol
symbol : method TrackEvent(java.lang.String,java.lang.String,java. lang.String,int)
location: class anywheresoftware.b4a.objects.AnalyticsTracker
mostCurrent._tracker.TrackEvent("Clicks","Button", "Test",(int)(4));
^
1 error
Reply With Quote
  #7 (permalink)  
Old 08-26-2011, 12:11 PM
Erel's Avatar
Administrator
 
Join Date: Apr 2007
Posts: 15,689
Awards Showcase
Basic4ppc Founder 
Total Awards: 1
Default

Have you added the libGoogleAnalytics library?
Reply With Quote
  #8 (permalink)  
Old 08-26-2011, 03:08 PM
Basic4ppc Veteran
 
Join Date: Sep 2007
Posts: 480
Default

I have and the .jar is also in the libraries folder.
Reply With Quote
  #9 (permalink)  
Old 08-26-2011, 03:11 PM
Erel's Avatar
Administrator
 
Join Date: Apr 2007
Posts: 15,689
Awards Showcase
Basic4ppc Founder 
Total Awards: 1
Default

Maybe there is a bug in the library. Does this error only happen with TrackEvent calls?
Reply With Quote
  #10 (permalink)  
Old 09-01-2011, 12:08 PM
Basic4ppc Veteran
 
Join Date: Sep 2007
Posts: 480
Default

Erel,

It only happens with the TrackEvent stuff. The PageView does not generate this error during compilation.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Wish: Google Analytics support Inman Bugs & wishlist 3 08-15-2011 10:54 PM
Google +1 Erel Basic4android Updates and Questions 15 07-31-2011 04:30 PM
Google Analytics SDK wrapper bluedude Basic4android Updates and Questions 0 06-10-2011 02:37 PM
Get google name NetStorm Basic4android Updates and Questions 0 05-01-2011 10:03 PM
b4a and google api Cor Basic4android Updates and Questions 1 01-19-2011 05:46 AM


All times are GMT. The time now is 10:02 PM.


Powered by vBulletin® Version 3.6.12
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0