Transfer Scratch Files to Your Scribble Project

AppWizard provides several source files for an OLE server application that you can use as-is in Scribble. The following procedures describe how to incorporate source files and code from the Scratch version of Scribble, which you created with the AppWizard full-server option, into the version of Scribble you’ve been developing step by step, and which did not initially include full-server support.

Suggested Reading

To add the new files to your Scribble project

  1. Copy the following files from Scratch\Scribble to your Scribble project root directory:

    These files provide “In Place” (IP) editing functionality for Scribble. Placing them in your project directory makes dependent files available to the project. When AppWizard generates Scribble.cpp with Full-server support, it adds OLE-specific code to the file.

  2. Start Visual C++, if necessary, and from the File menu, click Open Workspace.

  3. Navigate to your original version of Scribble and open Scribble.dsw.

    Click Yes when prompted to register this version of Scribble.

  4. From the Project menu, point to Add to Project and click Files into Project.

    The Insert Files into Project dialog box appears. By default, the dialog box points to your current project directory.

  5. Select the files IpFrame.cpp, IpFrame.h, ScribbleItem.cpp, and ScribbleItem.h, and click the OK button.

    You can now view the added files in FileView and their associated classes in ClassView.

  6. From FileView, open Scribble.hpj.

    Because you added the help source file, Afxolesv.rtf, to the project, you need to modify the help project file.

  7. In the [FILES] section of Scribble.hpj, type “AfxOleSv.rtf,” and save the file.

    Similar to the process for adding files to a project, you can’t just copy a help source (.RTF) file; you must add it to the Help project. Modifying the Help Project (.HPJ) file accomplishes this.