home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / sys / mac / database / 1634 < prev    next >
Encoding:
Text File  |  1992-12-29  |  3.0 KB  |  61 lines

  1. Newsgroups: comp.sys.mac.databases
  2. Path: sparky!uunet!wupost!csus.edu!netcom.com!netcom!triantos
  3. From: triantos@netcom.Netcom.COM (Nick B Triantos)
  4. Subject: Re: Searching for non-blanks while using a script in FMP2.0
  5. In-Reply-To: mwgordon@nyx.cs.du.edu's message of Mon, 28 Dec 92 17:23:31 GMT
  6. Message-ID: <TRIANTOS.92Dec28134554@netcom.Netcom.COM>
  7. Sender: triantos@netcom.com (Nick B Triantos)
  8. Organization: Netcom Online Communications Service
  9. References: <1992Dec28.172331.7003@mnemosyne.cs.du.edu>
  10. Date: Mon, 28 Dec 1992 21:45:54 GMT
  11. Lines: 48
  12.  
  13. In article <1992Dec28.172331.7003@mnemosyne.cs.du.edu> mwgordon@nyx.cs.du.edu (Mike Gordon) writes:
  14.  
  15. >Is there a way to search for non-blank records in a script?  Actually,
  16. >I need to search for records that are not blank in fields W, X, Y, or Z, but
  17. >all records will have data in fields A,B,C, and D.
  18.  
  19. What you can do is to set up a calculation field that would be a small IF
  20. statement for whether the fields are blank.  Here's a way to do it:
  21.  If (W & X & Y & Z & "_" = "_", 1, 0)
  22. This is the preferred way to test for a blank.  What we've just done is
  23. concatenated all four fields together, and placed an underscore at the end
  24. of the whole thing.  If that whole mess equals just an underscore, then we
  25. know that the first four fields were blank.  You can now have your script
  26. Perform a Find for any records with a 1 in this calculation field, and
  27. you'll have all the ones with W, X, Y, and Z blank...
  28.  
  29. > I can't even figure out a way to get Filemaker to perform a search for 
  30. >a pre-defined string when running a script.   There must be a way to do this, 
  31. >because there are many applications I can see where you would want a button to
  32. >find all occurences of something and print a report.
  33.  
  34. Set up a Find request exactly as you want the script to do the find.  Enter
  35. the ScriptMaker, and add the "Perform Find" command, with the "Restore"
  36. option on.  That should do it.
  37.  
  38. If you want to find a string that could be in any one of several fields, set
  39. up your Find by placing the string in one of the fields, asking for a "New
  40. Request", placing the string in the second field, adding a new request,
  41. placing it in the third, and so on.  When you perform the find, FileMaker
  42. Pro will find any records with the string in any one of the fields you
  43. requested it look in.  New Requests in Find mode can be thought of as
  44. analagous to the logical OR operation.
  45.  
  46. > Also, is there a way to make FMP2.0 print a report to a file instead of
  47. >the printer?  I could save quite a few trees each month with this feature.
  48.  
  49. Not directly, but there's a great shareware program called Print2Pict that
  50. gives you a chooser document to which you can print.  Print2Pict will create
  51. PICTs, extract the text, create standalong postcards, and I believe there's
  52. even more.  Check it out by FTPing it from your favorite Mac archive site,
  53. such as mac.archive.umich.edu, sumex.stanford.edu, etc., or from America
  54. OnLine.
  55.  
  56. -Nick "A moose once bit my sister" Triantos
  57.  
  58. I may work in Claris Technical Support, but not when I'm logged in on
  59. the Internet... 
  60.  
  61.