home *** CD-ROM | disk | FTP | other *** search
/ C!T ROM 21 / CTROM21B.mdf / win95 / utility / wb99g32i / filemenu.mn_ < prev    next >
Text File  |  1999-04-22  |  21KB  |  463 lines

  1.           editor="winbatch studio.exe"    ;Default editor
  2.           ; Common menu for all file types
  3.           ;First figure out where filemenu.dll is installed via registry lookup
  4.           ErrorMode(@OFF)
  5.           wbdir=RegQueryValue(@REGMACHINE,"SOFTWARE\Wilson WindowWare\WinBatch\CurrentVersion")
  6.           if wbdir==0 
  7.              wbdir=RegQueryValue(@REGMACHINE,"SOFTWARE\Wilson WindowWare\WinBatch Compiler\CurrentVersion")
  8.           endif
  9.           ErrorMode(@CANCEL)
  10.           if wbdir==0 then Display(5,"Error","Registry entries missing.  Re-install WinBatch")
  11.           homedir=strcat(wbdir,"system\")
  12.  
  13.           inifile=strcat(DirWindows(0),"FileMenu.ini")
  14.           if !FileExist(inifile) then inifile=strcat(homedir,"FileMenu.ini")
  15.           commonmenu="FileMenu for all filetypes.mnw"
  16.           defaultmenu="FileMenu for misc filetypes.mnw"
  17.           menudir=IniReadPvt("FileMenu","MenuDir",homedir,inifile)
  18.           if Strsub(menudir,strlen(menudir),1)!="\" then menudir=StrCat(menudir,"\")
  19.  
  20. Two Explorers, side by side ; Your dual window file manager
  21.         a=IntControl(31,0,0,0,0)  ;return list of ids of explorer windows
  22.         c=ItemCount(a,@TAB)
  23.         switch c
  24.            case 0
  25.               run("explorer.exe",strcat("/n,/e,",DirGet()))
  26.               while FindWindow("ExploreWClass")==""    ;wait for it to come up
  27.                 Yield
  28.               end while
  29.               ;Fall into case 1
  30.  
  31.            case 1
  32.               TimeDelay(0.5)
  33.               run("explorer.exe",strcat("/n,/e,",DirGet()))
  34.               break
  35.            case c       ; 2 or more
  36.               break
  37.         endswitch
  38.         d=1
  39.         while c<2 && d<500
  40.            a=IntControl(31,0,0,0,0)
  41.            c=ItemCount(a,@TAB)
  42.            d=d+1
  43.         endwhile
  44.         if c<2 then exit
  45.         id1=ItemExtract(1,a,@TAB)
  46.         id2=ItemExtract(2,a,@tab)
  47.         WinPlaceSet(@NORMAL,id2,"500 0 1000 900")
  48.         WinShow(id2)
  49.         Yield
  50.         Yield
  51.         WinPlaceSet(@NORMAL,id1,"0 0 500 900")
  52.         WinShow(id1)
  53.      
  54. Open With ... ; Choose an application to view or edit the selected file.
  55.  
  56.  &Browser (binary file viewer)  ; View any file in binary format.
  57.         file = CurrFilePath()
  58.         If !(FileExist(file)) Then file = ""
  59.         Else If FileExtension(file) == "" Then file = StrCat(file, ".")
  60.         Run("browser.exe", FileNameShort(file))     
  61.  &Notepad  ; Modify small plain text files.
  62.         file = CurrFilePath()
  63.         If !(FileExist(file)) Then file = ""
  64.         Else If FileExtension(file) == "" Then file = StrCat(file, ".")
  65.         Run("notepad.exe", file)
  66.  &MSPaint (bitmap) ; View and Modify bitmaps
  67.          file = CurrFilePath()
  68.          If !(FileExist(file)) Then file = ""
  69.               Else If FileExtension(file) == "" Then file = StrCat(file, ".")
  70.          bmpfile = strlower(FileExtension(file))
  71.          If bmpfile != "bmp" && bmpfile!="jpg" && bmpfile!="gif" && bmpfile!="jpeg"
  72.               Message("Error","Select a bmp, gif or jpg file and try again.")
  73.               Exit
  74.          EndIf          
  75.          rkey=RegOpenKey(@REGMACHINE,"SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths")
  76.          mspaintexe=RegQueryValue(rkey,"MSPAINT.EXE")
  77.          RegCloseKey(rkey)
  78.          Run(mspaintexe,strcat('"',file,'"'))
  79.  &Wordpad (text and graphics) ; Modify WORD, RTF, plain text files. Can contain bitmaps, too.
  80.          file = CurrFilePath()
  81.          If !(FileExist(file)) Then file = ""
  82.               Else If FileExtension(file) == "" Then file = StrCat(file, ".")
  83.          rkey=RegOpenKey(@REGMACHINE,"SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths")
  84.          wordpadexe=RegQueryValue(rkey,"WORDPAD.EXE")
  85.          RegCloseKey(rkey)
  86.          Run(wordpadexe,'"%file%"')
  87.  WinBatch &Studio (text) ; Open file with WinBatch Studio
  88.         f = CurrFilePath()
  89.         If !(FileExist(f)) Then f = ""
  90.         Else If FileExtension(f) == "" Then f = StrCat(f, ".")
  91.         f=strcat('"',f,'"')
  92.         Run(editor,f)
  93.  
  94.      
  95. File Operations
  96.  
  97.  File/Folder size    ;Sum sizes of all highlighted files and folders
  98.         
  99.         tot = FileSize(FileItemize(""))
  100.         sub1 = DirItemize("")
  101.         totdir=0
  102.         level=1
  103.         dir1=DirGet()
  104.         
  105.         numdir1 = ItemCount(sub1, @tab)
  106.         index1 = 0
  107.   
  108.         :dsloop
  109.         If index%level% == numdir%level% Then Goto upalevel
  110.         index%level% = index%level% + 1
  111.         DirChange(StrCat(dir%level%, ItemExtract(index%level%, sub%level%, @tab)))
  112.         
  113.         totdir=totdir+1
  114.         tot = tot + FileSize(FileItemize("*.*"))
  115.         level = level + 1
  116.         dir%level% = DirGet()
  117.         sub%level% = DirItemize("*.*")
  118.         numdir%level% = ItemCount(sub%level%, @tab)
  119.         index%level% = 0
  120.         goto dsloop
  121.   
  122.         :upalevel
  123.         drop(dir%level%,sub%level%,index%level%,numdir%level%)
  124.         level=level-1
  125.         if level!=0 then goto dsloop
  126.  
  127.         ; -----------
  128.         ; Termination
  129.         ; -----------
  130.         
  131.         If StrLen(tot) < 9 Then tot = StrCat(StrFill("", 9 - StrLen(tot)), tot)
  132.         tot = StrCat(StrSub(tot,1,3),",",StrSub(tot,4,3),",",StrSub(tot,7,3))
  133.         tot = StrTrim(tot)
  134.         If StrSub(tot, 1, 1) == "," Then tot = StrSub(tot, 2, StrLen(tot) - 1)
  135.         tot = StrTrim(tot)
  136.         If StrSub(tot, 1, 1) == "," Then tot = StrSub(tot, 2, StrLen(tot) - 1)
  137.         tot = StrTrim(tot)
  138.         Message("%totdir% Subdirectories included", "Total size %tot% bytes.")
  139.  
  140.  Print (with Notepad)   ;Print text-type file with notepad on default printer
  141.         Run("notepad.exe",strcat("/p ",CurrFilePath())
  142.  Associate              ;Associate this type of file with an application
  143.         a=strlower(FileExtension(CurrentFile()))
  144.         Terminate((a=="exe"||a=="com"||a=="bat"||a=="pif"||a=="lnk"),"Ooops","Cannot associate executable files")
  145.         b=AskFileName("Associate %a% files with","C:\","Executable Files|*.exe;*.com;*.bat;*.pif|All Files|*.*|","",1)
  146.     
  147.         rkey=RegOpenKey(@REGCLASSES,"")
  148.         ErrorMode(@OFF)
  149.         RegDeleteKey(rkey,".%a%")
  150.         ErrorMode(@CANCEL)
  151.         RegSetValue(rkey, ".%a%", "%a%_auto_file")
  152.         RegSetValue(rkey,"%a%_auto_file\shell\open\command",strcat('"',b,'" "%%1"'))
  153.         AU=StrUpper(a)
  154.         RegSetValue(rkey,"%a%_auto_file","%AU% File")
  155.         RegClosekey(rkey)
  156.  File Attributes        ;View file attributes
  157.         files = FileItemize("")
  158.         numfiles = ItemCount(files,@TAB)
  159.         While numfiles == 1
  160.         file = CurrentFile()
  161.         result = FileAttrGet(file)
  162.         If StrLen(file) > 30
  163.              fileindialog = StrSub(file,1,30)
  164.           
  165.              fileindialog = StrCat(fileindialog," ...")
  166.         Else 
  167.              fileindialog = file
  168.         EndIf
  169.      
  170.         readonly = 2
  171.         archive = 2
  172.         system = 2
  173.         hidden = 2
  174.         If StrSub(result,1,1) == "R" Then readonly = "3"
  175.         If StrSub(result,2,1) == "A" Then archive = "3"
  176.         If StrSub(result,3,1) == "S" Then system = "3"
  177.         If StrSub(result,4,1) == "H" Then hidden = "3"
  178.  
  179.                FileAttributesFormat=`WWWDLGED,5.0`
  180.                
  181.                FileAttributesCaption=`File Attributes`
  182.                FileAttributesX=7
  183.                FileAttributesY=25
  184.                FileAttributesWidth=199
  185.                FileAttributesHeight=101
  186.                FileAttributesNumControls=17
  187.                
  188.                FileAttributes01=`110,86,36,DEFAULT,PUSHBUTTON,DEFAULT,"&Cancel",0`
  189.                FileAttributes02=`42,18,38,DEFAULT,STATICTEXT,DEFAULT,"Read Only"`
  190.                FileAttributes03=`126,18,36,DEFAULT,STATICTEXT,DEFAULT,"System"`
  191.                FileAttributes04=`84,18,36,DEFAULT,STATICTEXT,DEFAULT,"Archive"`
  192.                FileAttributes05=`168,18,36,DEFAULT,STATICTEXT,DEFAULT,"Hidden"`
  193.                FileAttributes06=`56,86,36,DEFAULT,PUSHBUTTON,DEFAULT,"&OK",1`
  194.                FileAttributes07=`2,54,36,DEFAULT,STATICTEXT,DEFAULT,"On"`
  195.                FileAttributes08=`2,36,36,DEFAULT,STATICTEXT,DEFAULT,"Off"`
  196.                FileAttributes09=`2,4,194,DEFAULT,STATICTEXT,DEFAULT,"Set File Attributes for => %fileindialog% "`
  197.                FileAttributes10=`42,36,36,DEFAULT,RADIOBUTTON,readonly,"",2`
  198.                FileAttributes11=`42,54,36,DEFAULT,RADIOBUTTON,readonly,"",3`
  199.                FileAttributes12=`166,54,36,DEFAULT,RADIOBUTTON,hidden,"",3`
  200.                FileAttributes13=`84,36,36,DEFAULT,RADIOBUTTON,archive,"",2`
  201.                FileAttributes14=`84,54,36,DEFAULT,RADIOBUTTON,archive,"",3`
  202.                FileAttributes15=`166,36,36,DEFAULT,RADIOBUTTON,hidden,"",2`
  203.                FileAttributes16=`126,36,36,DEFAULT,RADIOBUTTON,system,"",2`
  204.                FileAttributes17=`126,54,36,DEFAULT,RADIOBUTTON,system,"",3`
  205.                
  206.                ButtonPushed=Dialog("FileAttributes")
  207.  
  208.  
  209.  
  210.            Select buttonpushed
  211.           
  212.                Case 0
  213.                     Break
  214.                     
  215.                Case 1
  216.  
  217.                     first = ""
  218.                     second = ""
  219.                     third = ""
  220.                     fourth = ""
  221.                     If readonly == 2 Then first = "r"
  222.                     If archive == 2 Then second = "a"
  223.                     If system == 2 Then third = "s"
  224.                     If hidden == 2 Then fourth = "h"
  225.                     If readonly == 3 Then first = "R"
  226.                     If archive == 3 Then second = "A"
  227.                     If system == 3 Then third = "S"
  228.                     If hidden == 3 Then fourth = "H"
  229.  
  230.                     
  231.                     
  232.                     
  233.                     attributes = StrCat( first, second, third, fourth )
  234.                     FileAttrSet(file, attributes)
  235.                     break
  236.            End Select
  237.                 
  238.  
  239.      Exit
  240.      EndWhile
  241.  
  242.      ;Set Attributes: Selected Files
  243.  
  244.      displayfiles = files
  245.      readonly = 1
  246.      archive = 1
  247.      system = 1
  248.      hidden = 1
  249.                AttribFormat=`WWWDLGED,5.0`
  250.                
  251.                AttribCaption=`Attributes`
  252.                AttribX=6
  253.                AttribY=25
  254.                AttribWidth=201
  255.                AttribHeight=101
  256.                AttribNumControls=22
  257.                
  258.                Attrib01=`110,86,36,DEFAULT,PUSHBUTTON,DEFAULT,"&Cancel",0`
  259.                Attrib02=`42,18,38,DEFAULT,STATICTEXT,DEFAULT,"Read Only"`
  260.                Attrib03=`126,18,36,DEFAULT,STATICTEXT,DEFAULT,"System"`
  261.                Attrib04=`84,18,36,DEFAULT,STATICTEXT,DEFAULT,"Archive"`
  262.                Attrib05=`168,18,36,DEFAULT,STATICTEXT,DEFAULT,"Hidden"`
  263.                Attrib06=`2,34,38,DEFAULT,STATICTEXT,DEFAULT,"No Change"`
  264.                Attrib07=`2,70,36,DEFAULT,STATICTEXT,DEFAULT,"On"`
  265.                Attrib08=`2,52,36,DEFAULT,STATICTEXT,DEFAULT,"Off"`
  266.                Attrib09=`42,34,36,DEFAULT,RADIOBUTTON,readonly,"",1`
  267.                Attrib10=`42,52,36,DEFAULT,RADIOBUTTON,readonly,"",2`
  268.                Attrib11=`42,70,36,DEFAULT,RADIOBUTTON,readonly,"",3`
  269.                Attrib12=`84,34,36,DEFAULT,RADIOBUTTON,archive,"",1`
  270.                Attrib13=`84,52,36,DEFAULT,RADIOBUTTON,archive,"",2`
  271.                Attrib14=`84,70,36,DEFAULT,RADIOBUTTON,archive,"",3`
  272.                Attrib15=`126,34,36,DEFAULT,RADIOBUTTON,system,"",1`
  273.                Attrib16=`126,52,36,DEFAULT,RADIOBUTTON,system,"",2`
  274.                Attrib17=`126,70,36,DEFAULT,RADIOBUTTON,system,"",3`
  275.                Attrib18=`168,34,36,DEFAULT,RADIOBUTTON,hidden,"",1`
  276.                Attrib19=`168,52,36,DEFAULT,RADIOBUTTON,hidden,"",2`
  277.                Attrib20=`168,70,36,DEFAULT,RADIOBUTTON,hidden,"",3`
  278.                Attrib21=`58,2,130,DEFAULT,STATICTEXT,DEFAULT,"Set Attributes for Selected Files"`
  279.                Attrib22=`56,86,36,DEFAULT,PUSHBUTTON,DEFAULT,"&OK",1`
  280.                
  281.                ButtonPushed=Dialog("Attrib")
  282.                
  283.  
  284.  
  285.  
  286.           Select buttonpushed
  287.           
  288.                Case 0
  289.                     Break
  290.                     
  291.                Case 1
  292.  
  293.                     first = ""
  294.                     second = ""
  295.                     third = ""
  296.                     fourth = ""
  297.                     If readonly == 2 Then first = "r"
  298.                     If archive == 2 Then second = "a"
  299.                     If system == 2 Then third = "s"
  300.                     If hidden == 2 Then fourth = "h"
  301.                     If readonly == 3 Then first = "R"
  302.                     If archive == 3 Then second = "A"
  303.                     If system == 3 Then third = "S"
  304.                     If hidden == 3 Then fourth = "H"
  305.  
  306.                     
  307.                     
  308.                     
  309.                     attributes = StrCat( first, second, third, fourth )
  310.                     FileAttrSet(files, attributes)
  311.                     break
  312.            End Select
  313.       Exit                              
  314.  
  315.  
  316.  DOS &Copy  ; Like the good, old, DOS COPY command.
  317.        s = StrTrim(FileItemize(""))
  318.        s=StrReplace(s,@tab,"|")
  319.        If s == "" Then Message("Copy Error", "No files selected")
  320.        Then Exit
  321.        If ItemCount(s, "|") == 1 Then t = s
  322.        Else t = ""
  323.        t = AskLine("Copy", StrCat(s, @CRLF, @CRLF, "to"), t)
  324.        If t == "" Then Message("Copy Error", "Cannot copy to null file name")
  325.                Then Exit
  326.        FileCopy(s, t, @TRUE)
  327.  
  328.  DOS &Rename  ;Like the good, old DOS RENAME command.
  329.        s = StrTrim(FileItemize(""))
  330.        s=StrReplace(s,@tab,"|")
  331.        If s == "" Then Message("Rename Error", "No files selected")
  332.        Then Exit
  333.        If ItemCount(s, "|") == 1 Then t = s
  334.        Else t = ""
  335.        t = AskLine("Rename", StrCat(s, @CRLF, @CRLF, "to"), t)
  336.        If t == "" Then Message("Rename Error", "Cannot rename to null file name")
  337.                   Then Exit
  338.        FileRename(s, t)
  339.  
  340.   
  341. Clipboard Tricks ; Copies just the filenames to the clipboard
  342.  FileName(s) to Clipboard ; Just the filenames
  343.         a=FileItemize("")
  344.         a=ItemSort(a,@tab)
  345.         a=strreplace(a,@TAB,@CRLF)
  346.         ClipPut(a)
  347.         Display(2,"Filenames placed on Clipboard",a)
  348.  Path and FileName(s) to Clipboard ; Copies filenames with full paths to the Clipboard
  349.         a=FileItemize("")
  350.         a=ItemSortNC(a,@TAB)
  351.         a=strcat(@TAB,a)
  352.         b=DirGet()
  353.         a=StrSub(StrReplace(a,@TAB,strcat(@TAB,b)),2,-1)
  354.         a=StrReplace(a,@TAB,@CRLF)
  355.         ClipPut(a)
  356.         Display(2,"Full path filenames placed on Clipboard",a)
  357.  Path to Clipboard   ; Copies just the path to the clipboard
  358.         a=DirGet()
  359.         ClipPut(a)
  360.         Display(2,"Path placed on Clipboard",a)
  361.         
  362.         
  363.  _Run Clipboard Viewer   ; Lets you see what is on the clipboard
  364.         Run("clipbrd.exe","")
  365.  
  366.  
  367. WIL Interactive
  368.  Execute a function
  369.         call("%homedir%wwwmenu95.wil","CMDSTACK NEWCMD")
  370.  _Load WIL Help File
  371.         WinHelp(strcat(wbdir,"Windows Interface Language.hlp"),"CONTENTS","")     
  372.       
  373.  
  374.  
  375.      
  376. _Edit File Menus ; Modify WinBatch FileMenus here 
  377.  Edit menu for this filetype  ; Edit menus for files with a specific file extension.
  378.         b=strupper(FileExtension(CurrentFile()))
  379.         a=IniReadPvt("Menus",b,"*NONE*",inifile)
  380.         c=a
  381.         if c=="*NONE*" then a=strcat("FileMenu for %b% files",".mnw")
  382.         if FilePath(a)=="" then a=strcat(menudir,a)
  383.         ;Message(a,FileExist(a))
  384.         if  FileExist(a)
  385.                 if c=="*NONE*"
  386.                    iniwritepvt("Menus",b,a,inifile)
  387.                    Display(7,"%b% was missing from %inifile%","Adding menu file back in now")
  388.                 endif
  389.         else
  390.                 c=AskYesNo("Please note:","The menu file for the %b% filetype does not exist.  Would you like to start a new one?")
  391.                 if c==@NO then exit
  392.                 c=               "; WinBatch FileMenu for %b% filetype%@CRLF%"
  393.                 c=strcat(c,@CRLF,"; This is a sample menu file to help you get started")
  394.                 c=strcat(c,@CRLF,"; writing your very own Winbatch FileMenu menus.  It is")
  395.                 c=strcat(c,@CRLF,"; really not too bad.  WinBatch is a simple programming")
  396.                 c=strcat(c,@CRLF,"; language.  You can find out just about all you need to")
  397.                 c=strcat(c,@CRLF,"; know from the Windows Interface Language help file or")
  398.                 c=strcat(c,@CRLF,"; the manual.  Check out the section on Menu Files,")
  399.                 c=strcat(c,@CRLF,"; the WIL Tutorial and the WIL Function Reference.")
  400.  
  401.                 c=strcat(c,@CRLF,@CRLF,'Standalone menu item            ; Sample menu item')
  402.                 c=strcat(c,@CRLF,      '        Message("Hello","There")')
  403.                 c=strcat(c,@CRLF,@CRLF,'Top Level menu item')
  404.                 c=strcat(c,@CRLF,      ' Selected File is               ; Shows currently selected file')
  405.                 c=strcat(c,@CRLF,      '        a=CurrFilePath()')
  406.                 c=strcat(c,@CRLF,      '        Message("Selected File is",a)')
  407.                 c=strcat(c,@CRLF,      ' Run Calculator                 ; Sample Run function')
  408.                 c=strcat(c,@CRLF,      '        Run("calc.exe","")')
  409.                 c=strcat(c,@CRLF,      ' Run Notepad on selected file   ; Sample Run function with filename')
  410.                 c=strcat(c,@CRLF,      '        a=CurrFilePath()')
  411.                 c=strcat(c,@CRLF,      '        Run("notepad.exe",a)')
  412.  
  413.                 c=strcat(c,@CRLF,@CRLF,'; Note: You may want to delete this menu item if you edit this file')
  414.                 c=strcat(c,@CRLF,      ' _Delete this sample menu file  ; Deletes this menu file')
  415.                 c=strcat(c,@CRLF,      '        ErrorMode(@OFF)')
  416.                 c=strcat(c,@CRLF,      '        wbdir=RegQueryValue(@REGMACHINE,"SOFTWARE\Wilson WindowWare\WinBatch\CurrentVersion")')
  417.                 c=strcat(c,@CRLF,      '        if wbdir==0')
  418.                 c=strcat(c,@CRLF,      '           wbdir=RegQueryValue(@REGMACHINE,"SOFTWARE\Wilson WindowWare\WinBatch Compiler\CurrentVersion")')
  419.                 c=strcat(c,@CRLF,      '        endif')
  420.                 c=strcat(c,@CRLF,      '        ErrorMode(@CANCEL)')
  421.                 c=strcat(c,@CRLF,      '        if wbdir==0 then Display(5,"Error","Registry entries missing.  Re-install WinBatch")')
  422.                 c=strcat(c,@CRLF,      '        homedir=strcat(wbdir,"system\")')
  423.                 c=strcat(c,@CRLF,      '        inifile=strcat(DirWindows(0),"FileMenu.ini")')
  424.                 c=strcat(c,@CRLF,      '        if !FileExist(inifile) then inifile=strcat(homedir,"FileMenu.ini")')
  425.                 c=strcat(c,@CRLF,      '        menudir=IniReadPvt("FileMenu","MenuDir",homedir,inifile)')
  426.                 c=strcat(c,@CRLF,      '        if StrSub(menudir,strlen(menudir),1)!="\" then menudir=StrCat(menudir,"\")')
  427.                 c=strcat(c,@CRLF,      '        b=strupper(FileExtension(CurrentFile()))')
  428.                 c=strcat(c,@CRLF,      '        a=IniReadPvt("Menus",b,"*NONE*",inifile)')
  429.                 c=strcat(c,@CRLF,      '        if a=="*NONE*" then a=strcat("Files%b%",".mnw")')
  430.                 c=strcat(c,@CRLF,      '        if FilePath(a)=="" then a=strcat(menudir,a)')
  431.                 c=strcat(c,@CRLF,      '        c=AskYesNo("Are you sure you wish to delete this menu file",a)')
  432.                 c=strcat(c,@CRLF,      '        if c==@YES')
  433.                 c=strcat(c,@CRLF,      '           IniDeletePvt("Menus",b,inifile)')
  434.                 c=strcat(c,@CRLF,      '           FileDelete(a)')
  435.                 c=strcat(c,@CRLF,      '        endif')
  436.  
  437.  
  438.  
  439.  
  440.                 c=strcat(c,@CRLF)
  441.                 fh=FileOpen(a,"WRITE")
  442.                 FileWrite(fh,c)
  443.                 FileClose(fh)
  444.                 iniwritepvt("Menus",b,a,inifile)
  445.                 drop(c)
  446.                 
  447.         endif
  448.         Run(Editor,'"%a%"')
  449.  ;Edit the Miscellaneous File Menu     ; Edit menus for files with unrecognized extensions
  450.  ;       a=IniReadPvt("FileMenu","DefaultMenu",defaultmenu,inifile)
  451.  ;       if FilePath(a)=="" then a=strcat(menudir,a)
  452.  ;       Run(Editor,'"%a%"')
  453.  Edit menu for all filetypes      ; Edit global menu for all files 
  454.         a=IniReadPvt("FileMenu","CommonMenu",commonmenu,inifile)
  455.         if FilePath(a)=="" then a=strcat(menudir,a)
  456.         Run(Editor,'"%a%"') 
  457.  _Load WIL Help File
  458.         WinHelp(strcat(wbdir,"Windows Interface Language.hlp"),"CONTENTS","")     
  459.  
  460.  _About WinBatch FileMenu  ; Software from Wilson WindowWare
  461.         About()           
  462.            
  463.