Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Languages / Managed C++ / July 2005

Tip: Looking for answers? Try searching our database.

First Visual Studio C++.net Project

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Larry Bird - 17 May 2005 01:05 GMT
I'm attempting to build my first VC++ .net project and I'm unable to get a
clean compile.  Please view code below:

// This is the main project file for VC++ application project
// generated using an Application Wizard.

#include "stdafx.h"

#using <mscorlib.dll>

using namespace System;

int _tmain()
{
   // TODO: Please replace the sample code below with your own.
   Console::WriteLine(S"Hello World");
    return 0;
}

The above code is very simple nothing fancy.  I continue to get a compile
error however, not errors are display in the output window.  What ever the
error is it's not allowing the "exe" to be built.  

Does any one see anthing wrong?  Where else should I be looking to locate
what's wrong?
thanks
Larry Bird - 17 May 2005 01:09 GMT
I generated the project using Application Wizard.
thanks

> I'm attempting to build my first VC++ .net project and I'm unable to get a
> clean compile.  Please view code below:
[quoted text clipped - 22 lines]
> what's wrong?
> thanks
Peter van der Goes - 17 May 2005 03:24 GMT
>I generated the project using Application Wizard.
> thanks
[quoted text clipped - 27 lines]
>> what's wrong?
>> thanks

What C++ project template are you using?

Signature

Peter [MVP Visual Developer]
Jack of all trades, master of none.

Larry Bird - 17 May 2005 03:31 GMT
I'm trying to build a console application for starters.

Thanks

> >I generated the project using Application Wizard.
> > thanks
[quoted text clipped - 29 lines]
> >>
> What C++ project template are you using?
Larry Bird - 17 May 2005 03:33 GMT
I'm trying to use the console template.

Thanks

> >I generated the project using Application Wizard.
> > thanks
[quoted text clipped - 29 lines]
> >>
> What C++ project template are you using?
Peter van der Goes - 17 May 2005 14:04 GMT
> I'm trying to use the console template.
>
> Thanks

OK, I've copied the code in your original post into a Console Application
shell here, and it compiles without error and runs correctly. That
exonerates the code. How long have you had Visual Studio installed (And,
please say which version you have. I use Visual Studio .NET 2003), and have
you tried any other project/template types to see if they work (a simple VB
Windows app, for instance)?
Right now, it looks as if there is something wrong with your installation,
and with only the symptoms reported to go on, I'd suggest a repair install
of Visual Studio.

Signature

Peter [MVP Visual Developer]
Jack of all trades, master of none.

Larry Bird - 17 May 2005 03:21 GMT
Here's the out of my compile:

Build Log      ------- Build started: Project: ASimpleProject,
Configuration: Debug|Win32 -------

Command Lines      Creating temporary file "c:\Documents and
Settings\louis.AZALEA\My Documents\Visual Studio
Projects\ASimpleProject\ASimpleProject\Debug\RSP000005.rsp" with contents
[
/Od /AI "C:\Documents and Settings\louis.AZALEA\My Documents\Visual Studio
Projects\ASimpleProject\Debug" /D "WIN32" /D "_DEBUG" /D "_MBCS" /FD /EHsc
/MTd /GS /Yu"stdafx.h" /Fp"Debug/ASimpleProject.pch" /Fo"Debug/"
/Fd"Debug/vc70.pdb" /W3 /c /Zi /clr /TP /FU
"C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\mscorlib.dll"
/FU "C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\System.dll"
/FU "C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\System.Data.dll"
".\AssemblyInfo.cpp"
".\ASimpleProject.cpp"
]
Creating command line "cl.exe @"c:\Documents and Settings\louis.AZALEA\My
Documents\Visual Studio
Projects\ASimpleProject\ASimpleProject\Debug\RSP000005.rsp" /nologo"
Creating temporary file "c:\Documents and Settings\louis.AZALEA\My
Documents\Visual Studio
Projects\ASimpleProject\ASimpleProject\Debug\RSP000006.rsp" with contents
[
/Od /AI "C:\Documents and Settings\louis.AZALEA\My Documents\Visual Studio
Projects\ASimpleProject\Debug" /D "WIN32" /D "_DEBUG" /D "_MBCS" /FD /EHsc
/MTd /GS /Yc"stdafx.h" /Fp"Debug/ASimpleProject.pch" /Fo"Debug/"
/Fd"Debug/vc70.pdb" /W3 /c /Zi /clr /TP /FU
"C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\mscorlib.dll"
/FU "C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\System.dll"
/FU "C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\System.Data.dll"
".\stdafx.cpp"
]
Creating command line "cl.exe @"c:\Documents and Settings\louis.AZALEA\My
Documents\Visual Studio
Projects\ASimpleProject\ASimpleProject\Debug\RSP000006.rsp" /nologo"
Output Window       Results      Build log was saved at
"file://c:\Documents and Settings\louis.AZALEA\My Documents\Visual Studio
Projects\ASimpleProject\ASimpleProject\Debug\BuildLog.htm"
ASimpleProject - 1 error(s), 0 warning(s)

Thanks

> I'm attempting to build my first VC++ .net project and I'm unable to get a
> clean compile.  Please view code below:
[quoted text clipped - 22 lines]
> what's wrong?
> thanks
Carl Daniel [VC++ MVP] - 17 May 2005 03:36 GMT
> Here's the out of my compile:

<build log snipped>

Could you post the text from the Output window in the VC++ IDE?
Unfortunately, the build log doesn't show what the errors were - just that
there were errors.

-cd
Larry Bird - 17 May 2005 03:42 GMT
The output is below:
------ Build started: Project: ASimpleProject, Configuration: Debug Win32
------

Build log was saved at "file://c:\Documents and Settings\louis.AZALEA\My
Documents\Visual Studio
Projects\ASimpleProject\ASimpleProject\Debug\BuildLog.htm"
ASimpleProject - 1 error(s), 0 warning(s)

---------------------- Done ----------------------

   Build: 0 succeeded, 1 failed, 0 skipped

Thanks

> > Here's the out of my compile:
>
[quoted text clipped - 5 lines]
>
> -cd
John Gabriel - 17 May 2005 04:35 GMT
Larry,
 Have you tried rebuilding it twice? I have found that it usually reports
no errors on the second attempt.

John Gabriel

> The output is below:
> ------ Build started: Project: ASimpleProject, Configuration: Debug Win32
[quoted text clipped - 20 lines]
> >
> > -cd
Larry Bird - 17 May 2005 13:08 GMT
I've tried building it serveral times and get the same results.  I've also
perform a run on it and received the message that the project is out of date.
I click the yes button to build the project and still get the same results.  

Does anyone know what might be happing here.

Thanks

> Larry,
>   Have you tried rebuilding it twice? I have found that it usually reports
[quoted text clipped - 26 lines]
> > >
> > > -cd
David - 19 Jul 2005 17:33 GMT
Yeah I know what your problem is, I'm having the same problem.  However, I do
not know what to do since I'm having the same problem.  When you create that
app there are two files needed to compile that code, AssemblyInfo.cpp,
stdafx.cpp, and some other ones.  One of two of them are not loading,  

> I've tried building it serveral times and get the same results.  I've also
> perform a run on it and received the message that the project is out of date.
[quoted text clipped - 34 lines]
> > > >
> > > > -cd

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.