一个初学者的问题?

123bug 2001-07-16 09:53:55
我是一个刚刚学VC的
今天用MFC Appwizard(exe)建立了一个简单的“基本对话”项目
可编译是出现了一下错误,我不知道是什么原因,请各位帮我解决!

--------------------Configuration: ddd - Win32 Debug--------------------
Compiling resources...
Compiling...
StdAfx.cpp
Compiling...
ddd.cpp
E:\ddd\ddd.cpp(37) : fatal error C1001: INTERNAL COMPILER ERROR
(compiler file 'msc1.cpp', line 1786)
Please choose the Technical Support command on the Visual C++
Help menu, or open the Technical Support help file for more information
dddDlg.cpp
Generating Code...
Error executing cl.exe.

ddd.exe - 1 error(s), 0 warning(s)
...全文
186 23 打赏 收藏 转发到动态 举报
AI 作业
写回复
用AI写文章
23 条回复
切换为时间正序
请发表友善的回复…
发表回复
123bug 2001-07-26
  • 打赏
  • 举报
回复
g
tryibest 2001-07-26
  • 打赏
  • 举报
回复
重装也能得分,真高兴
123bug 2001-07-25
  • 打赏
  • 举报
回复
谢谢,给分!
tryibest 2001-07-24
  • 打赏
  • 举报
回复
接上,
其中的原因只有等高手,解决了,说一下,我第一次装也是创天的中文版,可能是这个公司的光盘的问题
tryibest 2001-07-24
  • 打赏
  • 举报
回复
这个问题我以前也碰到过,什么程序也不能
编译,重装vc也没有用,我重装了win98就好了
hitwd2000 2001-07-24
  • 打赏
  • 举报
回复
找个英文版安装一下吧
ajun21cn 2001-07-24
  • 打赏
  • 举报
回复
关注
kenny_yuan 2001-07-24
  • 打赏
  • 举报
回复
创天?
不新鲜了!
Cline 2001-07-17
  • 打赏
  • 举报
回复
可以把你的代码(最好整个projct打个包)email给我们测试测试,再看看了
Clineyuan@sina.com.cn
123bug 2001-07-17
  • 打赏
  • 举报
回复
究竟是什么原因?
是不是我的VC++有问题?
我用的是VISUAL STUDIO6.0共计8张盘
VC++是叫创天的汉化版!

为什么我的VC不能用MFC类(可能是)
这是用VC自动生成的程序
我在网上下载了一个程序代码,
编译也有错,也是出在MFC的类上,真搞不懂
我是初学者,从来没用个VC编程







// abc.cpp : Defines the class behaviors for the application.
//

#include "stdafx.h"
#include "abc.h"
#include "abcDlg.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// CAbcApp

BEGIN_MESSAGE_MAP(CAbcApp, CWinApp)
//{{AFX_MSG_MAP(CAbcApp)
// NOTE - the ClassWizard will add and remove mapping macros here.
// DO NOT EDIT what you see in these blocks of generated code!
//}}AFX_MSG
ON_COMMAND(ID_HELP, CWinApp::OnHelp)
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CAbcApp construction

CAbcApp::CAbcApp()
{
// TODO: add construction code here,
// Place all significant initialization in InitInstance
}

/////////////////////////////////////////////////////////////////////////////
// The one and only CAbcApp object

CAbcApp theApp;

/////////////////////////////////////////////////////////////////////////////
// CAbcApp initialization

BOOL CAbcApp::InitInstance()
{
AfxEnableControlContainer();

// Standard initialization
// If you are not using these features and wish to reduce the size
// of your final executable, you should remove from the following
// the specific initialization routines you do not need.

#ifdef _AFXDLL
Enable3dControls(); // Call this when using MFC in a shared DLL
#else
Enable3dControlsStatic(); // Call this when linking to MFC statically
#endif

CAbcDlg dlg;
m_pMainWnd = &dlg;
int nResponse = dlg.DoModal();
if (nResponse == IDOK)
{
// TODO: Place code here to handle when the dialog is
// dismissed with OK
}
else if (nResponse == IDCANCEL)
{
// TODO: Place code here to handle when the dialog is
// dismissed with Cancel
}

// Since the dialog has been closed, return FALSE so that we exit the
// application, rather than start the application's message pump.
return FALSE;
}


第37行就是CAbcApp theApp;






Cline 2001-07-17
  • 打赏
  • 举报
回复
編譯后,按一下F4,如果會跳到什麼地方(line37),把它貼出來讓大家看看再想辦法.
azuo_lee 2001-07-17
  • 打赏
  • 举报
回复
逐个去掉编译优化选项(工程设置的C/C++选项卡),试试行不行。
123bug 2001-07-17
  • 打赏
  • 举报
回复
我都做了,还是不行!
kenny_yuan 2001-07-16
  • 打赏
  • 举报
回复
编译器内部错误,需要重建工程(或调整参数)
有可能是死机导致文件损坏造成的。
也有可能是VC需要重装造成的。
重启一次机器有时会好。
cpp文件本身一般没有问题。
123bug 2001-07-16
  • 打赏
  • 举报
回复
#ifndef __AFXWIN_H__
#error include 'stdafx.h' before including this file for PCH
#endif

#include "resource.h" // main symbols

/////////////////////////////////////////////////////////////////////////////
// CDddApp:
// See ddd.cpp for the implementation of this class
//

class CDddApp : public CWinApp
{
public:
CDddApp();

// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CDddApp)
public:
virtual BOOL InitInstance();
//}}AFX_VIRTUAL

// Implementation

//{{AFX_MSG(CDddApp)
// NOTE - the ClassWizard will add and remove member functions here.
// DO NOT EDIT what you see in these blocks of generated code !
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};


/////////////////////////////////////////////////////////////////////////////

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_DDD_H__CE0BC309_C34C_4B59_8B56_EDEEB7F8B883__INCLUDED_)



这是CDDDAPP
zhang_qxian 2001-07-16
  • 打赏
  • 举报
回复
你将你的CPP贴出来看一看。上面这段没有问题!
123bug 2001-07-16
  • 打赏
  • 举报
回复
能告诉我在哪里的设置呀?
nickysoft 2001-07-16
  • 打赏
  • 举报
回复
编译应该没问题,可能出在LINKING上,检查你的设置。
123bug 2001-07-16
  • 打赏
  • 举报
回复
这是VC自动生成的程序!




/////////////////////////////////////////////////////////////////////////////
// CDddApp construction

CDddApp::CDddApp()
{
// TODO: add construction code here,
// Place all significant initialization in InitInstance
}

/////////////////////////////////////////////////////////////////////////////
// The one and only CDddApp object

CDddApp theApp;

/////////////////////////////////////////////////////////////////////////////
// CDddApp initialization

BOOL CDddApp::InitInstance()
{
AfxEnableControlContainer();

// Standard initialization
// If you are not using these features and wish to reduce the size
// of your final executable, you should remove from the following
// the specific initialization routines you do not need.

#ifdef _AFXDLL
Enable3dControls(); // Call this when using MFC in a shared DLL
#else
Enable3dControlsStatic(); // Call this when linking to MFC statically
#endif

CDddDlg dlg;
m_pMainWnd = &dlg;
int nResponse = dlg.DoModal();
if (nResponse == IDOK)
{
// TODO: Place code here to handle when the dialog is
// dismissed with OK
}
else if (nResponse == IDCANCEL)
{
// TODO: Place code here to handle when the dialog is
// dismissed with Cancel
}

// Since the dialog has been closed, return FALSE so that we exit the
// application, rather than start the application's message pump.
return FALSE;
}
lianhuiyong 2001-07-16
  • 打赏
  • 举报
回复
应该是编译时出现的错误,由此判断是语法错误。在你的程序的37行,你可以把37行也帖出来,或者自己检查修改以下
加载更多回复(3)

16,548

社区成员

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

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

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