Adding attachments to task

Hi, í´ve develop a solution to allow .NET applications to communicate with Oracle Workflow beacuse the Worklistmanager doesn´t work for me. So I´ve embed Java code in a java web service that manages all the api of the workflow. I have a method that allows to update the task state. And I´ve been improving it, so i decided to include a parameter that is a byte array that corresponds to a file for attach it to the task.
The code looks like this...
private Task addAttachmentToTask(IWorkflowContext oWorkflowContext,
ITaskService oTaskService, String taskId,
byte[] content) {
try {
AttachmentTypeImpl attachment;
ByteArrayInputStream attachedContent;
Task oTask;
attachment = new AttachmentTypeImpl();
attachedContent = new ByteArrayInputStream(content);
attachment.setInputStream(attachedContent);
attachment.setTaskId(taskId);
attachment.setMimeType("application/octet-stream");
oTask = oTaskService.addAttachment(oWorkflowContext, taskId,
attachment);
return oTask;
} catch (StaleObjectException e) {
this.LogText(e.toString());
return null;
} catch (WorkflowException e) {
this.LogText(e.toString());
return null;
the code is resulting in a nullpointer exception just in the line when I call the service of the workflow..
is there any documentation? Please help!

Hi, Jasmin
How to add a external file(.doc or .xls)as a attachement to a xfa form variable in process?
I've tried using the DDX and Assembler service.
When I set the input and output variable as document, the process works.
But when I set them as xfa form or document form, the process will fail by exception.
The Assembler service seems to accept the document type variable only.
the exception is :
Failure to invoke the job Assembler
Failure to invoke the job Assembler
Cannot coerce object: <document state="passive" senderVersion="0" persistent="false" senderPersistent="false" passivated="true" senderPassivated="false" deserialized="false" senderHostId="null" callbackId="0" senderCallbackId="0" callbackRef="null" isLocalizable="true" isTransactionBound="false" defaultDisposalTimeout="600" disposalTimeout="600" maxInlineSize="65536" defaultMaxInlineSize="65536" inlineSize="0" contentType="application/pdf" length="-1"><cacheId/><localBackendId><DocumentFileID fileName="C:\Documents and Settings\Administrator\Local Settings\Temp\AdobeDocumentStorage\local\docm1205306662328\b152e2c400d064ec2e16c01b547d25 d1"/><localBackendId/><globalBackendId/><senderLocalBackendId/><senderGlobalBackendId/><in line/><senderPullServantJndiName/><attributes file="C:\Adobe watch folder\Assembler\stage\Wxb7cbc144aa8e397ee4b4725a\testform3.pdf"/></document> of type: com.adobe.idp.Document to type: class com.adobe.idp.taskmanager.form.impl.xfa.XFARepositoryFormInstance
ALC-DSC-600-000:
Will I need to transfer the xfa form or document form to document type? How to do that?
Or is there another way to achieve this goal?
Bking

Similar Messages

  • Need link/button to allow users to add attachments to Tasks on Collect Feedback workflow

    Hi All,
    we would like to modify the
    Collect Feedback workflow in SharePoint to
    allow users to add attachments to Tasks. We need an additional button on the review form to attach files, when the reviewers are submitting their comments. 

    Hi nai.mish,
    I would not suggest you to modify the default collect feedback workflow, but to custom a workflow with custom form page that similar with the default workflow.
    You can consider using SharePoint Designer workflow, in this way, you may not be able to custom the task form with attachment, you can try to use “Hyperlink or Picture” column, this will need the viewer to upload the attachment to a library
    first.
    Or you can create VS workflow, the following has a sample about adding attachment to an InfoPath Workflow task form, you can get more information from it:
    http://www.devexpertise.com/category/sharepoint/workflow/
    Thanks,
    Qiao Wei
    TechNet Community Support

  • Can you customize what folder MAIL goes to when adding attachments?

    Can you customize what folder MAIL goes to when adding attachments?
    My friend has 2 email addresses for businesses.
    He has invoices in folders for both, and wants to set up the Mac like this:
    When he writes from one email address and attaches documents - he want the Mac always to go to the corresponding folder for that company of his. Same for the other email address...
    Make sense?
    Can this be done?
    Thanks in advance....

    Please read this whole message before doing anything.
    This procedure is a diagnostic test. It’s unlikely to solve your problem. Don’t be disappointed when you find that nothing has changed after you complete it.
    The purpose of the test is to determine whether your problem is caused by third-party system modifications that load automatically at startup or login. 
    Disconnect all wired peripherals except those needed for the test, and remove all aftermarket expansion cards. Boot in safe mode* and log in to the account with the problem. The instructions provided by Apple are as follows:
    Shut down your computer, wait 30 seconds, and then hold down the shift key while pressing the power button.
    When you see the gray Apple logo, release the shift key.
    If you are prompted to log in, type your password, and then hold down the shift key again as you click  Log in.
    *Note: If FileVault is enabled under OS X 10.7 or later, or if a firmware password is set, or if the boot volume is a software RAID, you can’t boot in safe mode. Safe mode is much slower to boot and run than normal, and some things won’t work at all, including wireless networking on certain Macs.  The next normal boot may also be somewhat slow.
    The login screen appears even if you usually log in automatically. You must know your login password in order to log in. If you’ve forgotten the password, you will need to reset it before you begin. Test while in safe mode. Same problem? After testing, reboot as usual (i.e., not in safe mode) and verify that you still have the problem. Post the results of the test.

  • What is Best Practice for Adding Thousands of Tasks to CloudJob?

    I am looking for some guidance on adding lots of tasks to a CloudJob.
    I have thousands of tasks to add to a job, and several parent tasks running across multiple TVMs are participating in adding the new tasks to the job. However, I can reproduce my problem with a single task that tries to add new tasks to the job with
    a max degree of parallelism of 15.
    In each thread, I call IBatchClient.OpenWorkItemManager, then IWorkItemManager.GetJobAsync, then ICloudJob.AddTaskAsync, followed by ICloudJob.CommitAsync in order to add a new task. I will occasionally get a "Server encountered an internal error. Please
    try again after some time." exception. After I delay, and then retry the entire series of operations again (from OpenWorkItemManager all the way to ICloudJob.CommitAsync), I receive the "A task instance can only be added to a single job." exception.
    Since I am receiving these exceptions frequently, I am hoping that there is a better way to add a lot of tasks to the job. I see a way to add multiple tasks to a work item, but I don't know what the tasks will be ahead of time. I have to wait until I am
    well into processing the job before I know what new tasks need to be added to the job.

    Am I correct in assuming you're doing something like this?
    Parallel.For(0, 100, new ParallelOptions() { MaxDegreeOfParallelism = 15}, async (idx) =>
    IWorkItemManager manager = batchClient.OpenWorkItemManager();
    ICloudJob job = await manager.GetJobAsync("wiName", "jobName");
    await job.AddTaskAsync(new CloudTask("foo", "cmdline"));
    You are doing some extra exception handling and stuff too as well I assume.
    There are a few improvements you can/should make that ought to make your life easier.
    First, the GetJobAsync() call actually does a round trip to the server -- you can avoid doing this for every task you add and reduce your round trips by half:
    IWorkItemManager manager = batchClient.OpenWorkItemManager();
    ICloudJob job = manager.GetJob("wiName", "jobName");
    //Foo("Test", "Abc", "test");
    Parallel.For(0, 100, new ParallelOptions() { MaxDegreeOfParallelism = 15}, async (idx) =>
    await job.AddTaskAsync(new CloudTask("foo", "cmdline"));
    Even more than that, we provide a helper method which has this functionality and performs bulk adds behind the scenes, which will reduce your round trips by about a factor of 50-100.
    IWorkItemManager manager = batchClient.OpenWorkItemManager();
    List<ICloudTask> tasksToAdd = new List<ICloudTask>(); //Popualte this with your tasks
    await manager.AddTaskAsync("wiName", "jobName", tasksToAdd, new BatchClientParallelOptions() { MaxDegreeOfParallelism = 15 });
    Additionally, we have a way where you can configure a "retry policy" without having to manually do it yourself on every call.  It's pretty handy, you can set it on the BatchClient itself, or on an individual call, below you can see I set it
    on both (just to show you - in a real application usually you would just set it on the batchClient and be done with it -- it would then apply to all operations done by the batch client):
    IBatchClient batchClient = BatchClient.Connect("", new BatchCredentials());
    IRetryPolicy retryPolicy = new LinearRetry(TimeSpan.FromSeconds(5), 6);
    batchClient.CustomBehaviors.Add(new SetRetryPolicy(retryPolicy));
    IWorkItemManager manager = batchClient.OpenWorkItemManager();
    List<ICloudTask> tasksToAdd = new List<ICloudTask>(); //Popualte this with your tasks
    await manager.AddTaskAsync(
    "wiName",
    "jobName",
    tasksToAdd,
    new BatchClientParallelOptions() { MaxDegreeOfParallelism = 15 },
    additionalBehaviors: new List<BatchClientBehavior>() { new SetRetryPolicy(retryPolicy) });
    Also a clarification -- you cannot ever add tasks to a work item.  The method for add tasks happens to live on the "WorkItemManager" which a bit confusingly also manages job related stuff as well (since job is a child of work item). 
    Whenever you are adding tasks, you are always adding tasks to a job, so the "workItemManager" methods related to adding tasks all take job name as a parameter.
    Another issue you may be hitting has to do with .NETs service point manager... see:
    https://msdn.microsoft.com/en-us/library/system.net.servicepointmanager.defaultconnectionlimit%28v=vs.110%29.aspx
    You may want to set this property to be something larger than the default of 2.
    Now, it's possible after making the changes I suggested you still experience some issues -- give these changes a try and if you're still having issues come back and let us know what they are and we can help you improve the submission code further.
    You can also see the sample code for TextSearch which demonstates this in the JobManager task.
    https://code.msdn.microsoft.com/windowsazure/Azure-Batch-Sample-Text-87d08017/sourcecode?fileId=129811&pathId=1120079659
    Hope that helps,
    -Matt

  • Adding attachments to a Parked cuetomer invoice(FBV2)

    Hi,
    I need to attach documents to a customer parked invoice, in short I need to replicate 'Adding Attachments'  functionality in Transaction FBV2.
    Can any1 please guide me how I am unable to find any solution to this problem.
    Cheers
    Abhishek

    You might find this Blog of help:
    /people/rammanohar.tiwari/blog/2005/10/10/generic-object-services-gos--in-background
    Also, search for GOS and Generic Object Services and look through the CL_GOS* classes.
    Jonathan

  • Adding attachments to Web Service call

    Hi
    Does Bea's web service classes include support for adding attachments to the soap message sent by a web service?
    How do I do it? or otherwise, how do I get through the abtraction down to the soap message so I can add it manually?
    I have both a weblogic.webservice.core.rpc.StubImpl and a javax.xml.rpc.Service to work with, I'm guessing it's somewhere deep down in the context of the Service...?

    Hi
    Does Bea's web service classes include support for adding attachments to the soap message sent by a web service?
    How do I do it? or otherwise, how do I get through the abtraction down to the soap message so I can add it manually?
    I have both a weblogic.webservice.core.rpc.StubImpl and a javax.xml.rpc.Service to work with, I'm guessing it's somewhere deep down in the context of the Service...?

  • Adding attachments to an e-mailable form

    I am creating a form that is to be filled out and then
    submitted and sent to an e-mail. I want to make an option available
    of adding attachments to the form being sent to the address but I
    don't know how. Is this something that I will have to do in a .php
    code?

    The type of thing you want is possible, but if it needs to work with Reader the document must be enabled by LiveCycle Reader Extensions so it includes the embedded file usage right.
    The best you can do with a file that's been Reader-enabled with Acrobat is to manually attach a file as a comment. A button can be used to display instructions, but that's it. There is also the licensing restrictions that come into play when you enable with Acrobat.

  • Problems creating an SSIS package: adding a script task causes data at root level is invalid error

    I am trying to create my first SSIS package using SQL 2012 Server Data Tools which will invoke a script task.  I added the script task, put in the code, and when I try to test out the package, I get a "data at the root level is invalid" error
    message.  I tried creating a new project from scratch, did a build and run w/in the IDE (with no code behind), worked ok.  Added the script task (with no code behind), and I get the same error.
    Can someone please point me in the right direction? 

    Are you sure it is not XML?
    How would I repro the issue?
    Please share all the steps, but I think the code has an issue.
    Arthur My Blog

  • Doco/functionality mismatch: Adding a Bounded Task Flow to a Page

    Hi JDev team
    With JDev 11g TP4 and the latest published ADF Guide in hand, under section 14.3 "Adding a Bounded Task Flow to a Page", subsection "To add a bounded task flow containing pages to a JSF page:" it notes that when you drag n drop a bounded task flow from the App Navigator into a JSF page you get the choice of creating a button or link. I don't get this option, instead I can create a region or a dynamic region in the drag n drop submenu.
    Cheers,
    CM.

    Chris,
    note that it says "containing pages", not "containing page fragments". If your taskflow contains page fragments "jsff" then the choice is a region, if it is pages (jspx) then the choice is button or link to launch the taskflow.
    Let me know if this still doesn't work for you
    Frank

  • How to  make adding attachments in the oaf page mandatory  to the user.

    Dear Friends
    I did a attachment section with item style as attachment table,entity map,primary  key concept in my details page
    But  I want to   make this section (adding attachments in the oaf page)  mandatory  to the user.
    Without adding the attchment user should not click SUBMIT.
    [ Just like we give  REQUIRED  property to ant text input fileds  to make entering them mandatory , Is there any property to set ]
    Please share ur ideas .Please help.
    Thanks
    Aravinda

    Gyan's Oracle Application Framework Blog: OAF - Making mandatory Attachement Mandatory
    iWiDi - This is how to make attachments mandatory in iExpense.
    --Sushant

  • Checklist -can a link be added to the task?

    Checklist -can a link be added to the task?
    Question is we have a list created but need to link back to a service or more detailed instruction - can this be done in the checklist item?

    Hello,
    It  looks like you can include HTML in the text of the checklist item.   Simply add the HTML as you would for a standard link.
    <a  href="URL">Click Here</a> for more information on  how to complete your task.
    Cheers!
    PS: I haven't used this  myself (we're on v2004), so I hope it works for you!

  • Authorization for adding attachments only while approving P.O

    Hi
    We work with SRM5 SP14.
    we are intrested in adding an authorization to PO approvers for adding attachments/texts in the "documents" tab in item & header.
    Is this a customizing process or role change?
    Thanks
    Hila

    Anyone???

  • Team Collaboration enhancement: attachments in Tasks

    Hello!
    Why a Team Collaboration does not support attachments in Tasks (create, read) such as in OBEO, Zimbra and Mozilla Sunbird?
    I think this feature would be very useful and convenient for end users.
    Dima.

    Hi,
    senthil's comment is probably no big help, as the worklfow repository where the attachments are stored uses a non ACL-based security manager.
    If you look there
    http://help.sap.com/saphelp_nw2004s/helpdata/en/da/e39b419b6ea109e10000000a155106/frameset.htm
    This security manager gives the users automatically permissions depending on the permissions the user has on the folder where the original object is created.
    For tasks I am actually not quite sure, what is to be done now, as permission on tasks are not good documented. E.g. the eu_role is sufficient to create a task.
    Did you already try giving the user the Collaboration Role?
    Or are you working in a room?
    If you can provide me with the steps you did to create the task and the environment (room template you used or standard roles you have assigned) I maybe can try to repeat it.
    Regards,
    Sascha

  • What's wrong in can't link Attachments to task?

    hi:
    EPM 2010
    I can link attachments to task by using project's Schedule Tools- Link To button. But in Tasks & Project Site, I can't link attachments to task,document,risk,issue. 
    The Custom Commands is ok, I can change link object but after saving nothing changed.
    Is there sth wrong in system or database?

    Hi, have you by any chance break the synchronization of project site issue/risk list?
    Have you rename/delete any of the default existing columns of Issue/Risk lists? You can also verify this from Queue Job, where you can find error that its unable to synchronize.  
    Now if above is valid, just see if you have any project sit with the default columns available, save it as a template and associate it with your EPT.
    Hope this helps.
    Khurram Jamshed - MBA, PMP, MCTS, MCITP (
    Blog, Twitter, Linkedin )
    If you found this post helpful, please “Vote as Helpful”. If it answered your question, please “Mark as Answer”.

  • ICal crashing after adding attachments

    Hi folks,
    Long time user of Mac here.
    Recently, I have done something I have seldom done; adding attachments to my iCal. Some of these attachments are on the large size. iCal is now freezing and crashing to the point where iCal is not usable. I can't remove the files as iCal freezes before I hone in on any one day.
    Help!

    I can no longer launch iCal 2.0.5 from my iMac G4. It crashes within seconds of launch. IPhone iCal application is only one that works. Deleted iCal, think I deleted all the preferences, Re-installed the application and it still crashes. Do I need to upgrade to OS10.5? I use mobileme to sync the calender, but iCal on G4 crashes on sync. Can't remember if this all started with new iPhone (had first generation previously). Have read all issues on this and none relate to my OS.

Maybe you are looking for

  • Testing local is fine, but online is not working

    I made a gallery and tested locally (inside flash mx environment) and it's working great. It can connect the database (my web hosting is mediatemple) with no problem. Sending and receving queries are okay too. But when I upload this file online (swf)

  • Photoshop CS4 slow on my idea centre a600

    Hi. i have with me an IdeaCentre A600, 1gb ram, ati 3560. However, photoshop CS4 is laggy with this desktop. It is fast in loading images and all.. however, cropping is lagging (when highlighting the area i want to crop), adding text etc. any idea ho

  • Displaying Distinct Count as Grand Total

    Hi - I have a requirement where i have to show the distinct count of Transaction Numbers at the bottom of the report as Grand Total. I created a dummy column with Fx as MAX(RCOUNT(1)) and used it in Narrative view and it is showing me the total rowco

  • Transaction variant vs screen variant

    Hi. Created a transaction variant.  The variant has two screen variants. (for VA01).  one for the main screen, and one for the sales overview screen. If I click test for the screen variant, it is working fine as expected. But if I click the test for

  • Remove Blank Page conditionally in Smartforms

    Hi  Experts this is Arun, I have Requirement in such a way that, Form should contain three different pages which display three different records using three different internal tables.My problem is I have to avoid second and third page if it does not