Tuesday, March 11, 2014

ARITHMETIC CALCULATOR

Calculator

ONLINE CALCULATOR

PRESS C FOR "CLEAR SCREEN"

Thursday, January 30, 2014

HTML


SIMPLE HOMEPAGE FOR EASY NAVIGATION TO FREQUENTLY VISITING WEBSITE:

<html>
    <head>
        <title> Home page </title>
    </head>
        <body>
            <h1>WELCOME TO HOME PAGE</h1>
            <body bgcolor="blue" text="black">
            <a href="http//www.google.com"><input type="button" value="Google"></a></br>
            <a href="http//www.googlemaps.com"><input type="button"  value="Google Map"></a></br>
          
            <a href="http//www.wikipedia.com"><input type="button"  value="WIKIPEDIA"></a></br>
          
            <a href="http//www.ragava08.blogspot.com"><input type="button"  value="ragava08"></a></br>
          
        </body>
</html>
------
NOTE: <a href="http//www.google.com"> //In above code,Change the URL specified in these tags for customized usage.

Saturday, September 21, 2013

Online Compile for "C"


Enter your name:

C-Gods Programming Language

"C Language"

#include <stdio .h>
//SUM OF TWO NUMBERS

main()
{
  
      int a,b,c;
      printf("Enter two numbers to add");
      scanf("%d%d",&amp;a,&amp;b);
      c=a+b;
      printf("Result=",a);
     
  
}

Saturday, September 14, 2013

9-PLANETS-POSITION


Enter your name:

GROWING


Dynamic Positioning

Welcome!

Sunday, September 8, 2013

Windows program-Mouse Event-1(win32)

MOUSE EVENT I

Program:

MouseEvents.C


#include <windows.h>
LRESULT CALLBACK WndProc (HWND,UINT,WPARAM,LPARAM);
int WINAPI WinMain ( HINSTANCE hInstance, HINSTANCE hPrevInstance, PSTR szCmdLine, int iCmdShow )
{
 static  TCHAR szAppName[]=TEXT ("HELLO");
HWND hwnd;
MSG msg;
// DECLARING AND INTIAZING THE WINDOW CLASS
WNDCLASS wc;                                                       // Window class declaration
wc.style = CS_HREDRAW| CS_VREDRAW;        // Window style
wc. lpfnWndProc = WndProc;                                   // Window Procedure
wc.cbClsExtra = 0;                                                     // Extra Parameters
wc.cbWndExtra = 0;                                                   // Extra Parameters
wc.hInstance = hInstance;                                          // Instance handle
wc.hIcon = LoadIcon (NULL, IDI_APPLICATION); // Icon
wc.hCursor = LoadCursor (NULL, IDC_ARROW);            // Window Cursor
wc.hbrBackground = (HBRUSH) GetStockObject (WHITE_BRUSH);
                                                                                    // Set Background Color
wc.lpszMenuName = NULL;                                     // Menu Handle
wc.lpszClassName = szAppName;                             // Class Name
// REGISTERING THE WINDOW CLASS
if (!RegisterClass (&wc))
{
            MessageBox(NULL, TEXT("This program requires WindowsNT!"), szAppName, MB_ICONERROR);
            return 0;
}
// CREATING THE WINDOW
hwnd = CreateWindow ( szAppName,                                  // window class name
TEXT("The Hello Program"), // window caption 
WS_OVERLAPPEDWINDOW,      // window style
CW_USEDEFAULT,                                    // initial x position
CW_USEDEFAULT,                                    // initial x position
CW_USEDEFAULT,                                    // initial x position
CW_USEDEFAULT,                                    // initial x position
NULL,                                                            // parent window handle
NULL,                                                            // window menu handle
hInstance,                                          //program instance handle
NULL);                                               // creation parameters
// DISPLAYING THE WINDOW
            ShowWindow (hwnd, iCmdShow);              
            UpdateWindow (hwnd);
// PROCESSING THE MESSAGE LOOP
                                    while (GetMessage(&msg,NULL,0,0))          // extracts message from Message Queue
{
                        TranslateMessage (&msg);
                        DispatchMessage (&msg);                  // dispatches the message received
            }
            return msg.wParam;
}

// WINDOW PROCEDURE FUNCTION
LRESULT CALLBACK WndProc (HWND hwnd,UINT message,WPARAM wparam,LPARAM lparam)
{
            char left[]="How are u?";
            char right[]="Hello";
            switch (message)
            {
            case WM_LBUTTONDOWN:           // Left mouse button press message
                        MessageBox(GetFocus(),left,"Left Mouse Button Pressed",MB_OK);
                        return 0;
            case WM_RBUTTONDOWN:          // Right mouse button press message
                        MessageBox(GetFocus(),right,"Right Mouse Button Pressed",MB_OK);
                        return 0;
            case WM_DESTROY:                       // used to close the window
                        PostQuitMessage(0);               // used to terminate while loop in WinMain()
                        return 0;
            }
            return DefWindowProc(hwnd,message,wparam,lparam);

}
Sample Output: