Google Analytics for Desktop Application - c#

I wanted to have analytics for my upcoming alpha release so I can analyse how the program gets used, how often errors occur and so on.
Implementing an own approach of such is quite difficult and time consuming. Today I saw that the developers of the game "Rust" have implemented Google Analytics to track session times, average framerates based on system architecture and so on. So obviously desktop applications can use GA for that.
Now I did some research and I haven't found out anything. I have the C# assembly for Analytics V3 but I don't get how I can use it to report any data. I created a Developers Console project and added the Analytics API to the project.
But now? Analytics has only Website or Mobile App properties, authentication has only website, server or mobile apps but nowhere is something mentioned about desktop apps.
I've seldom seen such well undocumented features. Not even google spits out helpful information about the usage. All tutorials I can find are about ASP.Net websites and hence not helpful.
Does anybody know how this works? Is there any support planned on the part of Google? Is it even allowed (I guess so if Rust's developers use it)?
Thanks for any help!

You can use a packaged lib available on NuGet which does most of the heavy lifting of sending data to google analytics. The lib uses performance protocol as mentioned by #osowskit.
Here is the link to one of them. Its open sourced so you can modify the code to your needs.
https://www.nuget.org/packages/GoogleAnalyticsTracker/
Source - https://github.com/maartenba/GoogleAnalyticsTracker

Rust game is based on Unity and Google has created Google Analytics Plugin for Unity that "...allows game developers to easily implement Google Analytics in their Unity games on all platforms, without having to write separate implementations.". That is probably what Rust developers are using.
The closest support for non-Unity desktop applications you can get from Google is Analytics Measurement Protocol which allows you "to send raw user interaction data directly to Google Analytics servers". That data could be visited screens/views, events, exceptions etc...For the comprehensive protocol description see Developer Guide.

Related

Facebook integration with Windows C# UWP Program

I have a Windows C# UWP Application that was integrated with Facebook (It allowed users to post Greetings card images into their timeline) and previously used the Sharing Charm feature between Windows UWP apps. Facebook removed the sharing functionality from their app some time ago so I now need to recode the functionality using a Facebook SDK but don't know quite where to start.
First question is what is the best API to use, as there seems to be multiple options. I have seen "winsdkfb" and also "facebook" but all the documentation I have seen seems well out of date. Could someone point me to the best Nuget API and an up to date tutorial?
My app is coded for UWP Win 10 Build 14393 and Id rather not go through a whole rebuild into something like .Net Core at this stage as its a big complex app.

Displaying ads on C# desktop applications?

So I've been trying to figure out what's going on with ads in desktop applications, and looking at APIs, Google's API seems low on examples and documentation, and I didn't manage to make any sense out of it, and the Bing API seems to be concerning itself with those who want to be advertised, rather than affiliates. In retrospect, so does Google's.
My currently leading idea is to just drop in a web form in my Windows Forms application, and load the HTML that the Google/Bing/Whoever would give me for my webpage, that should register as the ad being viewed/clicked etc. But that seems a bit amateurish, I would imagine there would be a component ready for displaying ads.
So the question is, do advertising APIs from the major players (Google, Bing, Amazon etc) target affiliates or not? If not, does the web browser component method work, or may it lead to having the account revoked due to suspicious use of the HTML code (to prevent scam etc)?
Additionally, I found out that Amazon forbids use of the ads in applications not specifically related to Amazon itself, it seems alright to do so for Bing and Google but I can't find conclusive proof of it, does anyone know what's going on with that?

Accessing iOs file system from Windows in C#

Firstly I tried to access it with SSH, but running an ls command and then getting the output stream takes too much time, and also required packages to be installed on the device.
Is there a way to access a USB connected iOs device file system from Windows any other way? I also read about Xamarin, but as I can see it's only good for developing apps for iOs.
Edit: The possible duplicate question partly solved my answer, however I needed to find a compiled version for Windows (see comments below).
Our company had a lot of trouble with this; at first, we could not find any available C#/.NET library to do this. We ended up writing our own library using external library calls, but it had numerous stability issues and we gave up. Eventually, we found a library that provided a very good code base: MK.Mobile.Device.Lite
The documentation is scarce, but the code is quite self-explanatory; the library provides LOTS of functions for accessing iDevices over a USB cable, and the project maintainer stated that network capabilities may become available in the foreseeable future.
We have incorporated this great open source library into many of our applications, and the implementation is quite simple: you register an event that fires when a device is plugged in/unplugged, and you can call your code on those events.
The functions are extensive, allowing code to fetch many different aspects of the device. If you contact them, there is a version of the library that is even more powerful than the free libary; however it is not open source.
Good luck using this library. We have had great success, and have been able to use it in many of our applications.
Note:
After using this library, we are now affiliated with the group that develops this library.

Video calling in desktop application .net

I am working on a wpf application which is suppose to have video calling feature. So I am going for Skype to provide me with the solution.
I am using Skype4COM library to do it. I got all the friends from Skype in my application, I can make call to my friends and even can do video call, but I cant control streaming. Video is being shown in Skype window, I want to show it inside my application like a part of my application.
I don't even know which control should I use to handle the video streaming.
If there is another better way or free way to add video calling in a WPF application. I am ready to change my preferences.
I had previous plans to use Web browser control and go for WebRTC but that does not support IE and believe there is no web browser control from Mozilla and Chrome.
Videoconferencing is not trivial to implement. You have to first look at a signalling protocol like SIP or XMPP which would provide infrastructure to maintain a list of 'friends' and whether they are online or offline. The signalling infrastructure would also let you place a call and alert you when you receive a call. And then there is the question of actually flowing video/audio between two endpoints. There is no single solution that you can plug into your app.
You can look at Google's Libjingle or ConferenceXP for a starting point.
To establish a video conference you would need the following information:
Whom can you call? This is your friends list. You would need a mechanism to add friends to your list and ensure that you can only add friends that are willing to communicate with you
How do you establish a communication channel with your friends? For example what is their IP Address, can they support a particular video codec and so on.
Once you have established a way to communicate with your friend, then there is the question of receiving audio and video information and displaying it with correct timing.
For points 1 and 2 you would need what is called a signalling and presence protocol. SIP and XMPP are two very popular open protocol.
For point [3] you would look at a protocol like RTP.
You can google SIP, XMPP and RTP. You would receive a wide variety of literature. Look at the RFC documents for exact information they they can be a bit arcane.
Libjingle is a library written in C++ implements XMPP and RTP
ConferenceXP is a RTP implementation in C# with some basic signalling but I think you can get a start with the examples without really getting into details.
You may or maynot be able to control that screen. If skype decides to share that level of control with you.
But it looks like skype4com library is on a dead end. It will stop working soon. :(
http://gigaom.com/2013/07/13/skype-says-it-will-kill-desktop-api-by-end-of-2013/
http://aragonresearch.com/microsoft-kills-skype-desktop-apis-leaves-developers-scrambling/
I'd recommend you not to invest time on skype4com, but look to other solutions to get the video chat working.
Please go through the following thread, as this discussess few alternative ways for video chatting.
Developing a Video Chat Application with high quality video streaming
Another promising thing is the Bittorent Live. But you will have to wait. It claims
BitTorrent Live is a powerful new web-based live streaming technology.
Designed to eliminate barriers to broadcast, Live is an entirely new
protocol, designed to deliver high quality video to large audiences -
with significant reduction in infrastructure cost and network delays.
http://live.bittorrent.com/
Its not open yet, let see :)

VoIP/SIP Soft Phone C# WPF

I need to write VoIP/SIP Soft Phone in C# using WPF interface with Audio support only.
I need to have call transfer, call conference, and recording of conversations in mp3.
I've looked at VoIP SDK from ABTO LLC, but it is slow at application startup (30 seconds to start application, I think it's related to loading activex part of this sdk).
I've also looked at SIP.Net, but it's only for SIP and doesn't contain components for voice data transfer.
I have very limited time only 2 months from zero to fully working app.
What SDK can I use to accomplish this task?
Windows 7 must be supported.
We have done this using SipekSDK. It's written on top of famous pjSIP open source SIPClient project. It does all the operations you have mentioned in the question.
https://sites.google.com/site/sipekvoip/
What is the Sip server you are going to use ? If its not asterisk, you can have a look of microsoft's Lync here.
You can download the Lync SDK and start exploring. Not just the audio call, Microsoft Lync has features like video call, chat, presence, conference etc.... and ofcourse connectivity to landline/pstn through voip providers
Another interesting article explaining the different SDKs for unified communications can be found here
Edit: If its for Asterisk, Sipek is the only available free opensource but we had lot of problems in installing in clients system like
C folder access
Poor device
support
Port conflict- If any
other voip app like qutecom runs on
5060, then Sipek wont run as the
port is being used already.
I struggled with this exact issue and eventually came across ABTO LLC.
They have an SDK available that supports Win 7, Win XP and can be used in WPF.
We did ask them though to build a separate SDK example for us as we are using ClickOnce for our deployments and so registering external libraries is impossible, but they graciously did it and i think have integrated into their SDK, if not then ask them to give it to you.
We are using a FreeSwitch SIP Server combined with ABTO's library and it is working like a dream. We are doing VoIP, Video and Conferencing and have had no issues at all.
The application I added the VoIP functionality to is a WPF 4 app.

Categories