没有合适的资源?快使用搜索试试~ 我知道了~
学计算机专业的学生向女生表白的小程序(满屏铺满玫瑰花)基于win32API
4星 · 超过85%的资源 需积分: 50 175 下载量 159 浏览量
2012-11-28
12:50:22
上传
评论 6
收藏 6KB TXT 举报
温馨提示
试读
8页
基于C语言和win32API。向女生表白的小程序。。满屏铺满玫瑰花,配有背景音乐,表白文字(这些都可以换成自己喜欢的)。。炫彩字显示。。
资源推荐
资源详情
资源评论
#include<time.h>
//#include<afxwin.h>
#include<stdlib.h>
#include<string>
using namespace std;
#define WM_SHOWLOVE 0x0228
HINSTANCE hInstance1;
CHAR m_strBuff1[123]="如果有一天我白发苍苍不再美丽你是否还会轻抚我的脸颊说陪我走到海角天涯如果天真的老了海真的枯了我只愿能与你相守千千万万个轮回";
char m_strBuff2[8]="asdffgg";
CHAR m_strBuff3[115]="如果可以我宁愿是个孩子空着双手站在你面前期待你的怜悯如果可以我宁愿是个乞丐从你的门前走过我渴望我的空碗能盛上你的爱";
CHAR m_strBuff4[71]="天为你而蓝花为你而艳情为你而动心为你而跳血为你而热你是我今生最美的思念";
CHAR m_Center[15]="永远爱你呵护你";//hb=Creat
LRESULT CALLBACK WndProc (HWND, UINT, WPARAM, LPARAM) ;
int WINAPI WinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance,
PSTR szCmdLine, int iCmdShow)
{
static TCHAR szAppName[] = TEXT ("AltWind") ;
HWND hwnd ;
MSG msg ;
WNDCLASS wndclass ;
wndclass.style = CS_HREDRAW | CS_VREDRAW ;
wndclass.lpfnWndProc = WndProc ;
wndclass.cbClsExtra = 0 ;
wndclass.cbWndExtra = 0 ;
//#include<afxwin.h>
#include<stdlib.h>
#include<string>
using namespace std;
#define WM_SHOWLOVE 0x0228
HINSTANCE hInstance1;
CHAR m_strBuff1[123]="如果有一天我白发苍苍不再美丽你是否还会轻抚我的脸颊说陪我走到海角天涯如果天真的老了海真的枯了我只愿能与你相守千千万万个轮回";
char m_strBuff2[8]="asdffgg";
CHAR m_strBuff3[115]="如果可以我宁愿是个孩子空着双手站在你面前期待你的怜悯如果可以我宁愿是个乞丐从你的门前走过我渴望我的空碗能盛上你的爱";
CHAR m_strBuff4[71]="天为你而蓝花为你而艳情为你而动心为你而跳血为你而热你是我今生最美的思念";
CHAR m_Center[15]="永远爱你呵护你";//hb=Creat
LRESULT CALLBACK WndProc (HWND, UINT, WPARAM, LPARAM) ;
int WINAPI WinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance,
PSTR szCmdLine, int iCmdShow)
{
static TCHAR szAppName[] = TEXT ("AltWind") ;
HWND hwnd ;
MSG msg ;
WNDCLASS wndclass ;
wndclass.style = CS_HREDRAW | CS_VREDRAW ;
wndclass.lpfnWndProc = WndProc ;
wndclass.cbClsExtra = 0 ;
wndclass.cbWndExtra = 0 ;
wndclass.hInstance = hInstance ;
wndclass.hIcon = LoadIcon (NULL, IDI_APPLICATION) ;
wndclass.hCursor = LoadCursor (NULL, IDC_ARROW) ;
wndclass.hbrBackground = (HBRUSH) GetStockObject (NULL_BRUSH) ;
wndclass.lpszMenuName = NULL ;
wndclass.lpszClassName = szAppName ;
hInstance1=hInstance;
if (!RegisterClass (&wndclass))
{
MessageBox (NULL, TEXT ("Program requires Windows NT!"),
szAppName, MB_ICONERROR) ;
return 0 ;
}
hwnd = CreateWindow (szAppName, TEXT ("请耐心的等一会儿"),
WS_POPUP,
CW_USEDEFAULT, CW_USEDEFAULT,
CW_USEDEFAULT, CW_USEDEFAULT,
NULL, NULL, hInstance, NULL) ;
ShowWindow (hwnd,SW_MAXIMIZE );
UpdateWindow (hwnd) ;
while (GetMessage (&msg, NULL, 0, 0))
{
TranslateMessage (&msg) ;
DispatchMessage (&msg) ;
}
return msg.wParam ;
wndclass.hIcon = LoadIcon (NULL, IDI_APPLICATION) ;
wndclass.hCursor = LoadCursor (NULL, IDC_ARROW) ;
wndclass.hbrBackground = (HBRUSH) GetStockObject (NULL_BRUSH) ;
wndclass.lpszMenuName = NULL ;
wndclass.lpszClassName = szAppName ;
hInstance1=hInstance;
if (!RegisterClass (&wndclass))
{
MessageBox (NULL, TEXT ("Program requires Windows NT!"),
szAppName, MB_ICONERROR) ;
return 0 ;
}
hwnd = CreateWindow (szAppName, TEXT ("请耐心的等一会儿"),
WS_POPUP,
CW_USEDEFAULT, CW_USEDEFAULT,
CW_USEDEFAULT, CW_USEDEFAULT,
NULL, NULL, hInstance, NULL) ;
ShowWindow (hwnd,SW_MAXIMIZE );
UpdateWindow (hwnd) ;
while (GetMessage (&msg, NULL, 0, 0))
{
TranslateMessage (&msg) ;
DispatchMessage (&msg) ;
}
return msg.wParam ;
剩余7页未读,继续阅读
浩世轩宇
- 粉丝: 90
- 资源: 15
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功
- 1
- 2
- 3
前往页