MODIFY MEMO Command

Opens an editing window for a Memo field or Blob field in the current record.

You can view or change the contents of the Memo field; however, the Blob field displays in the editing window as read-only.

MODIFY MEMO MemoField1 [, MemoField2 ...] [NOEDIT] [NOMENU]
   [NOWAIT] [RANGE nStartCharacter, nEndCharacter] 
   [[WINDOW WindowName1] [IN [WINDOW] WindowName2 | IN SCREEN]]
   [SAME] [SAVE]

Parameters

  • MemoField1 [, MemoField2 ...]
    Specifies the names of one or more Memo fields to edit.

    Tip

    To open an editing window for a Memo field in a table open in another work area, include the table alias with the field name.

  • NOEDIT
    Specifies that the opened Memo field cannot be changed; instead, it can be viewed and copied to the Clipboard.
  • NOMENU
    Hides the Format menu on the Visual FoxPro system menu bar to prevent formatting changes to the Memo field.
  • NOWAIT
    Continues execution of the program opening the editing window.

    Note

    NOWAIT applies only when used in a Visual FoxPro program (.prg). It has no effect when executing MODIFY MEMO in the Command window.

    The program does not wait for the editing window to close but continues execution on the program line immediately following the line containing MODIFY MEMO NOWAIT.

    If you omit NOWAIT, an editing window opens and program execution pauses until the editing window closes.

  • RANGE nStartCharacter, nEndCharacter
    Specifies a range of characters to appear selected when the editing window opens.

    Starting at the position specified with nStartCharacter, characters are selected up to but not including the character position of nEndCharacter. If nStartCharacter is equal to nEndCharacter, no characters are selected, and the cursor is placed at the position specified with nStartCharacter.

  • WINDOW WindowName1
    Specifies a window whose characteristics that the editing window uses.

    For example, if the window is created with the FLOAT option of the DEFINE WINDOW command, the editing window can be moved. The window specified must only be defined; it does not need to be active or visible.

  • IN [WINDOW] WindowName2
    Specifies a parent window in which to open the editing window.

    Note

    The parent window must first be defined with the DEFINE WINDOW command and must be visible in order to access the editing window.

    The editing window does not assume the characteristics of the parent window and cannot be moved outside the parent window. If the parent window is moved, the editing window moves with it.

  • IN SCREEN
    Opens the editing window explicitly in the main Visual FoxPro window, after placing the editing window in a parent window. You can place an editing window in a parent window by including the IN WINDOW clause.
  • SAME
    Prevents the editing window from appearing as the active window in the foreground.

    If the editing window is hidden, it displays but does not become the active window.

  • SAVE
    Keeps the editing window open after activating another window. If you omit SAVE, the editing window closes when another window activates.

    Note

    Including SAVE has no effect when used in the Command window.

Remarks

In a table that is opened for shared access on a network, the current record is automatically locked when editing begins in one of its Memo fields.

Note

In distributed run-time applications, syntax coloring in Memo field editing windows is disabled. For more information, see How to: Display and Print Source Code in Color.

Example

The following example uses the Visual FoxPro sample database, TestData, and MODIFY MEMO with the NOEDIT and RANGE options to open a Memo field named Notes for the first record of the Employee table. The memo field opens in an editing window as read-only and displays the first 10 characters as selected.

CLOSE DATABASES
OPEN DATABASE (HOME(2) + 'data\testdata')
USE employee  && Opens Employee table
MODIFY MEMO Notes NOEDIT RANGE 1,10  

See Also

Reference

CLOSE MEMO Command
APPEND MEMO Command
COPY MEMO Command

Other Resources

Commands (Visual FoxPro)