Page 173 - DCAP408_WEB_PROGRAMMING
P. 173

Unit 10: Menus




                                                                                                Notes


              Task  Illustrate the use of LoadResData function.
          Self Assessment


          Fill in the blanks:
          7.   Each  resource in  the resource file is identified  to  VB  6  by an  Id  and a  name in  the
               ..........................
          8.   Use the VB  predefined constants  vbResBitmap for  bitmaps, vbResIcon for icons, and
               vbResCursor for cursors for the “.........................” parameter.

          9.   To make a resource available to your program, you add them in the Resource Editor then
               use the Id and the resource “.........................” to point to them in your program.
          10.  When you add a resource, the actual file itself is ......................... into your project.

          10.3 Creating a Menu using the Borland Resource Workshop


          Traditional Windows development suggests that you add version information to your compiled
          .EXE files. Microsoft provides two  tools with Microsoft Visual  C++ that  allow Visual  C++
          programmers to add version information to compiled applications.

              The Microsoft Resource Compiler (RC.EXE).
              The Microsoft App Studio, a resource editor.
          Unfortunately, at this time, Visual Basic programmers cannot add version information to Visual
          Basic generated .EXE files. Visual Basic does not have the ability to add resource information to
          its .EXE files. Nor can you use either the Microsoft Resource Compiler or the App Studio to add
          resource information to .EXE files generated by Visual Basic.




             Notes  There are however other third party Resource Compilers/Editors that will work
             with Visual Basic compiled .EXE files. One such tool  is the “Resource Workshop” by
             Borland. You can contact Borland at 1-800-336-6464x8708.

          Below is a step by step example illustrating how to add version information to a Visual Basic
          compiled EXE using Borland’s “Resource Workshop.”


                 Example: Example of Adding Version Information to a VB Application
          1.   Start Resource Workshop.
          2.   From the Resource Menu, choose New (ALT+R N).

          3.   Select VERSIONINFO as the resource type, and click OK.
          4.   Resource  Workshop displays a default script for version information. Delete this, and
               type in something similar to the following:

                1  VERSIONINFO  LOADONCALL  MOVEABLE  FILEVERSION  1,  0,  0,
                5  PRODUCTVERSION  1,  0,  0,  10  FILEOS  VOS__WINDOWS16  FILETYPE




                                           LOVELY PROFESSIONAL UNIVERSITY                                   167
   168   169   170   171   172   173   174   175   176   177   178