Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!samsung!uunet!brunix!cs.brown.edu!pew From: pew@cs.brown.edu (Peter E. Wagner) Newsgroups: comp.databases Subject: Re: FoxPro Memo field Question Message-ID: <73882@brunix.UUCP> Date: 29 Apr 91 18:37:20 GMT References: <3263@mtecv2.mty.itesm.mx> Sender: news@brunix.UUCP Organization: Brown Computer Science Dept. Lines: 80 In article <3263@mtecv2.mty.itesm.mx>, al156125@mtecv2.mty.itesm.mx (Francisco J. Peon) writes: |> hi: |> |> I am working with Foxpro and I have a few troubles wit memo fields. |> |> I need to display a predefined message inside a memo field. |> The message could be several lines long, so I can't print the |> message in a memo window title. |> |> ______________________________________________ |> | | |> | Author: | |> | Title : | |> | Source: | |> | | |> ---------------------------------------------- |> memo field |> |> Where Author, Title and Source are the messages that I |> Would like to display each time the user edits, that memo field. |> Do you want the user to fill in these fields first, and then have this data copied into the memo field? What you probably want here is simply the replace command. Set a variable equal to "Author: Title : Source:" You will need to use some special characters ( = chr(13) anyway) to get the fields aligned on different lines. var = "Author:" + chr(13) + "Title:" + chr(13) + "Source:" Then just replace the memo field with this string. replace with var I think this is right, but it's just coming off the top of my head. This may not work verbatim, I'm a little rusty. You can also use "copy to " and "copy from " (I think it's 'copy'...) to move data into and out of memo fields. However, I believe this is for copying in files and copying out to files... In addition, there are some functions that allow you to manipulate the contents of a memo field, replacing instances of strings and such. |> |> Also I would like to know if it's possible to use the |> @ instruction (@1,1 Say "message") inside a memo. No, it is not. However, you might be able to define a new window and position it over your memo window. You could write into this window. You could define this window w/o a border so that it looks like you are writing into the memo window. |> |> How can I delete a specific memo from a record? |> I do not want to delete all the record neither all memo fields. I think 'replace with ""' will do the job. Good luck! Peter -- ---------------------------------------------------------------- Peter E. Wagner (401)863-7685 pew@cs.brown.edu Department Computer Science Box 1910 pew@BROWNCS.BITNET Brown University, Providence, RI 02912 uunet!brunix!pew Woody Allen when asked if he thought sex was dirty; `If you do it right.' ----------------------------------------------------------------