Problems with Data Objects, streams, and openDoc

When I try to use this.openDataObject("myObject") in Acrobat 8, I get
NotAllowedError: Security settings prevent access to this property or method.
Doc.openDataObject:1:Console
I have checked that the attachment type is allowed in the registry (and it is by default since the attachment is PDF), so is there a setting that can prohibit JavaScript from opening attachments?  If so, can I change this setting somewhere?
I have discovered that while the above issue needs to be resolved, it is only part of the problem.  I am trying to read in a PDF file using Net.HTTP.request, convert the response using stringFromStream, then feed the response to createDataObject.  The result is not a valid PDF file.  Is this process possible or am I going about this the wrong way?  I have also tried app.openDoc, but since the PDF is located on our intranet https://someserver.com/doc.pdf I get a security error.  Using only folder level JavaScript, is it possible to open a remote file from a web server, evaluate its Doc object (fields, etc), then save the file back out to the local file system?
Thanks,
Scott
Message was edited by: AcroBishop

I have hundreds of Acrobat PDF forms out on the company web server.  There is a web service that produces an xml feed which lists all of the documents hosted on that server.  I read in the XML and query it to return the URL of a desired PDF.  What I need is a way to import the Doc object of that PDF so that I can enumerate over all of the fields and populate a listbox in the current document with those field names.  If I could then save the imported PDF to a local folder, well... that would just be icing on the cake.  The way I have been trying to go about this is to feed the URL to Net.HTTP.request which should (in theory) return the PDF as a stream object.  I run util.stringFromStream on that object because I want to feed it to createDataObject which requires a string to act upon.  My problems at this point in the operation are:
1. I don't think this creates a valid PDF document object and I'm not sure if it should or if I am doing something wrong.  Though I am passing the correct MIME type to the createDataObject (application/pdf)
2. regardless of the type or validity of the attachment, I get the error message that I mentioned in my original post which leads me to believe that somehow this company has disabled opening attachments via JavaScript.  If that is the case I need to know how to change that configuration.

Similar Messages

  • Problem with Date objects

    I have a problem when using Date objects. If i create a Date object like this:
    Date d = new Date( 2002,03,20,19,45 ), and i try to get the number of Milliseconds
    ( d.getTime() ) i get a number that cannot be correct. I't is to high. I't looks like i
    get the number of Milliseconds to year 3000+ ?? But if i write out the Date object
    using a DateFormat.getInstance(), the date is equal to the date i entered above!
    Can anybody help me with this ?? Please ??

    Hi... as far as I remember, the getTime method returns the number of milliseconds since January 1 1970 (a holdover from Unix days).

  • Problem with Date of files and email

    Hi,
    I have a MacBook with MacOSx snow Leopard 10.6.3.
    I have a problem with the date showed for the files inside Finder and for my emails on Apple Mail. All files show a date with correct day and correct hour but with wrong month; all files have as month January. Except for files modified or email received in the last two days all the other files displayed by Finder (and also for email) have this wrong date. But when I want to attach a file to an email or insert a file (for example word) inside another file word the system displays correct date.
    Someone had the same problem?
    The version of Apple Email is 4.2 and the Finder is 10.6.4.

    You make no mention that you have checked your calendar settings.
    System Preferences>Time & Date>Date & Time
    Was this done?
    I am not at my SL MBP at the moment but, the above should be the same and/or similar as the Tiger OS.
    "MacOSx snow Leopard 10.6.3."
    Update to OS 10.6.4, repair permissions and restart your computer.
    !http://i50.tinypic.com/izvwo1.gif!

  • Problems with Date objects

    I want to use the HttpSession.getCreationTime() value and write it to an Oracle Date field.
    I am having trouble getting the value in the proper type and format.
    I have a test servlet to try to understand the various ways to use and convert DateTime values.
    Here's the code:
    response.setContentType("text/html");
    java.io.PrintWriter out = response.getWriter();
    HttpSession session = request.getSession();
    long logontime = session.getCreationTime();
    SimpleDateFormat formatter = new SimpleDateFormat("mm-dd-yyy hh:mm:ss");
    java.sql.Date sqlDate = new java.sql.Date(logontime);
    String sDate = formatter.format(sqlDate);
    out.println("<html>");
    out.println("<head>");
    out.println("<title>Servlet</title>");
    out.println("</head>");
    out.println("<body>");
    out.println("DateTime in Milliseconds: " + session.getCreationTime() + "<br>");
    out.println("DateTime as java.sql.Date: " + sqlDate + "<br>");
    out.println("java.sql.Date SimpleDateFormat: " sDate "<br>");
    out.println("</body>");
    out.println("</html>");
    out.close();
    Here's the output:
    DateTime in Milliseconds: 1016812138284
    DateTime as java.sql.Date: 2002-03-22
    java.sql.Date SimpleDateFormat: 48-22-2002 10:48:58
    What's happening with the Month in the SimpleDateFormat output?
    Also,
    How can I convert this string into a valid Date Object to use in CallableStatement.setDate(int index, Date x)?
    Thank you for your help.

    If you have a String that's in that format, and you want to convert it to a java.util.Date, you do something like this:SimpleDateFormat dateFormatter = new SimpleDateFormat("MM-dd-yyyy hh:mm:ss");
    java.util.Date date = dateFormatter.parse(thatString);Then if you want to convert that to a java.sql.Date, you do this:java.sql.Date sqlDate = new java.sql.Date(date.getTime());However, I suggest you don't actually want to do that. If your date has hours, minutes, and seconds in it then converting to java.sql.Date throws away that information. You may want java.sql.Timestamp instead.

  • Problem with Date object in Servlet

    in following code what i want to do is to convert database date field date
    string in to Date format oject. here user entered date string is convered to Date object successfully but database date field date String is not converting to Date object and i want to compare two dates wheter user ented date is more than the database date field. Pls if u can correct this it is a big help for me.
    Thank u,
    import java.io.*;
    import javax.servlet.*;
    import javax.servlet.http.*;
    import java.sql.*;
    import java.util.Date;
    //import java.text.*;
    public class chkAvail extends HttpServlet
         Connection con=null;
         PreparedStatement ps1,ps2;
         PrintWriter out;
         String UArraDate="";
         String UDepaDate="";
         String ChkType="";     
         Date d2;
    String aDate="";
         public void doGet(HttpServletRequest req,HttpServletResponse res)throws IOException,ServletException
              d2=new Date();
              try
                   res.setContentType("text/html");
                   out=res.getWriter();
                   //UArraDate=req.getParameter("ArrDate");
                   //UDepaDate=req.getParameter("DepaDate");
                   //ChkType=req.getParameter("ChkType");
                   String mydb="jdbc:odbc:portal";
                   Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
                   con=DriverManager.getConnection(mydb);
                   UArraDate="13/09/05";
                   Date d1=new Date(UArraDate);
                   ps1=con.prepareStatement("SELECT * FROM cottageReservation");
                   ResultSet re1=ps1.executeQuery();
                   while(re1.next())
                        //aDate=re1.getString("ADate");
                        //d2=java.sql.Date.valueOf(re1.getString("ADate"));
                        //out.println(d2);
                        aDate=re1.getString("ADate");
                        d2=new Date(aDate);
                        if(d1.after(d2))
                             System.out.println("OK");
                        else
                             System.out.println("NotOK");
              catch(SQLException e)
                   System.out.println(""+e);
              catch(ClassNotFoundException e)
              catch(Exception e)
    }

    Here is an example of how objects can be refered.....
    have a look
    //////////////////////////CustomDatumExample.java///////////////////////////////
    import java.sql.*;
    import oracle.jdbc.driver.*;
    import oracle.sql.*;
    import java.math.BigDecimal;
    public class CustomDatumExample
    /* Example invocation:
    java customDatumTest "jdbc:oracle:oci8:@" SCOTT TIGER \
    "oracle.jdbc.driver.OracleDriver"
    public static void main(String args []) throws Exception
    // Connect
    DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver ());
    OracleConnection conn = (OracleConnection)
    DriverManager.getConnection("jdbc:oracle:oci8:@",
    "scott", "tiger");
    // Create a Statement
    Statement stmt = conn.createStatement ();
    try
    stmt.execute ("drop table EMPLOYEE_TABLE");
    stmt.execute ("drop type EMPLOYEE");
    catch (SQLException e)
    // An error is raised if the table/type does not exist. Just ignore it.
    // Create and populate tables
    stmt.execute ("CREATE TYPE EMPLOYEE AS OBJECT(EmpName VARCHAR2(50),EmpNo INTEGER)");
    stmt.execute ("CREATE TABLE EMPLOYEE_TABLE (ATTR1 EMPLOYEE)");
    stmt.execute ("INSERT INTO EMPLOYEE_TABLE VALUES (EMPLOYEE('Susan Smith', 123))");
    stmt.close();
    // Create a CustomDatum object
    Employee e = new Employee("George Jones", new BigDecimal("456"));
    // Insert the CustomDatum object
    PreparedStatement pstmt
    = conn.prepareStatement ("insert into employee_table values (?)");
    pstmt.setObject(1, e, OracleTypes.STRUCT);
    pstmt.executeQuery();
    System.out.println("insert done");
    pstmt.close();
    // Select now
    Statement s = conn.createStatement();
    OracleResultSet rs = (OracleResultSet)
    s.executeQuery("select * from employee_table");
    while(rs.next())
    Employee ee = (Employee) rs.getCustomDatum(1, Employee.getFactory());
    System.out.println("EmpName: " + ee.empName + " EmpNo: " + ee.empNo);
    rs.close();
    s.close();
    if (conn != null)
    conn.close();
    /////////////////////////////////////////////////Employee.java///////////////////////////////////
    import java.math.BigDecimal;
    import java.sql.SQLException;
    import oracle.jdbc.driver.OracleConnection;
    import oracle.sql.*;
    public class Employee implements CustomDatum, CustomDatumFactory
    static final Employee _employeeFactory = new Employee(null, null);
    public static CustomDatumFactory getFactory()
    return _employeeFactory;
    public Employee ()
    /* constructor */
    public Employee(String empName, BigDecimal empNo)
    this.empName = empName;
    this.empNo = empNo;
    /* CustomDatum interface */
    public Datum toDatum(OracleConnection c) throws SQLException
    StructDescriptor sd =
    StructDescriptor.createDescriptor("SCOTT.EMPLOYEE", c);
    Object [] attributes = { empName, empNo };
    return new STRUCT(sd, c, attributes);
    /* CustomDatumFactory interface */
    public CustomDatum create(Datum d, int sqlType) throws SQLException
    if (d == null) return null;
    Object [] attributes = ((STRUCT) d).getAttributes();
    return new Employee((String) attributes[0],
    (BigDecimal) attributes[1]);
    /* fields */
    public String empName;
    public BigDecimal empNo;
    }

  • Weird Problem With Dates in Finder and Mail

    I have a MBPr running 10.8.2 which is exhibiting a very strange behaviour related to dates.
    Initially, the problem manifested in Mail where the date shown in the message list for each message was exactly the same, regardless of the date sent/received. Oddly, this problem only manifested in the "new" mail view. Switching to "Classic" view in Mail prefs works fine. This seemed odd enough, but only related to mail.
    Then, I noticed the exact same date was the Creation, Modification, and Last Opened date for many files (including all of the .emlx files in the Mail folder) as shown in the preview column in the Finder's column view. Oddly, the exact same files show different Creation/Modification/Opened dates when viewed in a Get Info window or when listed in the Terminal with ls -l.
    Clearly there is some kind of issue with a cache, or an index of some sort that is accessed by the Finder and/or Mail. I'm attaching a screenshot of the Get Info window and the Finder preview column for a file. Thanks for any info anyone can shed on this.

    Embarrassingly, the "More Like This" box to the immediate right of my post shows a discussion titled "Incorrect dates in column view preview" that fixed the problem.
    How this affects the "new" view in Mail and not the "Classic" view is beyond me, but I'm also beyond caring at this point.

  • Problem with data output stream

    in the code
    output.writeBytes(String arg);
    output.writeInt(Int arg);
    output.writeLong(dateOfPurchase.getTime());the first line is working fine ,but the other two line ,even though it writes something to the file it is not in a readable format can anyone help

    the first line is working fine ,but the other two line ,even though it writes something to the file it is not in a readable formatIt's not meant to be in a readable format. It's meant to be a big-endian binary representation of the data.
    can anyone helpNo help required. The software is working as designed.

  • Having a problem with dates when I send my numbers doc to excel. dates are all out and that they have to cut and paste individual entries onto their spreadsheet. Any idea how I can prevent this

    having a problem with dates when I send my numbers doc to excel. dates are all out and that they have to cut and paste individual entries onto their spreadsheet. Any idea how I can prevent this.
    I'm using Lion on an MBP and Numbers is the latest version

    May you give more details about what is wrong with your dates ?
    M…oSoft products aren't allowed on my machines but I use LibreOffice which is a clone of Office.
    When I export from Numbers to Excel and open the result with LibreOffice, the dates are correctly treated.
    To be precise, dates after 01/01/1904 are correctly treated. dates before 01/01/1904 are exported as strings but, as it's flagged during the export process, it's not surprising.
    Yvan KOENIG (VALLAURIS, France) mardi 3 janvier 2012
    iMac 21”5, i7, 2.8 GHz, 12 Gbytes, 1 Tbytes, mac OS X 10.6.8 and 10.7.2
    My iDisk is : http://public.me.com/koenigyvan
    Please : Search for questions similar to your own before submitting them to the community
    For iWork's applications dedicated to iOS, go to :
    https://discussions.apple.com/community/app_store/iwork_for_ios

  • Tp ended with error code 0247 - addtobuffer has problems with data- and/or

    Hello Experts,
    If you give some idea, it will be greatly appreciated.
    This transported issue started coming after power outage, sap system went hard shutdown.
    Then we brought up the system. Before that , we do not have this transport issue.
    our TMS landscape is
    DEV QA-PRD
    SED-SEQSEP
    DEV is having the TMS domain controller.
    FYI:
    *At OS level, when we do scp command using root user, it is fine for any TR.
    In STMS, while adding TR in SEQ(QA system), we  are getting error like this.
    Error:
    Transport control program tp ended with error code 0247
         Message no. XT200
    Diagnosis
         An error occurred when executing a tp command.
           Command:        ADDTOBUFFER SEDK906339 SEQ client010 pf=/us
           Return code:    0247
           Error text:     addtobuffer has problems with data- and/or
           Request:        SEDK906339
    System Response
         The function terminates.
    Procedure
         Correct the error and execute the command again if necessary.
    This is tp version 372.04.71 (release 700, unicode enabled)
    Addtobuffer failed for SEDK906339.
      Neither datafile nor cofile exist (cofile may also be corrupted).
    standard output from tp and from tools called by tp:
    tp returncode summary:
    TOOLS: Highest return code of single steps was: 0
    ERRORS: Highest tp internal error was: 0247

    when we do scp using sm69,
    SEDADM@DEVSYS:/usr/sap/trans/cofiles/K906339.SED SEQADM@QASYS:/usr/sap/trans/cofiles/.
    it throws the error like below,
    Host key verification failed.
                                                                                    External program terminated with exit code 1
    Thanks
    Praba

  • I am using i 4 phone. recently I had a problem with my lap top and had formatted hard disk of it. Now I want to use sync data in my iphone back to itune n my lap top. how can I perform this task with out loosing data in my i phone.

    I am using i 4 phone. recently I had a problem with my lap top and had formatted hard disk of it. Now I want to sync data in my iphone back to itune on my lap top. how can I perform this task with out loosing data in my i phone.

    Hey floridiansue,
    Do you have an installed email program such as Microsoft Outlook?  If your email is through an online login, such as Gmail, etc, then one will have to create an email association with a program such as Microsoft Outlook on the PC for this Scan to Email system to function.
    -------------How do I give Kudos? | How do I mark a post as Solved? --------------------------------------------------------
    I am not an HP employee.

  • Has anyone else had a problem with data? after updating my phone to the new update, i have all this data, and keep getting notifications that my data is getting high. i never had this problem before.

    has anyone else had a problem with data? after updating my phone to the new update, i have all this data, and keep getting notifications that my data is getting high. i never had this problem before.

    fair enough.  No need for any unnecessary posts either.  You issue had been addressed ad nauseum already in this forum had you bothered to search this forum (as forum etiquette would dictate) before posting.
    In any case, I hope that your problem was solved.

  • I have problem with data transfer between Windows Server 2012RT and Windows7 (no more than 14kbps) while between Windows Sever 2012RT and Windows8.1 speed is ok.

    I have problem with data transfer between Windows Server 2012RT and Windows7 (no more than 14kbps) while between Windows Sever 2012RT and Windows8.1 speed is ok.

    Hi,
    Regarding the issue here, please take a look at the below links to see if they could help:
    Slow data transfer speed in Windows 7 or in Windows Server 2008 R2
    And a blog here:
    Windows Server 2012 slow network/SMB/CIFS problem
    Hope this may help
    Best regards
    Michael
    If you have any feedback on our support, please click
    here.
    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.

  • Does anyone have problems with data usage with att and Iphone5?

    Hello, Does anyone have problems with data usage or non usage I should say with Iphone 5 and AT&T?

    After 4+ months of dealing with this data usage and battery drain problem that included 3 data captures of my wife's iMac, the trigger for us regarding the problems syncing with iCloud, and 5 hours of logs off my iPhone 6 to be analyzed by Apple engineers that included times my wife's computer was both on and off to demonstrate the difference in data usage and battery drain under those conditions, I can say with very reasonable certainty that the iOS 8.3 and corresponding Mac OS 10.10.3 update has solved the problem. 
    We have now been running for about 2 weeks and data usage with the iCloud Servers attempting to sync has dropped from a rate of 31 GBs to under 15 MBs per month.  Yes, you read it right.  We were burning 2000 times as much data doing absolutely nothing important on both of our phones, a 5s and a 6.  Just imagine what that does to battery life!  The 5s would last about 5 hours and the 6 was dead in less than 14.
    The distasteful aspect of this process was how the engineers were quietly fixing the problem at the same time sending messages to my contact person within Apple that were dismissive in nature in the face of indisputable unreasonable results. I must say, this experience with the multiple times the engineers' responses were inappropriate put a little tarnish on the old Apple shine of the ‘It just works’ mantra. This was my first experience in 34 years that caused me to stop recommending Apple products without reservations and with a disclaimer.
    Since the update solved the problem, then I can only conclude that there was a logic bug regarding the reaction within the process to the incoming data that was corrected.  There was noting short of logging out of iCloud that circumvented the problem for us, Gator5000e and probably many others noted on other threads.  I am not trying to imply that this is the cause of everyones battery use problem, but it is reasonable that it was a cause for many.

  • Problem with data in Adobe Forms - partially displayed(first pade only)

    Hi all .
    I only start work  with Adobe Forms so I need your help .
    My form includes   table with lot of data .
    My problems are:
    1.only the first page with data is displayed and I don't see the rest  of data .
           What I need to define  for get all my data printed ?
    2. How can I print total at end of  table ?
                 Regards Helena .

    select the subform where your table body present , there you choose the pallete object inside you need to set.
    if you still have doubts see these blogs
    Adobe Forms Using:  Nested Table, Text Module & providing the functionality of Page Total & Grand Total
    Displaying Internal Table in Adobe Form

  • Problem with inherited Objects

    Hi,
    I have a problem with inherited objects inside Flex using
    wsdl as the source of the object. The AS-classes are generated
    inside Flex Builder 3.
    Inside the wsdl I have 2 complex types:
    <complexType abstract="true" name="PersistentObject">
    <sequence>
    <element name="id" nillable="true" type="xsd:string"/>
    <element name="insertTimeStamp" nillable="true"
    type="xsd:dateTime"/>
    <element name="insertUsername" nillable="true"
    type="xsd:string"/>
    <element name="updateTimeStamp" nillable="true"
    type="xsd:dateTime"/>
    <element name="updateUsername" nillable="true"
    type="xsd:string"/>
    </sequence>
    </complexType>
    and
    <complexType name="Contact">
    <complexContent>
    <extension base="tns3:PersistentObject">
    <sequence>
    <element name="birthday" nillable="true"
    type="xsd:dateTime"/>
    <element name="firstName" nillable="true"
    type="xsd:string"/>
    <element name="lastName" nillable="true"
    type="xsd:string"/>
    <element name="middleName" nillable="true"
    type="xsd:string"/>
    <element name="newPassword" nillable="true"
    type="xsd:string"/>
    <element name="password" nillable="true"
    type="xsd:string"/>
    <element name="title" nillable="true"
    type="xsd:string"/>
    <element name="username" nillable="true"
    type="xsd:string"/>
    </sequence>
    </extension>
    </complexContent>
    </complexType>
    The classes in actionscript seem plausable:
    public class PersistentObject
    * Constructor, initializes the type class
    public function PersistentObject() {}
    public var id:String;
    public var insertTimeStamp:Date;
    public var insertUsername:String;
    public var updateTimeStamp:Date;
    public var updateUsername:String;
    and
    public class Contact extends PersistentObject
    * Constructor, initializes the type class
    public function Contact() {}
    public var birthday:Date;
    public var firstName:String;
    public var lastName:String;
    public var middleName:String;
    public var newPassword:String;
    public var password:String;
    public var title:String;
    public var username:String;
    When I want to retreive an object of type Contact, it seems
    that only a couple of entries are filled. While debugging the flex
    XMLDecoder, I noticed something strange. It seems, like the decoder
    is expecting the result xml data to be in alphabetical order:
    birthday, firstname, lastname, etc. But since the object is
    inherited, the data that is actually received contains elements
    from the parent class: birthday, firstname, id, inserttimestamp,
    The resulting object has just birthday and firstname filled,
    which is somehow wrong. This seems to be a problem inside the
    parser itself. What can I do?

    I am having a problem with an extended class as well.
    When I step through the code, everything is going fine and the decoder (mx.rpc.xml::XMLDecoder) sees that the class is an extension and wants to get the values for the superclass first.  When it gets into getApplicableValues(), it's looking for the values to be in the order of the definition which would be ok if the values collection didn't include the values from the subclass as well!  It goes through the whole definition and doesn't find anything for the superclass because the values aren't where it expects them.  When it pops back up to the subclass and starts to decode those values, it finds them because the definition order and values order match.
    Is this a known issue?  Or, am I misunderstanding something?
    Thanks,
    Chuck

Maybe you are looking for

  • BT Sport Is An Utter Disaster

    What the hell is going on? I can no longer get BT Sport (initially, I could). Error messages. Advice on the site that doesn't work. Telephone 'support' that doesn't answer (again and again). The forum is chock-full of complaints. Nobody seems to be d

  • Service entry tables

    Hi Gurus, i have an issue in finding out the cumulative qty in the service entry sheet i have Service entry sheet smartform developed,in that cumulative qty i ahve give the Field ACT_MENGE against the entry sheet number,but this value is changing aft

  • My master card

    My master card  was working effectively, suddenly it stopped ! it says my payment method is not accepted ! why I have money in my card but still cann't use it and msg : plz contac to itunze support hlp me

  • XI Alert - How to put messageid into Subseq. Activities Link

    Hi, I have control step to throw alert whenever error occur in the BPM. How can i put the messageid into the Subseq. Activities link so the user can only click the link and open the message in the message monitoring. I gave the URL below in the subse

  • Cerification in SAP - MM

    Dear All, Please guide me that which is best certification in SAP - MM Module. Give the details about that. reg VIS