11 Topics

Member Avatar for
Member Avatar for Dani

A couple of years ago, I began using a Cloudflare worker to track my Googlebot traffic in Google Analytics. The initial code I used, and thought process to get there, is [here](https://www.daniweb.com/digital-media/digital-marketing/threads/522837/bot-traffic-in-google-analytics), but here's what my code looks like today: const analyticsId = 'UA-98289-3' addEventListener('fetch', event => { event.passThroughOnException() event.respondWith(handleRequest(event)) …

Member Avatar for Naor
0
126
Member Avatar for bprosic

This code works but I don't know how to dismantle this "sausage" code. async function showAllFilters(qry, arrayParams) { // params is [] let result; try { result = await db.query(qry, arrayParams); } catch (error) { console.log("showAllFilters error: "); console.error(error); } return result; } router.get('/', function (req, res) { // localhost:5000/api/filter …

Member Avatar for maxhowells7
0
299
Member Avatar for Dani

It's here, here at last! Only about a decade too late, and about six or seven years after Google announced they were working on it. AdSense now offers asynchronous code, finally. It looks something like this: <script async src="http://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script> <ins class="adsbygoogle" style="display:inline-block;width:728px;height:90px" data-ad-client="ca-pub-xxxxxx" data-ad-slot="xxxxxx"></ins> <script> (adsbygoogle = window.adsbygoogle || []).push({}); …

Member Avatar for zardari
1
368
Member Avatar for satnav_8

Hey, I'm working on a simple command line program to download some files. I already made a Win Forms version, but wanted to do a command line version. The Win Forms app works exactly as it should, but I'm having some trouble with the command line app. Heres my code: …

Member Avatar for satnav_8
0
5K
Member Avatar for rahul_njain

I have added a web service reference in my C# metro Style App and it is added successfully. But when I try to call the async method it tells to use await before the function call. But when I use await it tells 'await' operator can only be used within …

Member Avatar for pritaeas
0
236
Member Avatar for anisha.silva

I have a component TM and it ‘s responsibility is divided to A and B. there is another component query client. Between these component there Is an async communication. I represented the query client and the TM as classes how do I represent the Async communication?

Member Avatar for anisha.silva
0
258
Member Avatar for MonsieurPointer

Hello DaniWebbers, I have the following classes in their respective namespaces; so far so good. When I have received data from the server, the AsyncTcpClient's *DataReceived* event gets raised and the Client's *OnReceivedData* method gets called. Also so far so good. The one thing that does not work (and which …

0
138
Member Avatar for astian

Hi, again Im hoping to be on the right topic. So here it is: I am publishing a SilverlightApplication that uses a WCF service to read from a database. The application uses Bing Maps to visualize some polygons. The thing is, that after I publish it ONLY on some machines …

0
151
Member Avatar for bunnyboy

Yesterday I started playing with Microsoft CTP async library and I came across awaitable pattern ... I followed some tutoral, but I have a newer version of ctp that tutorial was refering to so all info about that was useless. After looking over the internet how the new pattern looks …

Member Avatar for kvprajapati
0
205
Member Avatar for gravexxx

I am not showing all the code it is not necassary. TheInternets : TWebBrowser; I wrote a program to navigate to a server that my friend has up. Then it should get a result and display it. This takes about a second to execute which is really bad for my …

Member Avatar for Wolfgan
0
156
Member Avatar for cavpollo

Hi there, I'm using asp.net with the ScriptManager control from AJAX and some Javascript code., and came across this weird problem. The thing is that I have a page in which i placed the script manager and refreshed according to the interval of a timer. Some images are placed inside …

0
87

The End.