Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

I cannot debug Fortran code

Chao_P_
初學者
1,999 檢視

I found several simple fortran code to test my fortran compiler. But every time I started debugging, there was a error window saying Unable to start program 'C:\users\CPU\documents\visual studio 2008\projects\console1\x64\debug\console1.exe'  The system cannot find the file specified.

I am using Intel Fortran 11.1 and visual studio 2008. I have tested Fortran with ranning a UMAT in abaqus, and it did work. But when I wanted to debug any fortran code in visual studio, it appears the above error message.

0 積分
12 回應
Steven_L_Intel1
1,999 檢視

This means that the executable does not exist. Did a build complete without errors? You need to build the application first. From the Visual Studio menu, select Build and then Build Solution. Then you should be able to debug. Make sure you set a breakpoint at a convenient place in the Fortran code before starting the execution.

Chao_P_
初學者
1,999 檢視

Hi Steve, 

I built solution, and it appears 0 succeeded, 0 failed , 1 up-to-date, 0 skipped. And then, I started debugging, but I had the same problem. I had such problem even when I ran such a simple code.

$ vim helloworld.f

program hello
print *,"Hello World!"
end program hello

Chao_P_
初學者
1,999 檢視

Hi Steve, 

I built solution, and it appears 0 succeeded, 0 failed , 1 up-to-date, 0 skipped. And then, I started debugging, but I had the same problem. I had such problem even when I ran such a simple code.

$ vim helloworld.f

program hello
print *,"Hello World!"
end program hello

Steven_L_Intel1
1,999 檢視
Chao_P_
初學者
1,999 檢視

I did as the what the link showed. But it still did not work. Why there wasn't executable file created? 

It drives me crazy.....

Steven_L_Intel1
1,999 檢視

Please create a ZIP of your project folder and attach it to a reply here.

Chao_P_
初學者
1,999 檢視

Here is a code. Thank you so much. Steve

Steven_L_Intel1
1,999 檢視

You have not added the source file to the project.

Chao_P_
初學者
1,999 檢視

What should I do?

Chao_P_
初學者
1,999 檢視

I think I figure it out. I added the source files manually. I thought it will be created automatically. How can I make it created automatically under  the source files document?

Steven_L_Intel1
1,999 檢視

Select Project > Add New Item... (or Add Existing Item...). You can also right click on a project and add new/existing items that way. Another option is to drag and drop a file from a folder onto the "Source Files" pseudo-folder in your project in Visual Studio.

Chao_P_
初學者
1,999 檢視

Thank you for your patience, Steve. You help me a lot.

回覆