Subj : Re: MPL To : GRYPHON From : IGNATIUS Date : Thu Jan 31 2019 07:20 pm Gr> I reworked it some. I noticed that there are no colord mci codes, where Gr> there obviously should be some. I'm thinking that they may have gotten Gr> stripped off since it was posted to the message area here. Gr> It still doesn't work as it should. Thank you for trying. Here is the source code that I used before reapern66 took a look at the code. -//---snip-------------------------------------------------------------------- Uses CFG; Uses USER; Var Line1 : String Line2 : String Line3 : String Line4 : String Line5 : String Line6 : String Line7 : String Line8 : String automessage : String Topic : String Date : String InStr : String Done : Boolean //automessage := CfgDataPath + 'automsg.dat' Var c1 : String; // Variables for the ColorScheme stuff: Colorscheme code t anks to Zoob c2 : String; // " " " " c3 : String; // " " " " p1 : String; // Variables for the DataField in the Menu Editor: p2 : String; // i.e. "Menu" and "" p1 := Upper(ParamStr(1)) // What the variables mean... This tells Mysti to p2 := Upper(ParamStr(2)) // look n the menu data field for the 1st & 2n words // Putting the Date the automessage was written to a temp file. If FileExist(Date); fOpen(1, Text, ReWrite, Date); fClose(1); End If //########################### //## Display Automesage ### //########################### Procedure Write_Automsg Begin GetThisUser If InputYN ('|CRsave this message? ') then // Said after Should_We has run fopen (1, Text, ReWrite, automessage) // Opens automessage.DAT fWriteLn (1, 'from : '+ UserAlias) // Writes the useralias to file fWriteLn (1, 'topic: '+ Topic) // Writes topic to file fWriteLn (1, 'date : '+ Date) // Writes date to file fWriteLn (1, '|CR') If Line1 <> '' FWriteLn (1, ' '+ Line1) End If // Displays 1st ine If Line2 <> '' FWriteLn (1, ' '+ Line2) End If // Displays 2nd line If Line3 <> '' FWriteLn (1, ' '+ Line3) End If // and 3rd If Line4 <> '' FWriteLn (1, ' '+ Line4) End If // what the hay, 4th t o If Line5 <> '' FWriteLn (1, ' '+ Line5) End If // you guessed it, 5th If Line6 <> '' FWriteLn (1, ' '+ Line6) End If // writes 8th line If Line7 <> '' FWriteLn (1, ' '+ Line7) End If // writes 7th line If Line8 <> '' FWriteLn (1, ' '+ Line8) End If // writes 6th line fClose (1) // Closes automessage.DAT End If End Done := False // Is menu finished or not? //########################## //## Write automessage ### //########################## Procedure Should_We // boy, that question was long, I write here for it. Would you like to write au omessage, question. If InputNY ('|CRchange automsg? ') Write ('|CRtopic: ') Topic := Input (60, 60, 1, '') // If Topic doesn't exist, write a new one /* If FileExist(Topic) fOpen(1, Text, ReWrite, Topic) fClose(1) // Close Topic file End If */ // Writing automessage now WriteLn ('|CRenter automsg now.. 8 lines max|CR') Write (': ') Line1 := Input (77, 77, 1, '') If Line1 = '' // If nothing entered on line1, abort Write_Automsg WriteLn('aborted!') Halt End If Write (': ') Line2 := Input (77, 77, 1, '') If Line2 = '' // If nothing entered on line2, save automessage? Write_Automsg Halt End If Write (': ') Line3 := Input (77, 77, 1, '') If Line3 = '' // If nothing entered on line3, save automessage? Write_Automsg Halt End If Write (': ') Line4 := Input (77, 77, 1, '') If Line4 = '' // If nothing entered on line4, save automessage? Write_Automsg Halt End If Write (': ') Line5 := Input (77, 77, 1, '') If Line5 = '' // Get the idea? Write_Automsg Halt End If Write (': ') Line6 := Input (77, 77, 1, '') If Line6 = '' // I'm done typing here Write_Automsg Halt End If Write (': ') Line7 := Input (77, 77, 1, '') If Line7 = '' Write_Automsg Halt End If Write (': ') Line8 := Input (77, 77, 1, '') Write_Automsg DispFile (automessage) End If End //######################### //## automessage Menu ### //######################### Procedure Make_Menu Repeat // Repeat this stuff until Done := True(until user presses "Q") WriteLn (' lQ-automessage v2.2') WriteLn ('') WriteLn ('{V} View automessage') WriteLn ('{W} Write automessage') WriteLn ('(R) Reply to Author of automessage') WriteLn ('') Write ('lQ-automessage [Q/Quit] ['+ StrRep(' ', 2)+ ')'+ StrRep(Chr(8), 3)) InStr := Input(2, 2, 12, '') // The Input area is 2 characters long If InStr = 'V' Then // If user presses "V" then it displays the autome sage DispFile (automessage) // Display file "automessage.DAT" ElseIf InStr = 'W' Then // If "W" then Write the automessage Should_We // Run Should_We procedure ElseIf InStr = 'R' Then // If "R" then reply to Author of automessage MenuCmd('MW', UserAlias) // Write to the author of automessage ElseIf InStr = 'Q' Then // Quiting the menu Done := True // Finally! End If Until Done End //########################### //## Color Scheme Codes ### //########################### Procedure Color_Me_Blind If p1='BLUE' // If 1st word in menu data entry c1 :='' c2 :='' c3 :='' // equals BLUE then display those colors ElseIf p1='GREEN' // Same as above, but for GREEN c1 :='' c2 :='' c3 :='' ElseIf p1='CYAN' // Same as above. c1 :='' c2 :='' c3 :='' ElseIf p1='RED' c1 :='' c2 :='' c3 :='' ElseIf p1='MAGENTA' c1 :='' c2 :='' c3 :='' ElseIf p1='YELLOW' c1 :='' c2 :='' c3 :='' ElseIf p1='GREY' c1 :='' c2 :='' c3 :='' ElseIf p2='BLUE' // Changed to if 2nd word in menudata ield c1 :='' c2 :='' c3 :='' // equals BLUE then display these codes ElseIf p2='GREEN' // Same as p2='BLUE' c1 :='' c2 :='' c3 :='' ElseIf p2='CYAN' // Same as the other p2=""'s c1 :='' c2 :='' c3 :='' ElseIf p2='RED' c1 :='' c2 :='' c3 :='' ElseIf p2='MAGENTA' c1 :='' c2 :='' c3 :='' ElseIf p2='YELLOW' c1 :='' c2 :='' c3 :='' ElseIf p2='GREY' c1 :='' c2 :='' c3 :='' Else // If no color entered then use these c1 :='' c2 :='' c3 :='' // Color Codes End If End If p1='MENU' // If 1st word in menudatafield equals this then display Make_Menu // the menu ElseIf p2='MENU' // If the 2nd word in menudatafield equals this then display Make_Menu // the menu. Just so you can have these things in any order( he menu and color) End If Date := DateStr(DateTime, 1) // Date equals this Color_Me_Blind // Run this procedure(the color scheme) DispFile(automessage) // Run this procedure(display automessage) Should_We // Run this procedure(change automessage?) -//---snip------------------------------------------------------------- Thank you so much. |09ignatius |07(|15cia|07/|15scrollz|07) --- Mystic BBS v1.10 A52 (Linux) * Origin: catch22bbs.com (46:1/124) þ Synchronet þ thePharcyde_ >> telnet://bbs.pharcyde.org (Wisconsin) .