Display PDF Stored as OLE Object

Ask a Question related to Coldfusion Database Access, Design and Development.

  1. #1

    Default Display PDF Stored as OLE Object

    I have an Access database that has a field defined as an OLE Object to store
    PDF files. I have seen the posts related to using cffile and cfcontent but
    cannot get things to work. The problem seems to be generating the pdf file
    from the database. My code looks like the following:

    <cfoutput>
    <cffile action="write" file="Document.pdf"
    output="#toBinary(mydata.myfield)#"/>
    <cfcontent type="application/pdf" file="Document.pdf">
    </cfoutput>

    If anyone has any insight I could sure use it. And a code example would be
    greatly appreciated.

    Randy


    RandyWheeler Guest

  2. Similar Questions and Discussions

    1. How to Display A Stored TIF Blob field in SQL Server
      Does anybody know how to display a TIF blob field in SQL Server? :confused;
    2. object references stored in array gives me what?
      I'm nervous this method is not doing what I assumed it was doing. Does it not create objects, store them in an array, and check that array to see...
    3. Can't display images stored as Oracle BLOBs
      I have been fighting with storing/retrieving images in an Oracle database using ASP for over a month now. I have been able to store images < 64K w/...
    4. Unable to display stored array
      In the following code snippet, I build an array called $emp_final, which I attempt to echo later on. If I uncomment the echo immediately after the...
    5. Net::SNMP stored in an Object
      hey everyone... i've done loads of searches on the net and nothing has come up relating to the issue i have been having. is there anyone who can...
  3. #2

    Default Re: Display PDF Stored as OLE Object

    I never store files in a database. What I do is I use a text field with a
    path to the file and display it that way.


    "RandyWheeler" <webforumsuser@macromedia.com> wrote in message
    news:dqufvc$ki7$1@forums.macromedia.com...
    >I have an Access database that has a field defined as an OLE Object to
    >store
    > PDF files. I have seen the posts related to using cffile and cfcontent
    > but
    > cannot get things to work. The problem seems to be generating the pdf
    > file
    > from the database. My code looks like the following:
    >
    > <cfoutput>
    > <cffile action="write" file="Document.pdf"
    > output="#toBinary(mydata.myfield)#"/>
    > <cfcontent type="application/pdf" file="Document.pdf">
    > </cfoutput>
    >
    > If anyone has any insight I could sure use it. And a code example would
    > be
    > greatly appreciated.
    >
    > Randy
    >
    >

    Rick Guest

  4. #3

    Default Re: Display PDF Stored as OLE Object

    Take baby steps. Run just the CFFILE tag, and see if you can find the file on
    the server. Use full pathing in your tags so there's no mistake about where
    the file is being written to or retrieved from.

    philh Guest

  5. #4

    Default Re: Display PDF Stored as OLE Object

    Rick,

    That was my plan B. I will take your advice. Thanks.

    Randy
    RandyWheeler Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139