Filling out a form in the field

Discussion in 'iOS Programming' started by Dookieman, Jan 2, 2014.

  1. Dookieman macrumors 6502

    Joined:
    Oct 12, 2009
    #1
    I am looking to make an iOS app that fills out a form for the field instead of writing them by hand, which would make it more manageable. My idea is to assign different text boxes e.g. "Project Name", "Date", "First Paragraph about project in the field", a Drop down menu with some standard language that is used to assess what you find in the field. Then have it transpose on top of the word document/PDF so I can print it off when I get back to the office.

    I have the ability to design the layout and store the data after being written, but not sure how to "save it" to a file.
    How would I approach this?

    Thanks,
     
  2. chown33 macrumors 604

    Joined:
    Aug 9, 2009
    #2
    If your question is about saving the text-composited-atop-PDF to a file, see here:
    https://developer.apple.com/library...gprintingios/GeneratingPDF/GeneratingPDF.html
    The UIKit framework provides a set of functions for generating PDF content using native drawing code. These functions let you create a graphics context that targets a PDF file or PDF data object. You can then create one or more PDF pages and draw into those pages using the same UIKit and Core Graphics drawing routines you use when drawing to the screen. When you are done, what you are left with is a PDF version of what you drew.

    If your question is about saving the plain textual data, which will be composited atop PDF later, then I think an NSDictionary and a plist file would work. See the NSDictionary class reference, and look for method names that start with "writeTo".
     
  3. Dookieman thread starter macrumors 6502

    Joined:
    Oct 12, 2009
    #3
    I would like to have it "Fill it out in the background of the app" so I think pasting it on top of a PDF would be the best.

    Thanks, I'll look into it.
     

Share This Page