Converting a .RC to a .RES

Using the IDE

Firstly, ensure that the PowerBASIC IDE's OPTIONS dialog is configured to correctly point to the RC.EXE and PBRES.EXE files.  Once configured, the IDE can automatically compile a .RC into a .RES file, and then produce a .PBR file from the .RES file.  This is achieved in one simple step: simply load the .RC file into the IDE and select Compile.

Using the command-line Resource Compiler

To compile the .RC file, we need to run the Resource Compiler from a DOS box (command-line) to create the binary (.RES) resource file.

The resource compiler takes the filename of your modified (.RC) resource script file as a parameter, and produces a new 32-bit .RES file.  For example:

C:\PB\BIN\RC.EXE MYAPP.RC

Note that you may need to change the path name to suit your individual settings.  At this point, you should have a compiled binary resource file (i.e., MYAPP.RES), ready to be converted to PowerBASIC's .PBR format.

Tip: If you use the Microsoft Dialog Editor and you  do not rename your .RC file, the resultant .RES file will overwrite the .RES file created with the Microsoft Dialog Editor.  This will make it impossible to reopen the original dialog file in DLGEDIT.  Be sure to rename either the .RC file or the original .RES file before compilation with RC.EXE!

 

 

See Also

What is a Resource File?

Resource Editors

Resource Compiling

Resource Scripts

Converting a .DLG to a .RC  

Converting a .RES to a .PBR