My Professional Profile

I am Johnson Augustine Sr.Software Engineer and System Architect. I have 10 Yrs of hands on expertise in ASP.net MVC 5 , Angular 5 , C# MVC Razor, WPF MVVM , Android , IOS Swift 3 , IOS11 MSSQL,MySQL Database,,PHP,C/C++/Visual C++/G++/QT++,Com,DirectX,Open CV,EMGU CV , embedded System Development , [Raspberry PI]. ,html,Javascript,Jquery,Ajax.CSS , Networking ,Cyber security, Ethical Hacking You can see my professional profile at http://linkedin.com/in/johnsontaugustine Email : johnsonaugustine@live.com

Friday, 6 December 2013

updating raspberry pi bus speed

updating raspberry pi bus speed by enable SPI kernal modules will increase 10 mhz to 16 mhz from the config [ raspi-config ]

How to give more abilities to raspberry pi embedded board

To  give more abilities to raspberry pi embedded board just over clock the cpu by typing sudo raspi-config

then select the option overclock

also you can enable SPI kernal modules from config [ raspi-config] and update the kernal and firmware to latest 

Redirect http request to https in plesk/cpanel/hsphere control panels and IIS and Apache

Redirect http request to https in plesk/cpanel/hsphere control panels and IIS and Apache simply use the following script

open a note pad , and just create an html page as index.html , then put the following html

<html>
<head><title>Redirecting...</title></head>
<script language="JavaScript">
function redirectHttpToHttps()
{
       var httpsURL= "redirect url to https";
    window.location = httpsURL;
}
redirectHttpToHttps();
</script>
<body>
</body>
</html>


If you are using asp.net pages you can set a rule in web.config

<rule name="HTTP to HTTPS redirect" stopProcessing="true">
  <match url="(.*)" />
    <conditions>
      <add input="{HTTPS}" pattern="off" ignoreCase="true" />
    </conditions>
  <action type="Redirect" redirectType="Found" url="https://{HTTP_HOST}/{R:1}" />
</rule>

Saturday, 23 November 2013

Google Web designer

Google has relesed beta version of a tool for web design using html,java script,jquery etc , It is much simple and easy to use

Download from http://www.google.com/webdesigner

What is new update in android

Wow! Google released new IDE for Android named android studio , It is not much stable but google done a great job ,
Download android studio , it is much user friendly than Eclipse 

Cloud computing services or what is cloud computing means?

The basic idea of the cloud is always the same. It is a form of technology that allows enterprises, and small business alike,  to run applications that are housed away from the enterprises itself. In spite of this shared basic definition, however, there are several different types of cloud computing.

Web Based Cloud Computing. With this type of cloud computing, companies can use the functionality offered by a web service, and they do not have to develop a full application for their needs.

Infrastructure as a Service (IaaS). With IaaS, organizations have access to the unlimited storage potential of the cloud. They can grow and shirk their storage space as needed. This means that they do not have to worry about having dedicated servers on site. It also means that they can weather increased use of their sites or applications as needed.

Software as a Service (SaaS). This type of cloud computing is also referred to as software on demand. It can be used my many different people for a variety of functions. A popular example of SaaS is Google docs. SaaS allows people to access the functionality of a particular software without worrying about storage or other issues.

Platform as a Service (PaaS). With platform as a service, organizations can run their own software without having to worry about maintaining hard drives and servers. Instead, they can run their own applications on the cloud service’s platform.

Utility Services. This is ideal for companies who need to store a lot of data. With this type of cloud computing, companies can store all of their data remotely, and they can even create a virtual data centre.

Managed Services. Managed services are not applications that are used by the members of an organization. Instead, these are applications that are utilized by the cloud provider. Perhaps the most obvious example of a managed service is an anti-spam service.

Service Commerce. A perfect blend of Software as a Service and Managed Services, Service Commerce creates a hub of applications that can be used by an organization’s members or a company’s employees. With service commerce, organizations can set up the applications that they need along with the support that they desire.

The many different types of cloud computing mean that enterprises can easily find what they need to support their growth and potential.

The main cloud service providers are : Microsoft, Amazon, Softlayer, Scibero, HP , google etc.


WHMCS in plesk /Cpanel is not working showing error 500

WHMCS is not working showing error 500 ( Fast cgi execution terminated)

This is due to the PHP version, please upgrade your php version to higher.

How to check a software dependency of an executable

To do this just use dependency walker  softwareDependency Walker 2.2 Dependency Walker 2.2

How to open two main window simultaneously in QT

To do this just make one main window as mode less 

Space key press is not working in QT GUI app

Space key press  is not  working in QT GUI app , Why ?

Your controls in the form might have strong focuss , so you should remove the strong focus of all controls and then just give strong focus to form from properties in the right side . This will fix the problem

Wednesday, 13 November 2013

How to append two strings in C++/QT

To append two strings in qt just use .append () function

Eg : str.append();

Thursday, 7 November 2013

Key press event in QT

#include<QEvent>

namespace Ui {
    class MainWindow;
}

class MainWindow : public QMainWindow {
    Q_OBJECT
public:
       MainWindow(QWidget *parent = 0);
    ~MainWindow();

protected:
   
      void keyPressEvent(QKeyEvent *event);
private:
    Ui::MainWindow *ui;
 
private slots:
 
};

#endif // MAINWINDOW_H

.cpp file
=======

void MainWindow::keyPressEvent(QKeyEvent *event)
 {
     if(event->key() == Qt::Key_Escape)
        {
            qDebug() << "ESC";
        }
     if(event->key() == Qt::Key_Q)
        {
            qDebug() << "key q";
        }

 }

How to create Socket communication in C++ Linux Based application server socket

#include <iostream>
#include <cstring>      // Needed for memset
#include <sys/socket.h> // Needed for the socket functions
#include <netdb.h>      // Needed for the socket functions

int main()
{

    int status;
    struct addrinfo host_info;       // The struct that getaddrinfo() fills up with data.
    struct addrinfo *host_info_list; // Pointer to the to the linked list of host_info's.

    // The MAN page of getaddrinfo() states "All  the other fields in the structure pointed
    // to by hints must contain either 0 or a null pointer, as appropriate." When a struct
    // is created in c++, it will be given a block of memory. This memory is not nessesary
    // empty. Therefor we use the memset function to make sure all fields are NULL.
    memset(&host_info, 0, sizeof host_info);

    std::cout << "Setting up the structs..."  << std::endl;

    host_info.ai_family = AF_UNSPEC;     // IP version not specified. Can be both.
    host_info.ai_socktype = SOCK_STREAM; // Use SOCK_STREAM for TCP or SOCK_DGRAM for UDP.
    host_info.ai_flags = AI_PASSIVE;     // IP Wildcard

    // Now fill up the linked list of host_info structs with google's address information.
    status = getaddrinfo("127.0.0.1", "5556", &host_info, &host_info_list);
    // getaddrinfo returns 0 on succes, or some other value when an error occured.
    // (translated into human readable text by the gai_gai_strerror function).
    if (status != 0)  std::cout << "getaddrinfo error" << gai_strerror(status) ;


    std::cout << "Creating a socket..."  << std::endl;
    int socketfd ; // The socket descripter
    socketfd = socket(host_info_list->ai_family, host_info_list->ai_socktype,
                      host_info_list->ai_protocol);
    if (socketfd == -1)  std::cout << "socket error " ;

    std::cout << "Binding socket..."  << std::endl;
    // we use to make the setsockopt() function to make sure the port is not in use
    // by a previous execution of our code. (see man page for more information)
    int yes = 1;
    status = setsockopt(socketfd, SOL_SOCKET, SO_REUSEADDR, &yes, sizeof(int));
    status = bind(socketfd, host_info_list->ai_addr, host_info_list->ai_addrlen);
    if (status == -1)  std::cout << "bind error" << std::endl ;

    std::cout << "Listen()ing for connections..."  << std::endl;
    status =  listen(socketfd, 5);
    if (status == -1)  std::cout << "listen error" << std::endl ;


    int new_sd;
    struct sockaddr_storage their_addr;
    socklen_t addr_size = sizeof(their_addr);
    new_sd = accept(socketfd, (struct sockaddr *)&their_addr, &addr_size);
    if (new_sd == -1)
    {
        std::cout << "listen error" << std::endl ;
    }
    else
    {
        std::cout << "Connection accepted. Using new socketfd : "  <<  new_sd << std::endl;
    }


    std::cout << "Waiting to recieve data..."  << std::endl;
    ssize_t bytes_recieved;
    char incomming_data_buffer[1000];
    bytes_recieved = recv(new_sd, incomming_data_buffer,1000, 0);
    // If no data arrives, the program will just wait here until some data arrives.
    if (bytes_recieved == 0) std::cout << "host shut down." << std::endl ;
    if (bytes_recieved == -1)std::cout << "recieve error!" << std::endl ;
    std::cout << bytes_recieved << " bytes recieved :" << std::endl ;
    incomming_data_buffer[bytes_recieved] = '\0';
    std::cout << incomming_data_buffer << std::endl;


    std::cout << "send()ing back a message..."  << std::endl;
    char *msg = "thank you.";
    int len;
    ssize_t bytes_sent;
    len = strlen(msg);
    bytes_sent = send(new_sd, msg, len, 0);

    std::cout << "Stopping server..." << std::endl;
    freeaddrinfo(host_info_list);
    close(new_sd);
    close(socketfd);

return 0 ;


}

How to create Socket communication in C++ Linux Based application Client socket

TCP Client Socket
================

#include <iostream>
#include <cstring>      // Needed for memset
#include <sys/socket.h> // Needed for the socket functions
#include <netdb.h>      // Needed for the socket functions

int main()
{

    int status;
    struct addrinfo host_info;       // The struct that getaddrinfo() fills up with data.
    struct addrinfo *host_info_list; // Pointer to the to the linked list of host_info's.

    // The MAN page of getaddrinfo() states "All  the other fields in the structure pointed
    // to by hints must contain either 0 or a null pointer, as appropriate." When a struct
    // is created in c++, it will be given a block of memory. This memory is not nessesary
    // empty. Therefor we use the memset function to make sure all fields are NULL.
    memset(&host_info, 0, sizeof host_info);

    std::cout << "Setting up the structs..."  << std::endl;

    host_info.ai_family = AF_UNSPEC;     // IP version not specified. Can be both.
    host_info.ai_socktype = SOCK_STREAM; // Use SOCK_STREAM for TCP or SOCK_DGRAM for UDP.

    // Now fill up the linked list of host_info structs with google's address information.
    status = getaddrinfo("127.0.0.1", "5556", &host_info, &host_info_list);
    // getaddrinfo returns 0 on succes, or some other value when an error occured.
    // (translated into human readable text by the gai_gai_strerror function).
    if (status != 0)  std::cout << "getaddrinfo error" << gai_strerror(status) ;


    std::cout << "Creating a socket..."  << std::endl;
    int socketfd ; // The socket descripter
    socketfd = socket(host_info_list->ai_family, host_info_list->ai_socktype,
                      host_info_list->ai_protocol);
    if (socketfd == -1)  std::cout << "socket error " ;


    std::cout << "Connect()ing..."  << std::endl;
    status = connect(socketfd, host_info_list->ai_addr, host_info_list->ai_addrlen);
    if (status == -1)  std::cout << "connect error" ;


    std::cout << "send()ing message..."  << std::endl;
    char *msg = "GET / HTTP/1.1\nhost: www.google.com\n\n";
    int len;
    ssize_t bytes_sent;
    len = strlen(msg);
    bytes_sent = send(socketfd, msg, len, 0);

    std::cout << "Waiting to recieve data..."  << std::endl;
    ssize_t bytes_recieved;
    char incomming_data_buffer[1000];
    bytes_recieved = recv(socketfd, incomming_data_buffer,1000, 0);
    // If no data arrives, the program will just wait here until some data arrives.
    if (bytes_recieved == 0) std::cout << "host shut down." << std::endl ;
    if (bytes_recieved == -1)std::cout << "recieve error!" << std::endl ;
    std::cout << bytes_recieved << " bytes recieved :" << std::endl ;
    incomming_data_buffer[bytes_recieved] = '\0' ;
    std::cout << incomming_data_buffer << std::endl;
    std::cout << "Receiving complete. Closing socket..." << std::endl;
    freeaddrinfo(host_info_list);
    close(socketfd);

}

Monday, 4 November 2013

What is WCF ?

WCF is (Windows communication foundation ) is a set of APIs and run time in the dot net frame to develop service oriented applications. Its previous name was indigo. In wsdl it support only limited network protocols but in wcf it supports most of the protocol stack and easy to use and it is available in visual studio 2008 onwards.

Saturday, 26 October 2013

Linux device driver


Linux Device driver programming 

To develop linux based device drivers you need to know the C language and pointers and  microprocessor programming .

User space and kernel space



When you write device drivers, it’s important to make the distinction between “user space” and “kernel space”.

Kernel space. Linux (which is a kernel) manages the machine's hardware in a simple and efficient manner, offering the user a simple and uniform programming interface. In the same way, the kernel, and in particular its device drivers, form a bridge or interface between the end-user/programmer and the hardware. Any subroutines or functions forming part of the kernel (modules and device drivers, for example) are considered to be part of kernel space.
User space. End-user programs, like the UNIX shell or other GUI based applications (kpresenter for example), are part of the user space. Obviously, these applications need to interact with the system's hardware . However, they don’t do so directly, but through the kernel supported functions.

Example

#include <linux/init.h>
#include <linux/module.h>
#include <linux/kernel.h>

MODULE_LICENSE("Dual BSD/GPL"); // For loading the driver

static int hello_init(void) {
  printk("<1>Driver test by johnson : Hello world!\n");
  return 0;
}

static void hello_exit(void) {
  printk("<1> Bye, Johnson \n");
}

module_init(hello_init);
module_exit(hello_exit);
Next, you need to generate a makefile. The makefile for this example, which should be named Makefile, will be:

<Makefile>
inside make file

obj-m := hello.o

Unlike with previous versions of the kernel, it’s now also necessary to compile the module using the same kernel that you’re going to load and use the module with. To compile it, you can type:

$ make -C /usr/src/kernel-source-2.6.8 M=pwd modules

This extremely simple module belongs to kernel space and will form part of it once it’s loaded.

In user space, you can load the module as root by typing the following into the command line:

# insmod  hello.o

The insmod command allows the installation of the module in the kernel. However, this particular module isn’t of much use.

It is possible to check that the module has been installed correctly by looking at all installed modules:

# lsmod

Finally, the module can be removed from the kernel using the command:

# rmmod  hello

By issuing the lsmod command again, you can verify that the module is no longer in the kernel.


How to develop device driver for windows ?


What is Device Driver?

 a program that determines how a computer will communicate with a peripheral device

How to develop device driver?

There is a kit available for develop device driver for windows ( DDK tool kit ) . download and install then you can start developing .Now its called Windows Driver Kit (WDK) 8.1

 Please be take care that if your driver has any problems then it will crash the OS so better , you should test the driver in windows installed in virtual box .

Download and install OSR Loader 

This GUI-based tool will make all the appropriate registry entries for your driver, and even allow you to start your driver without rebooting. It's even got a help file, for goodness sakes! If you write drivers, this is another one of those utilities that's a must have for your tool chest. x86 architecture.

Install DebugView  for Debug and view the result.


Introduction

DebugView is an application that lets you monitor debug output on your local system, or any computer on the network that you can reach via TCP/IP. It is capable of displaying both kernel-mode and Win32 debug output, so you don't need a debugger to catch the debug output your applications or device drivers generate, nor do you need to modify your applications or drivers to use non-standard debug output APIs.

DebugView Capture

Under Windows 2000, XP, Server 2003 and Vista DebugView will capture:
Win32 OutputDebugString
Kernel-mode DbgPrint
All kernel-mode variants of DbgPrint implemented in Windows XP and Server 2003
DebugView also extracts kernel-mode debug output generated before a crash from Window's 2000/XP crash dump files if DebugView was capturing at the time of the crash.

DebugView Capabilites

DebugView has a powerful array of features for controlling and managing debug output.
Features new to version 4.6:
Support for Windows Vista 32-bit and 64-bit
Features new to version 4.5:
Support for log-file rollover: To better support long-running captures, DebugView can now create a new log file each day, optionally clearing the display when doing so.
Features new to version 4.4:
Support for Windows Server 2003 64-bit Edition and Windows XP 64-bit Edition for x64:DebugView now captures kernel-mode debug output on 64-bit versions of Windows.
Clock-time toggle: you can now toggle between clock time and elapsed time modes.
Features new to version 4.3:
Support for Windows XP SP2:DebugView now captures kernel-mode debug output on Windows XP SP2.
More highlighting filters: Many people have asked for more highlighting filters.
Log file wrapping: A new log file option has DebugView wrap around to the start of the log file when the specified size limit is reached.
Larger buffers: Larger Win32 and kernel-mode buffers lessen the chance of dropped debug output.
Clear-output string: When DebugView sees the special debug output string "DBGVIEWCLEAR" it clears the output.
Client minimize-to-tray: You can now run the client minimized in the tray.
Features new to version 4.2:
Kernel-hook bug fixed:DebugView sometimes mistakenly report that it couldn't hook kernel-mode debug output on Windows XP and Server 2003.
Client global-capture option: A new option allows the client to capture console Win32 debug output on Terminal Server systems when run from a non-console session.
Filtering improved: Filters can be much longer and now apply to Win32 process IDs when process IDs are included in the output.
Crash-dump support improved: Several bugs related to extracting kernel-mode output from crash dumps are fixed and DebugView now loads resulting log files.
More highlight filters:DebugView now has 10 highlight filters, up from 5.
Insert comments: A new menu item lets you insert comments into output.
New switches: New command-line switches allow you to specify history depth and load log files.
Better balloon tips: If an output line is wider than the screen its mouse hover balloon tip word wraps.
Features new to version 4.1:
Save and load filters: You can save and load filters, including the highlighting colors.
Load saved logs: You can now load a log file back into the DebugView output window.
Capture boot-time kernel-mode debug output: Under Windows 2000, you can use DebugView to capture debug output generated by drivers from the earliest point in the boot process.
Here is a list highlighting some of DebugView's other features:
Remote monitoring: Capture kernel-mode and/or Win32 debug output from any computer accessible via TCP/IP - even across the Internet. You can monitor multiple remote computers simultaneously. DebugView will even install its client software itself if you are running it on a Windows 2000 system and are capturing from another Windows 2000 system in the same Network Neighborhood.
Most-recent-filter lists:DebugView remembers your most recent filter selections, with an interface that makes it easy to reselect them.
Process ID option: Toggle the display of process IDs for Win32 debug output.
Clipboard copy: Select multiple lines in the output window and copy their contents to the clipboard.
Log-to-file: Write debug output to a file as its being captured.
Printing: Print all or part of captured debug output to a printer.
One-file payload:DebugView is implemented as one file.
Crash-Dump Support:DebugView can recover its buffers from a crash dump and save the output to a log file so that users can send you the output your Windows driver generated right up to the time of a crash.
The on-line help file describes all these features, and more, in detail.

Installation and Use


Simply execute the DebugView program file (dbgview.exe) and DebugView will immediately start capturing debug output. Note that if you run DebugView on Windows 2000/XP you must have administrative privilege to view kernel-mode debug output. Menus, hot-keys, or toolbar buttons can be used to clear the window, save the monitored data to a file, search output, change the window font, and more. The on-line help describes all of DebugView's features.

HCK for Windows 8.1 

Hardware Certification tool for sign the driver. The driver signing and certification tools are available in visual studio 2013 genuine version .

For driver development samples visit the link bellow




How to change or hide your actual ip address

Change or hide your actual ip address  by using any of the following applications for free of cost

hideip vpn
Proxpn
open vpn etc

How to warm up IP address and email for Deliverability

To warm-up IP address and email for Deliverability by  four steps

Step 1: Sign up for feedback loops

Step 2: Set up your authentication data

Step 3: Engage with your most active recipients

Step 4: Monitor

How do I tell search engines not to index content via secondary domain names or any folders

1) Configure settings in .htaccess file like bellow

RewriteEngine on
RewriteCond %{HTTP_HOST} \.b\.com$ [OR]
RewriteCond %{HTTP_HOST} \.c\.com$
RewriteRule ^(.*)$ http://a.com/$1 [R=301,L]

2) Configure settings in robots.txt file like bellow

User-agent: *
Disallow: /search
Disallow: /groups
Disallow: /images
Disallow: /news


Any of the above two steps will resolve what you need

How to take screen shot of a desktop using QT

#include<QPixmap>
#include<QDir>

QPixmap imgUrl;
    imgUrl = QPixmap::grabWindow(QApplication::desktop()->winId());
    QString format = "jpg";
    QString initialPath = QDir::currentPath() + tr("/untitled.") + format;
    imgUrl.save(initialPath, format.toAscii());

Works with GT GUI application only


Thursday, 24 October 2013

How to boot Windows 8 from pen drive/USB disk


How to boot Windows 8 from pen drive/USB disk

select  command prompt by typing at run -->cmd

c:> DISKPART
c:>list disk
c:>select disk [Disk number]
c:>clean
c:>create partition primary
c:>active
c:> format fs=ntfs
copy files to usb

How to assign " in to a string in QT

How to assign " in to a string in QT

To do this use / symbol before "

eg Qstring str="this is very /"interesting/" story"

Thursday, 10 October 2013

what is xpcom compoenets

XPCOM is a cross platform component object model, similar to Microsoft COM. It has multiple language bindings, letting XPCOM components be used and implemented in JavaScript, Java, and Python, in addition to C++. Interfaces in XPCOM are defined in a dialect of IDL called XPIDL.


Writing plug-ins for Mozzila Gekko engine

Writing Plug-ins


  1. Once you decide what you want your plug-in to do, creating it is a simple process. A basic overview of the plug-in development process is given in the following steps.

  2. Plan your plug-in: decide on the services you want the plug-in software to provide and how it will interact with the browser and the special media for which the plug-in is created.
  3. Decide the MIME type and file extension for the plug-in (see Registering Plug-ins).
  4. Set up your development environment properly. You can use a variety of environments to create a plug-in, but make sure that you have the necessary files from the mozilla source or from the plug-in SDK.
  5. Create a plug-in project.
  6. You can either start from one of the samples provided for your operating system in the mozilla source directory, where plug-ins samples are already being built, or you can construct a new plug-in project in your own development environment using SDK-provided files. See the README in the plug-in SDK for more information about using the SDK and using the samples provided there.
  7. Write your plug-in code and implement the appropriate Plug-in API methods for basic plug-in operation. You'll find an overview of the Plug-in API methods in this chapter, as well as separate chapters for all of the major functional areas of the Plug-in API. Also see Making Plug-ins Scriptable for more information about making plug-ins accessible from the browser.
  8. Build the plug-in for your operating system. See "Building Plug-ins"
  9. Install the plug-in in the plug-in directory for your operating system. See Installing Plug-ins.
  10. Test your plug-in and debug as necessary.
  11. Create an HTML page and embed the plug-in object. For information about the HTML elements to use, see Using HTML to Display Plug-ins. To see your plug-in in action, simply display the HTML page that calls it in the browser.

Registering Plug-ins

Gecko identifies a plug-in by the MIME type it supports. When it needs to display data of a particular MIME type, the browser finds and invokes the plug-in object that supports that type. The data can come from either an object element in an HTML file (where the object or embed element either specifies the MIME type directly or references a file of that type), from a separate non-HTML file of that MIME type, or from the server.

The server looks for the MIME type registered by a plug-in, based on the file extension, and starts sending the file to the browser. The browser looks up the media type, and if it finds a plug-in registered to that type, loads the plug-in software.

When it starts up, the browser checks for plug-in modules for the platform and registers them. It determines which plug-ins are installed and which types they support through a combination of user preferences that are private to the browser, the contents of the plug-ins directory or the registry on Windows.

A MIME type is made up of a major type (such as application or image) and a minor type, for example, image/jpeg. If you define a new MIME type for a plug-in, you must register it with IETF (Internet Engineering Task Force). Until your new MIME type is registered, preface its name with "x-", for example, image/x-nwim. For more information about MIME types, see these MIME RFCs:

RFC-2045: "Multipurpose Internet Mail Extensions (MIME) Part One: Format of Internet Message Bodies"
RFC-2046: "Multipurpose Internet Mail Extensions (MIME) Part Two: Media Types"
RFC-4288: "Media Type Specifications and Registration Procedures"

Create simple plugi n for google chrome browser - Plug-in development

Create simple plugi n for google chrome browser - Plug in development

Plug ins are addons that will give additional fecilities in to applications than built in . To create a simple plug in we need to do simple two steps

Create a minifest.json file
Create an html file

manifest.json

{
  "name": "my test menu",
  "version": "1.0",
  "manifest_version": 2,
  "description": "The first extension that I made.",
  "browser_action": {
    "default_menu": "First Menu",
    "default_popup": "popout.html"
  },
  "permissions": [
    "http://api.flickr.com/"
  ]
}

popout.html file

<html>
<html>
<label><b>This is a plugin</b></label>
</html>
</html>

To execute plugin in test mode Go to menu --> settings -->extensions -->tick developer mode -->click load unpack extension

This will execute your plugin

To pack the plugin click on pack plugin

This is a simple plugin



How to convert mp4 to h264 in debian linux or raspberry pi

Installation

sudo apt-get update
sudo apt-get install gpac
y

Usage
MP4Box -add  file1.mp4   output.h264

how to convert h264 to mp4 in debian linux or raspberry pi?

Installation

sudo apt-get update
sudo apt-get install gpac
y

Usage
MP4Box -add  file1.h264   output.mp4

Monday, 7 October 2013

How to find system names ,ip and mac address in a network or lan

How to find system names ,ip and mac address in a network or lan .

 To do this you shoud use any network scanners in windows or use the following ways .

1) open run ( in windows) --> type cmd ---> then type arp -a will list all systems with mac and ip.

2) Use network map from network sharing center

3) Use Advanced ip scanner from the bellow link

http://www.advanced-ip-scanner.com/


Sunday, 15 September 2013

What is Open MAX ? and hardware architecture

Open Max™ is a royalty-free, cross-platform API that provides comprehensive streaming media codec and application portability by enabling accelerated multimedia components to be developed, integrated and programmed across multiple operating systems and silicon platforms. The Open Max API will be shipped with processors to enable library and codec implementer's to rapidly and effectively make use of the full acceleration potential of new silicon - regardless of the underlying hardware architecture.



Saturday, 14 September 2013

How to generate class file for WSDL web service in visual studio

To do this create a web service in visual studio , then open command line tool for visual studio --> then type wsdl <space> the webservice url

it will generate a class for your web service

How to develop Android in visual studio

To develop android in visual studio , Use Android studio .

http://androidstudio.tektips.in/android-studio-download-now.aspx

How to secure your emails ?

To enable higher level security use email firewall called  Barracuda Firewall (https://www.barracuda.com/products) , this is used by Naasa,US Army etc 

develop python in Visual studio Environment

To get this fecility use this free tool
http://pytools.codeplex.com

usitable for embedded development and other linux based development too

Tuesday, 10 September 2013

QList in QT

Syntax : QList<Type> Identifier;
   

QList<QString> strlist;

To add values to list

    strlist.append(obj);

What is amazone Ec2 and S3 Cloud

Amazone EC2 allows you to faster deployment of services and S3 allows you to store large amount of data . In EC2 you can start any AMIs like windows and linux based AMis or you can deploy your own AMIs

Thursday, 15 August 2013

How to use Gsoap in C/C++/Embedded C++ to communicate to a web service in windows/linux and mac


First you have to download gsoap tool kit .

in that go to gsoap kit folder by following  <path>:\gsoap\gsoap\bin

then select platform .

open command prompt or terminal --> Move to the above path --> then type

wsdl2h.exe  -o <ourputfilename.h>  < webservice url wsdl >

It will produce a .h extention file then  type

soapcpp2.exe ourputfilename.h  will produce the c++ based soap files for the specified web service


[ gSoap in raspberry pi , gSoap in linux,gSoap in mac ,gsoap for windows , c++ and gsoap communication ]

What is web service?

Web services are typically application programming interfaces (API) or Web APIs that are accessed via Hypertext Transfer Protocol (HTTP).

The basic Web services platform is XML + HTTP.

XML provides a language which can be used between different platforms and programming languages and still express complex messages and functions.

The HTTP protocol is the most used Internet protocol.

Web services platform elements:

SOAP (Simple Object Access Protocol)
UDDI (Universal Description, Discovery and Integration)

WSDL (Web Services Description Language)


What is SOAP protocol ?

SOAP, originally defined as Simple Object Access Protocol, is a protocol specification for exchanging structured information . It is an XML-based messaging protocol. It defines a set of rules for structuring messages that can be used for simple one-way messaging but is particularly useful for performing RPC-style (Remote Procedure Call) request-response dialogues .

What is KD SOAP

As part of our commitment to cross-platform solutions, KDAB offers developers KD SOAP, a web service access package for Qt applications. KD SOAP is a tool for creating client applications for web services and also provides the means to create web services without the need for any further component such as a dedicated web server.

It makes it possible to interact with applications which have APIs that can be exported as SOAP objects. The web service then provides a machine-accessible interface to its functionality via HTTP.

Features

The KD SOAP library provides an abstraction layer for both the actual transport, as well as, the construction of data objects and method calls. (The latter relieves application developers from manually writing XML marshalling and demarshalling code, allowing them to build arbitrary complex data structures using simple C++ classes.)
The transport abstraction provides both synchronous as well as Qt signal/slot based asynchronous remote method call and response handling.
The server module supports both single-threaded as well as thread pool based network handling and method call execution.
Along side the library, KD SOAP ships with the kdwsdl2cpp code generator, providing additional means for increasing developer productivity by generating client-side proxy API or server-side object interfaces based on formal WSDL service description. Using classes generated by this approach adds build-time type checking and “in process”-like object behavior (i.e. using C++ data types as parameters and return values of each of the web service’s methods).

Get KD SOAP

KD SOAP is available under a LGPL license and can be downloaded from:
https://github.com/KDAB/KDSoap

Where to host your website [ 5 Tips ]

Every one get confused when they are thinking about a website , Where to host ? there are a lot of providers , Resellers and sub resellers . The first thing is that select the servers hosted in the area that the expected visitors are from . So it will reduce the latency of your website means will increase website speed .Second thing is that try to select providers who have faster and high configuration servers like scibero hosting and cyber solutions [ http://scibero.com], Godaddy [godaddy.com] , hostgator.com,ixhosting.com etc . Try to use linux platform than windows with basic scripting methonds like html,php or javascript will increase your site speed and Search engine visibility . Try to use static IP than dynamic . 

Sunday, 4 August 2013

How to start a visual studio addin project ?


To  create Addins for visual studio  just open visual studio , then  new project --> others --> Visual studio Addin .--> Name the project-->select the coding language [ C#/VB/C++/ATL] --> then follow the wizard .


How to find the location of an IP address

To find the location of an IP address you can use the free web services like ipaddress.com or network-tools.com .

You can decode the mail headers for cyber forensic activities , trace ip location and server location . Reverse look up will show you the Websites hosted in a server etc

For web hosting with faster server in visit scibero.com

Saturday, 3 August 2013

what is Cygwin?

Cygwin is:
  • a collection of tools which provide a Linux look and feel environment for develop applications on Windows.
  • a DLL (cygwin1.dll) which acts as a Linux API layer providing substantial Linux API functionality.

ygwin is not:

  • a way to run native Linux apps on Windows. You must rebuild your application from source if you want it to run on Windows.
  • a way to magically make native Windows apps aware of UNIX® functionality like signals, ptys, etc. Again, you need to build your appsfrom source if you want to take advantage of Cygwin functionality.

Which is the best performance language platform for PI

Tthe best performance language platform for raspberry PI is python  also c++ is also good but compiler is not much efficient and not sophisticated  for multithreading with pthread .

Debian Wheezy hardfloat supports Mono and QT?

Yes, Debian Wheezy hardfloat supports Mono and QT ! i am made this successfully for a project that i done for my firm . 

QT on raspberry PI compiler target issue


To resolve QT on raspberry PI compiler target issue you need to specify the compiler related things in QT creator .

 First install QT creator

 then setup QT toolchain in pi

then compile , Don't try to compile using cross tool chain because raspberry pi has some problems related to hardware means hardware dependency 

Sunday, 28 July 2013

How to convert Qstring to const char * in qt

To convert Qstring to const char *

String variable.toStdstring.c_str();


Reading XML in QT5

Reading xml in the format
XML will be look like 
<xml>
<settings name=john > </settings></xml>

#include <qdom.h>
#include <qfile.h>
#include <qfile.h>
#include <qstring.h>
#include <iostream>
#include <QTextStream>

QString  SetUrl()
{
          QString str;
          QDomDocument Settingsdoc( "demo.xml" );
          QFile file( "EmSettings.xml" );
          if( !file.open(QIODevice::ReadOnly ) )
          QTextStream(stdout) << "Error reading settings file"<< endl;
          if( !Settingsdoc.setContent( &file ) )
          {
            file.close();

          }
          file.close();
          QDomElement root = Settingsdoc.documentElement();
          QDomNodeList list  =root.elementsByTagName("settings");
          str = list.at(0).toElement().attribute("name");
          QTextStream(stdout) << "URL "<< str<< endl;
          Settingsdoc.clear();
           return str;
}

2) Read xml in the format

<xml>
<name>John</name>
<add>Demo</add>


Answer

QDomDocument Settingsdoc( "demo1" );
      QFile file( "demo.xml" );
      if( !file.open(QIODevice::ReadOnly ) )
        return -1;
      if( !Settingsdoc.setContent( &file ) )
      {
        file.close();
        return -2;
      }
      file.close();

      QDomElement root = Settingsdoc.documentElement();
      QDomNodeList list  =root.elementsByTagName("name");
      int count = list.count();
      for (int i = 0; i < count; i++)
          {
            QString str = list.at(i).toElement().text();
            QTextStream(stdout) << "Value "<< str<< endl;
          }


Saturday, 29 June 2013

What is #pragma "


Pragma is a compiler directive used for instruct the compiler to do something

eg

#pragma once"

This will do the specified task ones , means the header file onces


How to create Directx based development environment in your system?

How to create Directx based development environment in your system?

To do this it is very simple ,Just install the following components

directx_Jun2010_redist.exe from microsoft

and then install DirectX SDK

dx9sdk.exe

then install visual studio 20xx and ready to go

How to find network traffic of a specific or currently active network adapter using c# windows


How to find network traffic of a specific or currently active network adapter using c# windows

To do this First import the name spaces

using System.Net.NetworkInformation;
using System.Diagnostics;

Delcare global varibales

 #region BandwidthVariables
        private const double timerUpdate = 1000;
        private NetworkInterface[] nicArr;
        private Timer timer;
        double BytesRecived=0;
        #endregion


 // Edited from here 
        #region Network
        /// <summary>
        /// Initialize the Timer 
        /// </summary>

        private void InitializeTimer()
        {
            timer = new Timer();
            timer.Interval = (int)timerUpdate;
            timer.Tick += new EventHandler(timer_Tick);
            timer.Start();
        }

        private void InitializeNetworkInterface()
        {
            // Grab all local interfaces to this computer
            nicArr = NetworkInterface.GetAllNetworkInterfaces();
       }

        /// <summary>
        /// The Timer event for each Tick (second) to update the UI
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        void timer_Tick(object sender, EventArgs e)
        {
            UpdateNetworkInterface();
        }

        /// <summary>
        /// Update GUI components for the network interfaces
        /// </summary>
        private void UpdateNetworkInterface()
        {
            // Grab NetworkInterface object that describes the current interface
            NetworkInterface nic = nicArr[0];

            for (int i = 0; i < nicArr.Length; i++)
            {
                if (nicArr[i].OperationalStatus == OperationalStatus.Up) // Checking for active NIC
                {
                    nic = nicArr[i];
                  
                    break;
                    //nic is attached to some form of network
                }

            }
            // Grab the stats for that interface
            IPv4InterfaceStatistics interfaceStats = nic.GetIPv4Statistics();
            int bytesReceivedSpeed = (int)(interfaceStats.BytesReceived - BytesRecived) / 1024;
            BytesRecived = interfaceStats.BytesReceived; 
            lblBandwidth.Text = bytesReceivedSpeed.ToString() + " KB/s";

// Put a label and timer in your form and name the label as "lblBandwidth"

        }
        #endregion

Friday, 28 June 2013

How to install windows server 2012 in virtual box/ Fresh hard Drive

How to install windows server 2012 in virtual box/ Fresh hard Drive

Please go through my video tutorials at memcpy offical you tube channel

http://www.youtube.com/watch?v=rWI1Eox5VBw

Sunday, 16 June 2013

Install Mono in Raspberry PI


To install Mono frame work in raspberry PI hard float and Soft Float run the following command

sudo apt-get install mono-runtime
sudo-apt-get install mono-complete
sudo apt-get install monodevelop


For support for this mail to info@memcpy.in


For completely installed Disk image for Raspberry PI [ .img ] please contact info@memcpy.in


Create a Web browser for Raspberry PI in QT


To do this Open QT creator --> Create a new project --> Web HTML 5 APP --> Go forward . After creating the project just build and run , your web browser is ready

For Support for this contact info@memcpy.in


How to install QT in Raspberry PI


To install QT in raspberry PI use the following commands [ Both hard float and soft float ]

sudo apt-get upgrade
sudo apt-get update

sudo apt-get install libqt4-assistant libqt4-core \
libqt4-dbg libqt4-dbus libqt4-designer libqt4-dev \
libqt4-gui libqt4-help libqt4-network libqt4-opengl \
libqt4-opengl-dev libqt4-qt3support libqt4-script \
libqt4-sql  libqt4-sql-mysql libqt4-sql-odbc \
libqt4-sql-psql libqt4-sql-sqlite libqt4-sql-sqlite2 \
libqt4-svg libqt4-test libqt4-webkit libqt4-webkit-dbg \
libqt4-xml libqt4-xmlpatterns libqt4-xmlpatterns-dbg \
libqtcore4 libqtgui4 qt4-demos qt4-designer qt4-dev-tools \
qt4-doc qt4-doc-html qt4-qtconfig qtcreator


Qt installed Disk images | How to install QT in Raspberry pi , How to install QT in Linux .

For support your install please mail to info@memcpy.in



Sunday, 2 June 2013

Powerful electronics embedded board : Raspberry PI tutorial


Today world, small things make big changes to the entire world and change an era.  Now a day’s most of the new inventions are came from teen age peoples and youth. They are always thinking for a change especially in Information technology and Electronics. Things are changing from big to small and small to very small and to invisible but we can feel the presence, technologies are expanded in this ways. No need to sit in a place everything can be controlled when we are moving. I saw a software called KTS Info mate, and in that we can control more than 100 display screens [Digital notice Board ] and set different contents while we are moving .This is a great technology and may be a new invention for the world .
                If we talking about embedded boards and tiny computer devices, there are lot of experiments are going on .and lot of new boards and tiny computer systems are available now in market with great operational facilities and functions. And the great advantages of these are, it has only less cost .

Here I like to introduce a new board called as “RASPBERRY PI “in to your front. And  I am making things with this .

Powerful electronics embedded board : Raspberry PI tutorial and beginners guide
read at

 http://tektips.in/Raspberry-PI-for-Beginners.aspx


How to connect raspberry pi camera , How to setup raspberry pi , how to order raspberry pi , how to assembly raspberry pi , 

Saturday, 18 May 2013

memcpy() in c++ Reference


memcpy() in c++ Reference

memcpy() is used to transfer a bulk data [Block of data or memory block ]means a number of bytes in to another location , We can use this function in both windows and linux to copy memory locations .

Syntax :  memcpy ( Destination,Source,Sizeof memory block );


/* memcpy example */
#include <stdio.h>
#include <string.h>

struct {
  char Address[40];
  int count;
}obj,obj1;

int main ()
{
  char maddress[] = "Johnson";

  /* using memcpy to copy string: */
  memcpy ( obj.Address, maddress, strlen(maddress)+1 );
  obj.count= 4;

  /* using memcpy to copy structure: */
  memcpy ( &obj1, &obj, sizeof(obj) );

  printf ("copied" );

  return 0;
}

Difference between sleep and usleep

Difference between sleep and usleep

 sleep() will suspend the process for a specified second  , The input of sleep will be in seconds[integer value only]

Eg : sleep(10);

usleep() will suspend the process for a specified micro second  .

eg : usleep(2000);  // it will waits for two milli seconds

1sec = 1000 Milli Sec
1 Milli sec = 1000 Micro Sec

Get time in milliseconds in c++


Get time in milliseconds in c++

void GetMilliSec()
{
struct timeval  tv;
gettimeofday(&tv, NULL);

long time_in_mill =
         (tv.tv_sec) * 1000 + (tv.tv_usec) / 1000 ;
std::cout<<"\n\nTime in millisec"<<time_in_mill<<"\n";
}

pthread error in linux and embedded boards in c++

pthread error in linux and embedded boards in c++  : Not starting the multi thread p-thread_create()

It is due to the issue with the compiler , you fix this just put a sleep() after pthread_create () function

Thursday, 16 May 2013

How to use two dimensional array using vectors in c++ [ Linux and windows ]



Introduction

Vectors are built in arrays and supported by c++ compilers to reduce the effort to manage arrays and linked lists. 

Description

The syntax of  a single dimensional vector array is as follows .
std::vector<Type> Identifier 
eg: std::vector<int> array;

Two create two dimensional arrays 

std::vector<std::vector<type>> Identifier;
Eg : std::vector<std::vector<int> > m_2DintArray;

Don’t forget to put a space in between >> means “> put a space here >” else it will not parse correctly by the linux g++ compiler and may you will get an error like bellow

Error1 : Identifier not declared  
or
Error2 : No scope for the identifier

There is lot of built in operations available for vectors. Some of them are given bellow

To resize the array dynamically.
Eg m_2DintArray.resize(2);
 
To insert values to array
m_2DintArray[0].push_back(iValues);

Retrieve values from array
int values= m_2DintArray[0].pop_back();

Delete array values
m_2DintArray[0].erase(); - Delete a value 

For more discussions please visit : 


How to create a simple make file and compile c++ project in linux?


Introduction
    Make file is used to compile and link C++ header files, cpp files and associated libraries in Linux platform. 

For more discussions please visit : 

    Description

     Look at the bellow example.
     Assume that we have two cpp files that includes 2 header files and one Library file, to write a make file for this C++      project, do the following things.
    "Example1.cpp" associated to "example1.h"
     "Example2.cpp" associated to "exaple2.h" and a lib file called "example2LIB"
  • open a text file and name as "makefile" (Normally no extension)
  • open the file in any text editor
  • Wrtite the bellow expression
      g++  -c  example1.h Example1.cpp exaple2.h Example2.cpp -lexample2LIB -o example
  1. g++ - For calling Linux based c++ compiler
  2. -c - Compile the codes
  3. -l - Link to libraries
  4. -o - Final binary out put
  • Save the file.
  • Open Terminal and move to the project path
  • Type make to compile and link the code , If you got any error in code type vi space cpp or .h file name , 
  • Press i and edit the code correctly press ESC then press :wq to save ["q! to exit without save]
  • If any conflict in object files and intermediate files just add one more line in make file to clean up 
      clean: rm -f <Foldername>/*.o
  • To execute the clean command  type "make clean" in terminal
To avoid re-usage of same keywords or commands in make file creation and make some generality to your make file , just use variables like the following way
Syntax: Variable name=<value>
  • Eg:  CC=gcc
  • CPP=g++
  • To retrive the values from variables use "$" sign
  • Eg : $(CPP) -c example.h example.cpp -o example
  • To display a message to screen when making process use @echo
  • Eg: @echo "Cleaning up directory."
For more discussions please visit : 

For more discussions visit http://www.tektips.in

Sunday, 12 May 2013

Conditional Compiling in C++


To compile c++ code conditionaly just use #ifdef  <IDENTIFIER>  .... #endif

Multi Threading in C++

Multithreading is a specialized form of multitasking and a multitasking is the feature that allows your computer to run two or more programs concurrently. In general, there are two types of multitasking: process-based and thread-based.

creating and  Starting threads


#include <pthread.h>
pthread_create (thread, attr, start_routine, arg) 

Example
=======

#include <iostream>
#include <pthread.h>

using namespace std;

#define NUM_THREADS     5

void *PrintHello(void *threadid)
{
   long tid;
   tid = (long)threadid;
   cout << "Hello John! Thread ID, " << tid << endl;
   pthread_exit(NULL);
}

int main ()
{
   pthread_t threads[NUM_THREADS];
   int rc;
   int i;
   for( i=0; i < NUM_THREADS; i++ ){
      cout << "From Main thread creating thread, " << i << endl;
      rc = pthread_create(&threads[i], NULL, 
                          PrintHello, (void *)i);
      if (rc){
         cout << "Error:unable to create thread," << rc << endl;
         exit(-1);
      }
   }
   pthread_exit(NULL);
}


This example assumes that you are working on Linux OS and we are going to write multi-threaded C++ program using POSIX. POSIX Threads, or Pthreads provides API which are available on many Unix-like POSIX systems such as FreeBSD, NetBSD, GNU/Linux, Mac OS X and Solaris.

Tuesday, 7 May 2013

Which is the best performance embedded board with HD support


" Raspberry Pi " is a debian based embedded board with HD support

 [ For raspberry PI related development visit http://ktsinfotech.com ]

How to set static IP in Linux ?

How to set static IP in Linux ?

It is very simple , Just go to root folder ( / )  use cd ..  or cd <path> command  to navigate between directory .

Go to  cd /etc/network/

open  vi interfaces

 change DHCP to STATIC

Put ADDRESS <IP>
netmask <255.0. .>
gateway < Gateway ip >

Press ESC
Enter :wq
[ If shows write error use sudo chmod 777 interfaces ]
type sudo reboot 

ASP.net Web application is not working after publishing why?

ASP.net Web application is not working after publishing why?

Check all referenced libraries are present in bin folder
Check the App running machine config (X86 or x64) , and publish for the corresponding target machine
Check DB path and connection string, and check for permissions

Can't Connect Access data base via ODBC connection in c#.net web application ?


It is due to the following resons ,

1) Check the database path , Use double slah to define database in windows
2) 64 Bit Os may not have the correct ODBC access driver


How to Handle Cross thread UI Error in C#.net


It can be handled using deligates in c#

Sunday, 5 May 2013

Is it Possible to Run ASP.net applications in Linux

Yes, It is possible by the help of Apache using modmono, Now i am using this for to run an asp.net website in linux .

How to Add file reference in C#.net /Mono


Just open the project , Right click on project --> Click Add reference -- Select the Ref Dll from list or browse to the dll


Ajax File upload with progress using ajax tool kit

In ASPX File
// You have to download and reffer ajax tool kit

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="ajaxToolkit" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>

     <script type="text/javascript">


         function onClientUploadComplete(sender, e) {
             var id = e.get_fileId();
             onImageValidated("TRUE", e);
         }

         function onImageValidated(arg, context) {

             var test = document.getElementById("testuploaded");
             test.style.display = 'block';

             var fileList = document.getElementById("fileList");
             var item = document.createElement('div');
             item.style.padding = '4px';

             if (arg == "TRUE") {
                 var url = context.get_postedUrl();
                 url = url.replace('&amp;', '&');
                 item.appendChild(createThumbnail(context, url));
             } else {
                 item.appendChild(createFileInfo(context));
             }

             fileList.appendChild(item);

         }

         function createFileInfo(e) {
             var holder = document.createElement('div');
             holder.appendChild(document.createTextNode(e.get_fileName() + ' with size ' + e.get_fileSize() + ' bytes'));

             return holder;
         }

         function createThumbnail(e, url) {
             var holder = document.createElement('div');
             var img = document.createElement("img");
             img.style.width = '80px';
             img.style.height = '80px';
             img.setAttribute("src", url);

             holder.appendChild(createFileInfo(e));
             holder.appendChild(img);

             return holder;
         }
           </script>
</head>
<body>
    <form id="form1" runat="server">
        <ajaxToolkit:ToolkitScriptManager runat="Server" EnablePartialRendering="true" ID="ScriptManager1" />
    <div class="demoarea">
        <div class="demoheading">
            AjaxFileUpload Demonstration</div>
        Click <i>Select File</i> to select an image file to upload. You can upload a maximum
        of 10 jpeg files (files with the .jpg or .jpeg extension)
        <br />
        <asp:Label runat="server" ID="myThrobber" Style="display: none;"><img align="absmiddle" alt="" src="uploading.gif"/></asp:Label>
        <ajaxToolkit:AjaxFileUpload ID="AjaxFileUpload1" runat="server" Padding-Bottom="4"
            Padding-Left="2" Padding-Right="1" Padding-Top="4" ThrobberID="myThrobber" OnClientUploadComplete="onClientUploadComplete"
            OnUploadComplete="AjaxFileUpload1_OnUploadComplete" MaximumNumberOfFiles="10"
            AllowedFileTypes="jpg,jpeg" />
        <br />
        <div id="testuploaded" style="display: none; padding: 4px; border: gray 1px solid;">
            <h4>
                list of uploaded files:</h4>
            <hr />
            <div id="fileList">
            </div>
        </div>
       
    </div>
    <div class="demobottom">
    </div>
   
    </form>
</body>
</html>





In C# Code behind
================

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using AjaxControlToolkit;
public partial class _Default : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        
     
        }
    }

    protected void AjaxFileUpload1_OnUploadComplete(object sender, AjaxFileUploadEventArgs file)
    {
        
      
     // your code here to save the file after upload
        
    }
    
}