Tuesday, February 16, 2016

Windows Services and Event Logs


Short video demonstrating event viewer events created by installing and running a Windows Service.
The course can be seen here "Windows Service Programming in C# .Net For Coders & Students".

Point in showing the Windows event viewer here is to give the student a general sense of how Windows Services operate. The exercise also prepares them for debugging in future, where they might get stuck in a production scenario looking desperately for clues.
If anybody has got any questions on the subject, I'm always available to answer those.

Just by a stroke of sheer luck, I have done a lot of work on Windows services on my full time job. I show how to do it using C# .Net in this course but as a matter of fact I've created Windows Service applications using C++ as well.
That was for a thing that acted as an intermediary between NEC NEAX telephone exchange and Avaya handsets. Our thing would allow users to invoke a call recording web service from their IP phones.
You may get a special discount on the course by redeeming the coupon code HALF



  1. Let us take a quick look into Windows Event Log
  2. I will click start button and type Event Viewer and open it
  3. The event viewer can take a few minutes to load the data
  4. Let’s Expand the node ‘Windows Logs’
  5. I’ll Click the sub-item ‘Application’
  6. I will Look for ‘Udemy Windows Service’ in the ‘Source’ column
  7. When I click on an item in the list, the lower half of the window shows some stuff in ‘General’ and ‘Details’ tab
  8. The General tab will have the message your application would’ve written to the Windows event logs.
  9. Now click on the ‘System’ node under ‘Windows Logs’
  10. If you didn’t install this service a long long while ago, you will be able to find an event related to service install near the top of list view.
  11. In our case, I’ve found the event related to service installation. It says ‘A service was installed in the system.‘

Thursday, February 4, 2016

Automated Testing in Nunit Selenium using C Sharp, Hello World


I've been producing videos instead of text blogs lately. The video shared here is another addition to the same chain. I hope you'll find it useful.

Friday, January 29, 2016

Friday, July 10, 2015

Network Programming course offered by AIOU in BCS programme is wonderful

AIOU-BCS-COURSE-OUTLINE-NETWORK-PROGRAMMING-3487
Network Programming 3487 in list of  BCS courses of AIOU 


I am an Allama Iqbal Open University graduate, I passed BCS in 2005. I've been working as a programmer ever since, although I've changed track a few years ago and moved to automated software testing. I must say Open university has got a very good program in place and if someone's got a fire in their belly, AIOU has got the gasoline to turn it into an inferno. It has produced bright stars like my friend & colleague Akhter Sheikh.

AIOU Network Programming course code 3482

You can check the detailed curriculum of the course here

http://www.aiou.edu.pk/CourseDetail.asp?CID=171&PID=187

This course is using Winsock 2 with VC++ which is not commonly used in the market these days. I suppose using C# .Net instead would have been more beneficial for the students, because it is a widely used programming language.


aiou-network-programming-3482-course-details
Course outline of network programming course







Inclusion of advanced topics like IOCP and QoS is a good move, it will help students to get jobs in software development market.


An online video course about TCP/IP socket programming

Network programming course on AIOU website came to my attention one day while I was casually browsing list of courses included in their bachelor of computer sciences program these days.
My online course about TCP/IP socket programming is hosted on Udemy.com and it can be helpful for people who are either taking this course right now or have taken the course some time in past already.
I have created a free discount 100% coupon for my junior university fellows. You don't pay anything, just click the link given below and watch the stuff. I'm sure it will be worth your time.

The first section of the course explains several important computer networking concepts which are used for socket and network programming. These concepts are universal, which means useful for C++/C#/Java/Python or any other programming language.
The remaining parts of the course show practical coding examples and programming techniques which are useful in general.


Join my online course, its FREE!

I recommend you to sign up for my online course and take a peek, it is totally free(using the link below) and you will get a wealth of information in two hours. Just click the link below!


Udemy Discount Online Learning Course Socket Programming

Asynchronous Socket Programming in C#




Prologue: How I got into network programming?

Before I became automated software testing professional, I luckily had a chance to do network programming in more than one language. I started in C# .Net for a telephony server application that used TCP/IP sockets to share data between a Panasonic POTS PBX (Microsoft TAPI 2.1) and various clients. Later on, I used Winsock in a C++ based project. I even used POSIX sockets for a short project while working with an Alcatel Lucent IP PBX(CSTA).

I had no idea back then that in the years to come I will be using sockets again and again. I used UDP sockets in Java programming language for an Android remote control app(iSymphony 2.1), that was some time in 2012/2013. User data gram sockets are considerably different as compared to connection based TCP/IP sockets.
You don't need to learn C to work on this course.

Socket Java, python socket udp

Saturday, March 21, 2015

Cocos2d-x Animating Objects with OnTouch and RunAction

cocos-2dx-touch-action-code

First of all create a new blank Cocos2d-X C++ project as shown here.
Now follow the previous tutorial(Handle Touch Input in Cocos2d-x Mobile Game) in this series. Don't add the business logic code inside HelloWorld::OnTouchEnded  callback function.

I would love to make this article stand alone by describing all the steps here but I can't do that due to lack of time. I hope it won't hurt much since the other articles are reasonably well written(at least I think so).

Now go inside HelloWorld::OnTouchEnded callback funciton in HelloWorldScene.cpp and add following to the callback

auto mainScene =  getChildByName("mainscene");
auto lblHello = mainScene ->getChildByName("lblHello");

auto vecLocationOfTouch = touch ->getLocation();

CCLOGERROR("onTouchEnded x: %f y: %f", vecLocationOfTouch.x, vecLocationOfTouch.y);


By doing this you will have a handle to the "Hello World!" label you created by following earlier tutorials.

Next we need to animate the label on touch. We will use Cocos2d-x MoveTo action in this case and supply it the vector vecLocationOfTouch.

The exact code to make the label run around the screen chasing your mouse clicks or screen taps is given below.






lblHello ->getActionManager() ->removeAllActions();

auto actMoveTo = MoveTo::create(2.0, vecLocationOfTouch);

lblHello ->runAction(actMoveTo);

You can see the removeAllActions() method call before creating the action, I'm not sure if its necessary but still I kept it there as it's not causing any harm either.

I created a moveTo action and provided it with the speed of the movement as first parameter and the end location of the animation in the second parameter.

I wish I had a decent screen capture software, I would be posting videos of final results too.

Feel free to ask questions and get in touch.