在线等,奇怪的问题!

jxfzamdzyx 2004-07-10 04:39:35
我程序是在win2000sever下写的刻录在光盘上,现在在win98下运行刚开始几次没事,多运行几次后,按钮上的字体没了,如果重新装vc,运行有字体的程序,过一阵子又是这样!以前在win2000从来不会出现这种情况!我该怎么办,急!(我按钮是使用一个类,重画其颜色和边框)
...全文
183 11 打赏 收藏 转发到动态 举报
写回复
用AI写文章
11 条回复
切换为时间正序
请发表友善的回复…
发表回复
jdzwq 2004-07-11
  • 打赏
  • 举报
回复
增补:
在响应WM_PAINT的绘制函数中,千万不要试图动态创建资源,即使在出函数时匹配地释放了所有资源,也会引发资源耗尽,只是Win98来得更快,Win2000迟早也会发生,对这种情况,本人也曾吃尽苦头,如有类似情况,请诸位及早回头,绕道而行。
jdzwq 2004-07-11
  • 打赏
  • 举报
回复
请检查你的绘制函数,在循环中创建资源(画刷,字体,画笔等),即使用delteobject删除了,也会产生以上问题,建议你预先创建几中资源样式,然后在绘制函数中用SelectObject选择它,应该不会再有如上问题。
liuyuejob 2004-07-10
  • 打赏
  • 举报
回复
pdf ? 什么东西?
ringphone 2004-07-10
  • 打赏
  • 举报
回复
工程目录下只留dsw,dsp和源代码,资源等文件,其他都删掉,然后rebuild all。
jxfzamdzyx 2004-07-10
  • 打赏
  • 举报
回复
现在就是找不到pdf文件,怎么删!
liuyuejob 2004-07-10
  • 打赏
  • 举报
回复
把..pdb文件删掉,中间文件也删掉,rebuild all,如果还不行,可能是控件类有问题
jxfzamdzyx 2004-07-10
  • 打赏
  • 举报
回复
我是在98下编译的呀!
好象正如laiyling(最熟悉的陌生人)所说!
当我按F7出现下面情况:
RC : fatal error RC1109 : error creating Debug/FMXL1.res
Error executing rc.exe.:fmxl1\ascill.cpp(4) : fatal error C1033: cannot open program database '
d:\fmxl1\debug\vc60.pdb'
当我按运行程序出现下面情况:
FMXL1.cpp
d:\fmxl1\fmxl1.cpp(4) : fatal error C1033: cannot open program database '
d:\fmxl1\debug\vc60.pdb'
FMXL1Dlg.cpp
d:\fmxl1\fmxl1dlg.cpp(4) : fatal error C1033: cannot open program database '
d:\fmxl1\debug\vc60.pdb'
LOOKDATA.cpp
d:\fmxl1\lookdata.cpp(4) : fatal error C1033: cannot open program database '
d:\fmxl1\debug\vc60.pdb'
Splash.cpp
d:\fmxl1\splash.cpp(5) : fatal error C1033: cannot open program database '
d:\fmxl1\debug\vc60.pdb'
USER.cpp
d:\fmxl1\user.cpp(4) : fatal error C1033: cannot open program database '
d:\fmxl1\debug\vc60.pdb'
XPButton.cpp
d:\fmxl1\xpbutton.cpp(4) : fatal error C1033: cannot open program database '
d:\fmxl1\debug\vc60.pdb'
Generating Code...
Error executing cl.exe.

FMXL1.exe - 7 error(s), 1 warning(s)
但如果我直接按F5则会弹出询问please enter the path for mfcsd42.pdb.按取消,则程序运行都正常但就是button的字体没有,其它控件字体都有!是不是跟我控件继承的类有关?我该怎么办!
liuyuejob 2004-07-10
  • 打赏
  • 举报
回复
在98下重新编译一下好象就行,你试试看
Kudeet 2004-07-10
  • 打赏
  • 举报
回复
The .PDB file is so-called program database file, the Visual C++ compiler generates this file to allow you debug your application. We you are debugging your application, you will (in most cases) see the source code, and you will be able to go through them line by line by pressing F10 or F11. This file is usually very big and contains the file and line information of the functions you called in your source code. You really don't need to see them, but, just out of curiosity, you can open this file in Visual C++ IDE in binary mode.
jxfzamdzyx 2004-07-10
  • 打赏
  • 举报
回复
那是不是又要回到win2000下去写呀好象在win98下第一次运行会弹出询问please enter the path for mfcsd42.pdb.我一般按取消!
王国凡 2004-07-10
  • 打赏
  • 举报
回复
应该是程序中用到了 Win2000 有但 Win98 里没有的 API 函数 .

16,471

社区成员

发帖
与我相关
我的任务
社区描述
VC/MFC相关问题讨论
社区管理员
  • 基础类社区
  • Web++
  • encoderlee
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告

        VC/MFC社区版块或许是CSDN最“古老”的版块了,记忆之中,与CSDN的年龄几乎差不多。随着时间的推移,MFC技术渐渐的偏离了开发主流,若干年之后的今天,当我们面对着微软的这个经典之笔,内心充满着敬意,那些曾经的记忆,可以说代表着二十年前曾经的辉煌……
        向经典致敬,或许是老一代程序员内心里面难以释怀的感受。互联网大行其道的今天,我们期待着MFC技术能够恢复其曾经的辉煌,或许这个期待会永远成为一种“梦想”,或许一切皆有可能……
        我们希望这个版块可以很好的适配Web时代,期待更好的互联网技术能够使得MFC技术框架得以重现活力,……

试试用AI创作助手写篇文章吧