home *** CD-ROM | disk | FTP | other *** search
/ Piper's Pit BBS/FTP: ibm 0010 - 0019 / ibm0010-0019 / ibm0010.tar / ibm0010 / ME494-6.ZIP / UNLOCK.SRC < prev    next >
Encoding:
Text File  |  1990-04-06  |  1.1 KB  |  38 lines

  1. {*******************************MULTI-EDIT MACRO******************************
  2.  
  3. Name: Unlock
  4.  
  5. Description:  Unlocks MECONFIG.DB and MECOM.DB under circumstances where
  6.         these configuration files have somehow become locked.
  7.  
  8.                (C) Copyright 1989 by American Cybernetics, Inc.
  9. ******************************************************************************}
  10. $MACRO Unlock;
  11.     def_int(jx);
  12.     jx := window_id;
  13.     refresh := false;
  14.     rm('UserIn^SetConfig /DB=MECONFIG.DB');
  15.     IF return_int THEN
  16.         read_only := false;
  17.         cur_file_attr := (cur_file_attr AND $FFFE) OR (read_only <> 0);
  18.         save_file;
  19.         make_message('MECONFIG.DB unlocked.');
  20.     ELSE
  21.         make_message('MECONFIG.DB not loaded.');
  22.     END;
  23.     rm('UserIn^SetConfig /DB=MECOM.DB');
  24.     IF return_int THEN
  25.         read_only := false;
  26.         cur_file_attr := (cur_file_attr AND $FFFE) OR (read_only <> 0);
  27.         save_file;
  28.     END;
  29.     rm('UserIn^SetConfig /DB=KEYMAC.DB');
  30.     IF return_int THEN
  31.         read_only := false;
  32.         cur_file_attr := (cur_file_attr AND $FFFE) OR (read_only <> 0);
  33.         save_file;
  34.     END;
  35.     switch_win_id( jx );
  36.  
  37. END_MACRO;
  38.