How to find Image Region and add image in it?

Ask a Question related to Adobe Acrobat SDK, Design and Development.

  1. #1

    Default How to find Image Region and add image in it?

    Hello,
    I want to write a plug-in for Adobe Reader 8.First,the plug-in find the appointed Image Region such as named myImage in PDF file which designed by Adobe Designer 8.0. Then,want to add a picture in the image region when people used Adobe Reader.
    I don't know whether plug-in for Adobe Reader can realize that.If it can do,how to find the Image Region?
    Is there anyone can give me any suggestion?

    Thanks!
    yun
    yiyun0918@adobeforums.com Guest

  2. Similar Questions and Discussions

    1. I know we can set max image width, but I need to set itby region. Region A has one max width; Region B another.
      We can already set a maximum image width for use globally, throughout every page. Can we do it by region? This way one region can have a max...
    2. How to find size (in bytes) of an image using the GD image resource?
      I would like to be able to determine the size (in bytes) of a file and re-adjust before output. Is this possible? Norm -- Avatar hosting at...
    3. can you see/find imported image file names?
      I have a bunch of .tif's that I imported into Acrobat using the "Create from Mulitple Files" option. Is there any way I can bring in the actual file...
    4. Load JPG into Flash and find out the size of the image
      does it works with local loading too? I tryed the code below with flash loading a JPEG image located on my hard drive. The widht/height of my...
    5. Can I take a small (320x240), blurry image, and make it a clear, large image?
      Just wondering if there is an easy way to do this? I'm sure it won't be perfect cause photoshop can only work with what's there, but maybe it can...
  3. #2

    Default Re: How to find Image Region and add image in it?

    Before starting your project you must contact Adobe:
    <http://www.adobe.com/devnet/reader/ikla.html>
    Bernd Alheit Guest

  4. #3

    Default Re: How to find Image Region and add image in it?

    We have contacted Adobe.
    Can you tell me whether we can realize that function?
    Thanks!
    yiyun0918@adobeforums.com Guest

  5. #4

    Default Re: How to find Image Region and add image in it?

    It seems unlikely that Adobe would allow you to write such a plug-in.
    Have they indicated it will be allowed?

    If so, this is still a major technical challenge, because a Designer
    form is not a normal PDF, and 99% of the API is useless. You would
    have to extract the embedded XFA XML, update the XML, and resave into
    the PDF.

    Aandi Inston
    Aandi_Inston@adobeforums.com Guest

  6. #5

    Default Re: How to find Image Region and add image in it?

    Thank Aandi Inston!
    When I used API AFPDFieldGetName to get the name of a field,the string it return is not equal to the name that I set .Why?
    Codes:
    ACCB1 ASBool ACCB2 FieldEnumProc ( PDField fldP, void *clientData)
    {

    CosDoc cosDoc;
    CosObj fieldCosObj, keyValueObj, stringObj;
    char *fieldName;
    ASInt32 fieldNameLength;
    DURING
    if ( AFPDFieldIsValid (fldP))
    {
    fieldCosObj = AFPDFieldGetCosObj (fldP);
    if (! CosDictKnownKeyString (fieldCosObj, "FT"))
    E_RETURN( true );
    keyValueObj = CosDictGetKeyString (fieldCosObj, "FT");
    if ( CosName != CosObjGetType (keyValueObj))
    E_RETURN( true )
    if (( CosNameValue (keyValueObj) == ASAtomFromString ("Tx"))) {
    cosDoc = CosObjGetDoc (fieldCosObj);
    fieldName = AFPDFieldGetName (fldP);
    fieldNameLength = strlen (fieldName);
    stringObj = CosNewString (cosDoc, false , fieldName, fieldNameLength);
    AFPDFieldSetValue (fldP, stringObj);
    }
    }
    HANDLER
    END_HANDLER

    return true;
    }
    yiyun0918@adobeforums.com Guest

  7. #6

    Default Re: How to find Image Region and add image in it?

    Because those APIs are only for AcroForms. Designer creates XFA forms, and as Aandi mentioned 99% of the APIs are useless on XFA forms. You'll have to code this entirely from scratch, again as Aandi mentioned.
    PDL@adobeforums.com Guest

  8. #7

    Default Re: How to find Image Region and add image in it?

    Thanks!
    1.These codes can get the Fields in PDF.So , whether Adobe's SDK provide other API to realize that?
    2.If I have to begin from scratch, where do I begin?Is there any document?
    3.I didn't know much about XFA.Is there any API to parse XFA?
    yiyun0918@adobeforums.com Guest

  9. #8

    Default Re: How to find Image Region and add image in it?

    >1.These codes can get the Fields in PDF

    Yes, but only if you make a PDF which is an Acroform.
    You have chosen to use Designer instead. This is completely different.
    >.So , whether Adobe's SDK provide other API to realize that?
    I am not aware of anything in the Acrobat SDK, except to work as I
    described.
    >2.If I have to begin from scratch, where do I begin?Is there any document?
    You should always start a project on this scale by reading the PDF
    Reference, but most of it will not be relevant. So you should
    probably start by reading the section about XFA forms. This references
    other specifications.
    >3.I didn't know much about XFA.Is there any API to parse XFA?
    XFA is a form of XML. There are many APIs to parse XML files, you
    don't need one from Adobe, once you have it extracted.

    I emphasise: this is a major project. Very few programmers have
    attempted projects of this kind. It would be much simpler if you could
    work with Acroforms. Why are you using Designer, specifically, rather
    than Acroforms?


    Aandi Inston
    Aandi_Inston@adobeforums.com 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