문제

i use visual studio 2008, and i chose a .cpp in visual c++

at first i copied a tutorial sample

#include <stdio.h>

int main()
{
 int x=1;
 int n =1;
 printf("Wie viele Zahlen wollen sie ausgeben lassen?: ");


 for(int i=0; i < n; ++i)
 {
  x*=i; // x=x*i
  printf("%d: %d\n", i, x); 
 }

 return 0;
}

but i get an error

in german:Fehler beim Starten von "rc.exe". --> Problem by statring "rc.exe"

what did i wrong?

도움이 되었습니까?

해결책 2

well finally i found the solution

vs2008 installs rc.exe in C:\Program Files\Microsoft SDKs\Windows\v6.0A\Bin and there the rc.exe was missing, so i had download rc.exe and put it into that folder.

now it works

다른 팁

OOTB를 복원하려면 아래의 단계를 수행해야합니다.

I don't think there is anything wrong with the code you posted. The error message you quoted would suggest that your project is set up to use resources and either the resource file isn't present or the compiler install isn't quite there.

Neither of them should make any difference to the program above. First, ensure that you've got it set as a Win32 Console executable and then make sure you don't have any resource (.rc) files around.

at first i copied a tutorial sample

Where did you copy the code ? (what source code ?)

When you start Visual Studio 2008, you did create a project ? what kind ? or did you simply created a new file and hope be be able to compile it ?

I suggest create a new Console (Win32 Console Application) project and paste the code in the auto-magically created "main" (probably called _tmain) of the project.

I just tried it and it work (at least compile and link).

Max.

I had the same problem last night with an old version of Visual Studio. I found that there is a known bug in AVG anti-virus that quarantines the rc.exe file.

In my case, after I had switched to a different anti-virus, I also installed another version of Visual Studio. Within that installation's files, I found the RC.exe file and pasted it into the file structure for the installation that was throwing the error. My code compiled and ran correctly after that.

Here is the path where I pasted rc.exe( I was using Visual C++ in VS 2003): C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\bin

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top