Learn R Programming

redcapAPI (version 2.10.0)

exportPdf: Export PDF file of Data Collection Instruments

Description

These methods allow the user to download PDF files of data collection instruments. The download may be with or without collected data; and may return a single record, multiple records, or all records.

Usage

exportPdf(
  rcon,
  dir,
  filename = "redcap_forms_download",
  record = NULL,
  events = NULL,
  instruments = NULL,
  all_records = FALSE,
  ...
)

# S3 method for redcapApiConnection exportPdf( rcon, dir, filename = "redcap_forms_download", record = NULL, events = NULL, instruments = NULL, all_records = FALSE, ... )

Value

exportPdf invisibly returns the location on the local system to whihc the files is saved.

Arguments

rcon

A redcapConnection object.

dir

character(1). The directory into which the file should be saved.

filename

character(1). The base of the file name. When record = NULL, it will be appended with "_blank.pdf". When record has a value, it will be appended with "_record_[record id].pdf"

record

character(1), integerish(1), or NULL. The record id for which forms should be downloaded.

events

character. The events for which forms should be downloaded

instruments

character. The instruments for which forms should be downloaded

all_records

logical(1). When TRUE forms for all records are downloaded. When TRUE, this overrides the records argument.

...

Arguments to pass to other methods

Details

These methods mimics the behavior of "Download PDF of Instruments" button on the REDCap user interface. They permit the user to export a PDF file for:

  1. A single collection instrument (blank)c

  2. All instruments (blank)

  3. A single instrument (with data from a single record)c

  4. All instruments (with data from a single record)

  5. All instruments (with data from all records)

See Also

exportMetaData(),
importMetaData(),
exportFieldNames(),
exportInstruments(),
exportMappings(),
importMappings()