Event counter with a provided amount instead of 1

thomas_amsler

24-05-2018

We track video completion events using the built in HTML5 "% complete" condition. With this we have the following rules sending events:

  1. 0%: event10 and event15=0
  2. 25%: event11 and event15=25
  3. 50%: event12 and event15=25
  4. 75%: event13 and event15=25
  5. 100%: event14 and event15=25

I was expecting in Analytics that it would accumulate the values of event15 so if the video is watched until the end it would show 100(%). But as there are 5 events I get 5 as the value so it incremented it by 1 for each call. Is it even possible to achieve what I was trying, if yes, how would I need to configure the event or the value?

Accepted Solutions (1)

Accepted Solutions (1)

thomas_amsler

30-05-2018

Ok, there was a missconecption from my side. I accidentally set what I thought to be the value for the event in the serialize from value field. So I was basically missing an option to add values to an event with the GUI. It seems I need to add it in a custom code section.

So I know have the following (this is the video DOM element that triggered the rule):

s.linkTrackVars = 'eVar10';

s.linkTrackEvents = 'event16';

s.eVar10 = datalayer.video.getName(this);

s.events += ',event16=' + datalayer.video.getTimeDelta(this);

Answers (7)

Answers (7)

PratheepArunRaj

Moderator

27-05-2018

Dear Thomas,

To understand the percentage of video viewed, why would you need another event to capture the numeric? One event with an eVar is more than enough.

  1. 0%: event1 and eVar1=0
  2. 25%: event1 and eVar1=25
  3. 50%: event1 and eVar1=50
  4. 75%: event1 and eVar1=75
  5. 100%: event1 and eVar1=100

If you go to eVar1 report and put down the event1, you should able to get the numbers like below.

 

eVar1event1
010
258
506
754
1002

This would be sufficient. Event if you capture the %completion in event, it wont solve your purpose.

Thank You

Arun

thomas_amsler

30-05-2018

I clarified it and it seems we could use the eVar Instances as a counter as well. Though we keep the extra event and leave it as a normal counter.

But still I don't see why it doesn't work with a value. I've seen in the documentation that you need H23 Code, that this works. Where can I see what we are using, maybe this is why it isn't working.

I now also added another event to the milestones, counting the seconds played of the video. But here nothing at all gets tracked. I send it like this for the 25% milestone, whereas event16 should count the seconds and is defined as Numeric (Query String Parameter):

events: event11,event15,event16:14.3

It is defined in DTM in the Events section of the milestone like this:

event11

event15

event16="%custom-videoTimeDelta%"

thomas_amsler

28-05-2018

Thanks for the tips, I need to check with our analytics expert what exactly he wants to achieve with this as I seem to have not grasped the whole picture of his video tracking concept.

hyderziaee

Employee

27-05-2018

Check if your event configuration is set to numeric.

I may be wrong about this, but even if the event is a counter, it would accept numeric values to increase the counter by that number.