Пример #1
0
		public void SendTrackPoint (AdformTrackPoint adFormTrackPoint)
		{
			
			if (_initOptions == null) {
				SystemLogger.Log (SystemLogger.Module.PLATFORM, "Adform [SendTrackPoint] - Error: no init options loaded, please check if you have the 'adform-config.xml' file in your project");
				return;
			}

			try {
				nint tpID = _initOptions.TrackingID;

				TrackPoint trackPoint = new TrackPoint(tpID);
				trackPoint.SetSectionName(adFormTrackPoint.SectionName);

				if(adFormTrackPoint.CustomParameters != null) {
					foreach (AdformCustomParameter cp in adFormTrackPoint.CustomParameters) {
						trackPoint.AddParameter(cp.Name, cp.Value);
					}
				}

				SystemLogger.Log (SystemLogger.Module.PLATFORM, "Adform [SendTrackPoint] to id: " + tpID);

				AdformTrackingSDK.SharedInstance ().SendTrackPoint(trackPoint);

			} catch (Exception ex) {
				SystemLogger.Log (SystemLogger.Module.PLATFORM, "EXCEPTION Adform SendTrackPoint... ", ex);
			}
		}
Пример #2
0
		public override void FinishedLaunching (UIKit.UIApplication application, Foundation.NSDictionary launchOptions)
		{
			try {

				SystemLogger.Log (SystemLogger.Module.PLATFORM, "Adform Start tracking [" + _initOptions.TrackingID + "]...");
				AdformTrackingSDK.SharedInstance ().StartTracking (_initOptions.TrackingID);


				string sectionName = "Download";
				SystemLogger.Log (SystemLogger.Module.PLATFORM, "Adform Tracking Point with Section [" + sectionName + "]...");

				AdformTrackPoint tPoint = new AdformTrackPoint();
				tPoint.SectionName = sectionName;
				
				this.SendTrackPoint(tPoint);

			} catch (Exception ex) {
				SystemLogger.Log (SystemLogger.Module.PLATFORM, "EXCEPTION Adform Start tracking... ", ex);
			}
		}