// 學(xué)生管理.cpp : Defines the entry point for the application.
//
#include "stdafx.h"
#include "resource.h"
#define MAX_LOADSTRING 100
// Global Variables:
HINSTANCE hInst; // current instance
TCHAR szTitle[MAX_LOADSTRING]; // The title bar text
TCHAR szWindowClass[MAX_LOADSTRING]; // The title bar text
// Foward declarations of functions included in this code module:
ATOM MyRegisterClass(HINSTANCE hInstance);
BOOL InitInstance(HINSTANCE, int);
LRESULT CALLBACK WndProc(HWND, UINT, WPARAM, LPARAM);
LRESULT CALLBACK About(HWND, UINT, WPARAM, LPARAM);
struct person
{
char name[10];
int ID;
int cj_yw;
int cj_sx;
struct person* next;
struct person* pro;
}per;
int APIENTRY WinMain(HINSTANCE hInstance,
HINSTANCE hPrevInstance,
LPSTR lpCmdLine,
int nCmdShow)
{
// TODO: Place code here.
MSG msg;
HACCEL hAccelTable;
// Initialize global strings
LoadString(hInstance, IDS_APP_TITLE, szTitle, MAX_LOADSTRING);
LoadString(hInstance, IDC_MY, szWindowClass, MAX_LOADSTRING);
MyRegisterClass(hInstance);
// Perform application initialization:
if (!InitInstance (hInstance, nCmdShow))
{
return FALSE;
}
hAccelTable = LoadAccelerators(hInstance, (LPCTSTR)IDC_MY);
// Main message loop:
while (GetMessage(&msg, NULL, 0, 0))
{
if (!TranslateAccelerator(msg.hwnd, hAccelTable, &msg))
{
TranslateMessage(&msg);
DispatchMessage(&msg);
}
}
return msg.wParam;
}
//
// FUNCTION: MyRegisterClass()
//
// PURPOSE: Registers the window class.
//
// COMMENTS:
//
// This function and its usage is only necessary if you want this code
// to be compatible with Win32 systems prior to the 'RegisterClassEx'
// function that was added to Windows 95. It is important to call this function
// so that the application will get 'well formed' small icons associated
// with it.
//
ATOM MyRegisterClass(HINSTANCE hInstance)
{
WNDCLASSEX wcex;
wcex.cbSize = sizeof(WNDCLASSEX);
wcex.style = CS_HREDRAW | CS_VREDRAW;
wcex.lpfnWndProc = (WNDPROC)WndProc;
wcex.cbClsExtra = 0;
wcex.cbWndExtra = 0;
wcex.hInstance = hInstance;
wcex.hIcon = LoadIcon(hInstance, (LPCTSTR)IDI_MY);
wcex.hCursor = LoadCursor(NULL, IDC_ARROW);
wcex.hbrBackground = (HBRUSH)(COLOR_WINDOW+1);
wcex.lpszMenuName = (LPCSTR)IDC_MY;
wcex.lpszClassName = szWindowClass;
wcex.hIconSm = LoadIcon(wcex.hInstance, (LPCTSTR)IDI_SMALL);
return RegisterClassEx(&wcex);
}
//
// FUNCTION: InitInstance(HANDLE, int)
//
// PURPOSE: Saves instance handle and creates main window
//
// COMMENTS:
//
// In this function, we save the instance handle in a global variable and
// create and display the main program window.
//
BOOL InitInstance(HINSTANCE hInstance, int nCmdShow)
{
HWND hWnd;
hInst = hInstance; // Store instance handle in our global variable
hWnd = CreateWindow(szWindowClass, szTitle, WS_OVERLAPPEDWINDOW,
CW_USEDEFAULT, 0, CW_USEDEFAULT, 0, NULL, NULL, hInstance, NULL);
if (!hWnd)
{
return FALSE;
}
ShowWindow(hWnd, nCmdShow);
UpdateWindow(hWnd);
return TRUE;
}
//
// FUNCTION: WndProc(HWND, unsigned, WORD, LONG)
//
// PURPOSE: Processes messages for the main window.
//
// WM_COMMAND - process the application menu
// WM_PAINT - Paint the main window
// WM_DESTROY - post a quit message and return
//
//
LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
{
int wmId, wmEvent;
PAINTSTRUCT ps;
HDC hdc;
TCHAR szHello[MAX_LOADSTRING];
LoadString(hInst, IDS_HELLO, szHello, MAX_LOADSTRING);
switch (message)
{
case WM_COMMAND:
wmId = LOWORD(wParam);
wmEvent = HIWORD(wParam);
// Parse the menu selections:
switch (wmId)
{
case IDM_ABOUT:
DialogBox(hInst, (LPCTSTR)IDD_ABOUTBOX, hWnd, (DLGPROC)About);
break;
case IDM_EXIT:
DestroyWindow(hWnd);
break;
default:
return DefWindowProc(hWnd, message, wParam, lParam);
}
break;
case WM_PAINT:
hdc = BeginPaint(hWnd, &ps);
// TODO: Add any drawing code here...
RECT rt;
GetClientRect(hWnd, &rt);
DrawText(hdc, szHello, strlen(szHello), &rt, DT_CENTER);
EndPaint(hWnd, &ps);
break;
case WM_DESTROY:
PostQuitMessage(0);
break;
default:
return DefWindowProc(hWnd, message, wParam, lParam);
}
return 0;
}
// Mesage handler for about box.
LRESULT CALLBACK About(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
{
switch (message)
{
case WM_INITDIALOG:
return TRUE;
case WM_COMMAND:
if (LOWORD(wParam) == IDOK || LOWORD(wParam) == IDCANCEL)
{
EndDialog(hDlg, LOWORD(wParam));
return TRUE;
}
break;
}
return FALSE;
}
資源簡介:我以前做的一個比較簡單的c語言計算器 很容易看懂
上傳時間: 2015-04-29
上傳用戶:zmy123
資源簡介:簡單計算器的c++源碼,該計算器比較簡易
上傳時間: 2013-12-23
上傳用戶:大三三
資源簡介:C#開發(fā)的簡單計算器,和windows自帶的計算器功能差不多.
上傳時間: 2016-03-03
上傳用戶:Amygdala
資源簡介:用Visual C++實現(xiàn)計算器,簡單的加、減、乘、除運算
上傳時間: 2016-04-10
上傳用戶:waizhang
資源簡介:簡單計算器仿真
上傳時間: 2013-11-22
上傳用戶:ginani
資源簡介:C++實現(xiàn)計算器
上傳時間: 2015-02-11
上傳用戶:chongcongying
資源簡介:一個簡單計算器的java源代碼
上傳時間: 2014-01-01
上傳用戶:康郎
資源簡介:用java實現(xiàn)的一個簡單計算器
上傳時間: 2014-01-06
上傳用戶:asdfasdfd
資源簡介:這是一用單片機實現(xiàn)的簡單計算器
上傳時間: 2014-12-01
上傳用戶:ljmwh2000
資源簡介:使用c++簡單實現(xiàn)ATM自動提款機,只是簡單實現(xiàn)沒有考慮時間問題
上傳時間: 2015-03-19
上傳用戶:bakdesec
資源簡介:簡單計算器(帶密碼“111111”) 進行簡單的數(shù)字計算 包括“+” “-” “*” “/” “乘方”
上傳時間: 2015-03-31
上傳用戶:ljmwh2000
資源簡介:實現(xiàn)加減乘除的簡單計算器,可以將0顯示在輸入的右面.
上傳時間: 2014-09-02
上傳用戶:2404
資源簡介:一個簡單計算器程序,實現(xiàn)兩個操作數(shù)的運算,包括加減乘除
上傳時間: 2015-05-01
上傳用戶:Zxcvbnm
資源簡介:C51單片機實現(xiàn)液晶秒表以及簡單計算器 電路是一個51最小系統(tǒng),沒有采用總線方式,而簡單的連線方式,上有4*4矩陣鍵盤,一數(shù)碼管,89S51單片機,串口下載線,數(shù)碼管顯示鎖存芯片\蜂鳴器\1602液晶. 代碼已經(jīng)調(diào)試成功過,可以實現(xiàn)時間的調(diào)整.4*4矩陣鍵盤,第一排...
上傳時間: 2015-08-17
上傳用戶:cursor
資源簡介:用delphi做的一個簡單計算器程序,已經(jīng)調(diào)試運行過了!
上傳時間: 2015-08-19
上傳用戶:皇族傳媒
資源簡介:Visual C++ 簡單的學(xué)習(xí)教程,適合初學(xué)者,網(wǎng)頁方式,方便學(xué)習(xí)使用
上傳時間: 2013-12-19
上傳用戶:邶刖
資源簡介:實現(xiàn)一個簡單計算器,模擬windows自帶計算器實現(xiàn)
上傳時間: 2013-12-27
上傳用戶:1051290259
資源簡介:簡單計算器,用VB編程
上傳時間: 2015-09-21
上傳用戶:天誠24
資源簡介:51單片機實現(xiàn) 液晶秒表以 及簡單計算器
上傳時間: 2013-12-26
上傳用戶:xc216
資源簡介:用VHDL語言實現(xiàn)0--100范圍內(nèi)簡單計算器功能的源代碼,包括加減乘除四種運算功能
上傳時間: 2015-11-04
上傳用戶:bibirnovis
資源簡介:利用JMC做的簡單計算器SimpleCalculator
上傳時間: 2014-06-16
上傳用戶:BIBI
資源簡介:這是一個用VC編寫的簡單計算器,原文件是在C#的環(huán)境下運行的。
上傳時間: 2016-02-04
上傳用戶:hakim
資源簡介:java編寫的簡單計算器代碼,可顯示運算式,使用StringTokenizer區(qū)分出運算符。代碼清晰易讀。
上傳時間: 2013-11-26
上傳用戶:qq1604324866
資源簡介:此示例是一個用于 Pocket PC 的簡單計算器應(yīng)用程序。它使用多個 Windows 窗體控件且僅在 Visual Basic 中可用。
上傳時間: 2014-01-23
上傳用戶:wang5829
資源簡介:C51彈片機簡單計算器,可以計算加減乘除等簡單 計算功能
上傳時間: 2014-01-14
上傳用戶:ecooo
資源簡介:一個圖像化的C語言計算器程序,有興趣的可以
上傳時間: 2016-02-28
上傳用戶:lxm
資源簡介:計算用JAVA語言編寫一些小程序,簡單計算器,繪圖等.用JAVA語言編寫銀行管理系統(tǒng).
上傳時間: 2014-01-04
上傳用戶:yan2267246
資源簡介:Matlab中用GUI設(shè)計一簡單計算器。
上傳時間: 2013-12-17
上傳用戶:youke111
資源簡介:用匯編語言編寫的簡單計算器,帶LCM控制程序。
上傳時間: 2013-11-29
上傳用戶:xjz632
資源簡介:簡單計算器,加減乘除。只是適用于剛剛初學(xué)DELPHI的同學(xué)。
上傳時間: 2014-01-17
上傳用戶:小眼睛LSL