problem with a new project

problem with a new project

Bild des Benutzers diana g.

Hi, I'm new in Visual Studio 2012 and I have to write a program in Visual Fortran. I installed everything and when I want to compile a simply hello world program what I have to do? I open a new project call "hello", and a new fortran file, then I write my hello.f90 program

program hello
    implicit none
    character(15) string_out
    character(40) string_title
    string_out='Hello world!'
    string_title='Simple hello world using quickwin'
    open(unit=4,file='user',title=strig_title)
    write(4,'(10x,A15)')string_out
    end program hello

and when I click on the start button a message tell me: impossible start the program, don't find hello.exe.

what I forgot to do?

9 Beiträge / 0 neu
Letzter Beitrag
Nähere Informationen zur Compiler-Optimierung finden Sie in unserem Optimierungshinweis.
Bild des Benutzers Steve Lionel (Intel)

Select Build > Build Solution.  Then you can run - if the build was successful. There is a setting in Visual Studio to automatically build if the project is "out of date" - you could turn that on if you wanted. Tools > Options > Projects and Solutions > Build and Run > On Run, when projects are out of date.

Make sure you have selected the correct project type (Fortran > Console Application or Fortran > QuickWin Application > QuickWin Application.

Steve
Bild des Benutzers Sergey Kostrov

I tried your codes and there are two problems with the example:

- There are two compilation errors:

..\Main.f90(8): error #6404: This name does not have a type, and must have an explicit type. [STRIG_TITLE]
..\Main.f90(8): error #6054: A CHARACTER data type is required in this context. [TITLE]

- If it is fixed than there is some run-time error when open(unit=4,file='user',title=string_title) is executed

Please take a look at [InstallDir]\Composer XE 2013\Samples\en_US\Fortran for more QuickWin samples. Attached is a small Fortran project ( VS 2008 Professional Edition ) and it is a really small QuickWin based application.

Anlagen: 

AnhangGröße
Herunterladen qwintestapp.zip13.33 KB
Bild des Benutzers Sergey Kostrov

Here is a screenshot:

Anlagen: 

AnhangGröße
Herunterladen qwintestapp.jpg18.62 KB
Bild des Benutzers iliyapolak

@Sergey

Sorry for off topic question.Did you decide to learn programming in fortran?

Bild des Benutzers Sergey Kostrov

Steve,

I've noticed that Visual Studio Wizard doesn't add any source files to a newly created QuickWin project. For example, the project is created, it is properly configured but a developer should add a source file etc. As a feature request I would suggest to review these two Visual Studio Wizards for QuickWin projects and source files with codes for a minimal QuickWin application could be added.

Bild des Benutzers diana g.

Thank you both, I didn't understand to add a source file in my QuickWin application! There aren't so many good guide to learn from the beginning, and guides exist only in english!

Bild des Benutzers Sergey Kostrov

Please use qwintestapp.zip I've attached ( for Visual Studio 2008 Professional Edition ) and this is a very small QuickWin application.

Bild des Benutzers diana g.

Done, thank you

Melden Sie sich an, um einen Kommentar zu hinterlassen.