Path: news.uiowa.edu!news.physics.uiowa.edu!math.ohio-state.edu!howland.reston.ans.net!newsxfer.itd.umich.edu!news.mathworks.com!nntp.primenet.com!ddsw1!news.mcs.net!not-for-mail From: bird@MCS.COM (J. L. Walters) Newsgroups: comp.sys.apple2 Subject: Re: Appleworks WP Question... Date: 24 Jul 1996 22:08:43 -0500 Organization: /usr/lib/news/organi[sz]ation Lines: 63 Message-ID: <4t6ofr$fbj@Mars.mcs.com> References: NNTP-Posting-Host: mars.mcs.com In article , Richard Der wrote: > >bard@smarty.smart.net (E.G. Land) wrote: >> Two Questions: >> >> >> Why is it my document loses its format whenever I save and >> retrieve? I'm guessing that you are using AW 5.1 and have loaded a text file. If so, then your preferences say to save a text file as a text file. (A good thing from my perspective.) The bad news is, when you save it the file is saved as a text file which loses all formatting. Put the folowing macro in your default macro set and call it before saving: Force file to be saved as an AWP file even if: "Save text as text" is specified in the Misc menu : < poke $7C68,0 : // Force file to be saved as AWP even // if save text as text files are set. bell : // Let user know we worked >! ================================================================ Another useful macro is: #savetext = ba-- Causes files to be saved as text independent of the 'Save Text Files as Text' option in misc menu of 'Select Standard Settings...' (Thanks Wally) <#savetext>: < A = peek $FFD: // Find out if bit 5 set B = A : // Save old flag values X = .andbits A,#bit5 : // Check if 'Save text files if X = 0 : // as text' flag is set to No A = A + #bit5 : // Set the flag in A to yes poke $FFD,A: // Now in memory endif: A = peek $7C68 : // Get current file typ poke $7C68,#iztext : // Set file type as text // OA-S is $D3 and OA-Ctrl-S is $93, so we add that together to get 358. // Subtracting the smart one from the total leaves the dumb one. x = peek $10B1 : X = X + 1 + 128 : // Smart/dumb save value DumbSave = 358 - x : print chr$ DumbSave : //oa-ctrl-S : poke $7C68,A : // Restore file type poke $FFD,B : // Restore "Save text ... " >! Hope this helps, -- Joe Walters: bird@mcs.com or J.L.Walters@genie.com The sound of your horn is far sweeter if blown by somebody else.