Can document links be added via scripting?

Can we add document links through scripting on Master Agreement header page? We are trying to mass update document links for about 3000+ records and hence I need to create a script (one time task) that can add these values on MA header page.
I am trying to create the document link defintion as follows:
DocumentLinkDefinitionIBeanIfc dld = (DocumentLinkDefinitionIBeanIfc)
TypeFactory.createObjectReference(620);
dld.setDisplayName("Test");
dld.setInternalName("Test");
dld.setLinkClassId(509);
dls.setSystemDefined(new
Boolean(false));
dld.setLinkDirectionType(new DocLinkDirectionTypeEnumType(3));
dld.setLinkDefinitionType(new DocLinkDefinitionTypeEnumType(3));
and then set this document link defintion to Document Link Bean as follows:
DocumentLinkIBeanIfc dl = (DocumentLinkIBeanIfc)
TypeFactory.createObjectReference(509);
dl.setExtRefDoc("99999");
dl.setExtRefLine("900");
dl.setLinkDefinitionObjRef(dld);
But this is giving me error.
Let me know if I am doing something wrong.
Any help will be appreciated.
-Regards,
Bindu Sharma

Hi,
I create the document link definition between two agreements (variables doc and otherAgreement) using this code:
documentLinkDef = documentLinkDefHome.findUnique("FCI-CONTRACT RELATED");
newDocLink = doc.documentLinkList.create();
newDocLink.linkDefinitionType = new DocLinkDefinitionTypeEnumType(1);
newDocLink.linkDefinitionObjRef = documentLinkDef.objectReference;
newDocLink.LinkDocObjRef = otherAgreement.objectReference;
doc.documentLinkList.add(newDocLink);
Hope this is helpful
Francisco

Similar Messages

  • 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!

  • How can I link two frames via a button on one of the frame?help Plz

    Ok,here is the problem. I got two fully working java frames,each has different funcion. On one of the frames(my home Frame" Frame 1" ) i got a button called "Add User", when i press it i should then get my other frame(Frame2) to popup/run. in Frame1 i got this code as action for the add user button.Note: each Frame have thier own Main class.
    public void actionPerformed (ActionEvent e)
    if (e.getSource()==jbtnAddUser)
    // new Frame2(this,"hshsh",jb);
    ////////////// The commented line is where i am not sure what to put in there, Frame1 is the name of my Frame 2 class......
    Please could anyone tell me how do i link Frame 2 to Frame 1....i appreciate it....Max

    You can create both together on pgm startup (instaniation of the class).
    Next for frame1 - I'll call it - you can setBounds(int, int, int, int) and setVisible(true); When you press the button on frame1 to get frame2, you can then do frame1.hide(), followed by frame2 setBounds and setVisible. Finally, when you are done with frame2 you can do frame2.dispose() and frame1.show(). try that.

  • [JS] Menu Added via Scripting Moves

    I've been able to sucessfully add items to the InDesign menu thanks in part to Marijan Tompa's (tomaxxi) blog post http://indisnip.wordpress.com/2010/08/08/create-customized-menu/
    My test code (below) creates a new menu, and sucessfully adds two menu items plus a submenu. The submenu is causing me problems. When you first launch InDesign it's created in the proper place (in the middle of the menu). But when you relaunch InDesign, the submenu moves to the top of the menu and never goes back to it's proper position farther down in the menu where it was the first time InDesign was launched.
    I've searched high and low in this forum, the web and InDesign's documentation and can't figure out how to keep it from moving (I want the menu to be farther down the menu, not at the top). I hope one of you kind souls will help me to control the position of the submenu (and have it stay there across launches).
    Thanks in advance!
    Dan
    Here's the code I'm working with. This is saved as testMenu.jsx in the Scripts > startup scripts folder.
    P.S. I'm testing this in CS5.5 currently, but ideally this solution should work in CS3 and later.
    #targetengine "myTestMenu"
    var myFolder = Folder(app.activeScript.path);
    myFolder = myFolder.parent + '/Scripts Panel/';
    var menuItem1Handler = function( /*onInvoke*/ ){
      app.doScript(File(myFolder + 'MyTest1.jsx'));
    var menuItem2Handler = function( /*onInvoke*/ ){
      app.doScript(File(myFolder + 'MyTest2.jsx'));
    menuInstaller()
    function menuInstaller() {
      var menuItem1T = "My Menu Item 1",
           menuItem2T = "My Menu Item 2",
           menuT = "MyTestMenu",
                 subT = "Sub Menu",
           subs = app.menus.item("$ID/Main").submenus, sma, mnu;
      var refItem = app.menus.item("$ID/Main").submenus.item("$ID/&Layout");
      subMenu1 = app.scriptMenuActions.item(menuItem1T);
      if( subMenu1 == null ) {
              subMenu2 = app.scriptMenuActions.add(menuItem1T);
      subMenu2 = app.scriptMenuActions.item(menuItem2T);
      if( subMenu2 == null ) {
              subMenu2 = app.scriptMenuActions.add(menuItem2T);
      subMenu2.eventListeners.add("onInvoke", menuItem2Handler);
      mnu = subs.item(menuT);
      if( mnu == null ) {
                mnu = subs.add(menuT, LocationOptions.after, refItem);
      mnu.menuItems.add(subMenu1);
      mnu.menuSeparators.add();
      subsSubs = app.menus.item( '$ID/Main' ).submenus.item( menuT ).submenus;
      mnuSubMenu = subsSubs.item( subT );
      if( mnuSubMenu == null ) {
              mnuSubMenu = subsSubs.add( subT);
      mnu.menuItems.add(subMenu2);

    Hey, Marc: I'm going to be sort of blunt. Your code is hard for most people to read because it uses Javascript idioms they are entirely unfamiliar with, which don't make a lot of sense to people not really familiar with the language. And that's what most people here are. Let's take a walk through it:
    (function(/*obj|undefined*/HOST)
    The comment itself is confusing. Actually, it's even confusing to me.
        HOST || (HOST=$.global);
    Tbe || idiom is confusing. Most people don't know what it means offhand.
        // Prevent the current (startup) script from being uselessly rerun
        if( HOST[$.engineName] )
            alert( "This script is automatically executed at startup. You shouldn't run it manually." );
    Well, this isn't confusing, but I think it's bad. One of the important things to do is to test what happens when the menus already exist, and that's easiest to do by rerunning the script.
        var MENU_NAME = "My Test Menu",
    All caps for a function-local variable? Even using all caps for a globally scoped variable (Crockford) is confusing, but for a function-scope variable? That confuses me!
            FEATURES = [
                { caption: "My Menu Item 1", fileName: 'File-One.jsx', subName: "" },
    Use of Objects is justified here, but they are probably confusing.
            FEATURE_LOCATION_PATH = (function()
    Anonymous functions...definitely confusing! I'm also not sure what the point of this function heere is. Why not execute the code directly
    on the next line?
                try{ f=app.activeScript; }
                catch(_){ f=File(_.fileName); }
    Variables named "_"? Confusing!
    And this is why anonymous functions are confusing! Not much to be done about it, but why use one where you don't need to. It's not like we're polluting the global namespace here.
        while( i-- )
    Use of a while loop is a totally legitimate style choice, but I think it's typically less readable than a for loop. YMMV, of course!
            t = FEATURES[i];
    I'm horribly guilty of this, but single-letter variable names are not the most readable.
                (t.action = app.scriptMenuActions.add( t.caption )).
                    addEventListener('onInvoke', f);
    More parentheses imply more mental gymnastics to understand. Breaking this into two lines,
    with t.action=addEventListener... would help readability.
      var s,
            n = FEATURES.length,
            subs = {},
            sub = null;
    Wait, a mid-function var block? Gasp! What's up with that? Crockford's right on this. One var statement and all at the top.
    I am not sure why we're initializing sub to null -- what's wrong with the good old undefined? This probably doesn't qualify as confusing.
        for( i=0 ; i < n ; ++i )
    Caching FEATURES.length in n is good for performance, but it probably doesn't matter here, and makes it more confusing to read. Not by much, but let's say half a confusion point. I would also say that "++i" is harder to read than "i++", maybe to the tune of 0.1 confusion-points, but maybe that's just me. YMMV Extremely.
            sub = (s=t.subName) ?
                ( subs[s] || (subs[s]=mnu.submenus.add( s, LO_END )) ) :
                mnu;
    The ternary conditional operator, ?:, is pretty much always hard to read. And it's worse with short-circuit or-ing, ||, or three close-parens in rapid succession. Of course ?: tends to promote extra () as it almost always becomes ()?(): so...
    And then it's worth re-emphasizing, basically nobody understands the anonymous function paradigm .
    So there we have it, that's why I think your code is confusing to most readers.
    (On the other hand Dan's final code ignores my recommendation and still has those abysmal ==null tests in there. What's up with that? )

  • Set firefox to open pdf documents in adobe reader via script or GPO

    I am trying to change the settings of 400+ Windows 7 PCs with 2-10 users per PC. They all use Firefox and Adobe Reader XI. I would like to know how to use the Mozilla Administrative Template or how to create a GPO to change the default pdf viewer in Firefox to Reader XI. i need a way to be able to configure it so when a user logs into the PC via our domain login Firefox will be automatically configured to open PDF's from Firefox in an Adobe Reader window, otherwise we have to manually configure it and that gets very frustrating after the 2nd PC

    From: Test Screen Name [email protected]
    Sent: Sunday, August 04, 2013 11:32 AM
    To: gunner0490
    Subject: I'm not able to open PDF files in Adobe Reader XI.
    Re: I'm not able to open PDF files in Adobe Reader XI.
    created by Test Screen Name <http://forums.adobe.com/people/TestScreenName>  in Adobe Reader - View the full discussion <http://forums.adobe.com/message/5565198#5565198

  • Can I link 2 computers via Airport & access each others drives

    Hi,
    I have the following HW.....
    - PBook G4
    - PowerMac G4
    - Graphite Airport Base Station (connected to modem for internet access)
    Both cpu's subsequently access internet wirelessly as both have Airport cards built in)
    I would like to know if it is possible that I can access the Powermac drive from the PB over the wireless network. I wanna be able to drop to & pull data from one to the other accordingly.
    Is this (easliy) possible?
    Thanks
    jiggy44

    jiggy44, Welcome to the discussion area!
    I would like to know if it is possible that I can access the Powermac drive from the PB over the wireless network.
    Yes. Its just like using Ethernet. On the Power Mac, open the Sharing preference pane and enable File Sharing. That will allow the PowerMac to be visible to the PowerBook. More information can be found in KB 106461, Mac OS X: About File Sharing.

  • Can you give a document link for script logic for NW version7??

    Hi all,
        who can give a document link for script logic for nw version7??
        thanks in advance!!

    Hi Sheldon,
    I read through your "HOW to...Custom BADI for replicating Destination_App...." and it was great. However, Can this call also be used with WHEN/ENDWHEN statements? In the MS version, when using Destination_App, I was also able to map source accounts into the correct destination accounts as well as source E type dim to desination E type dim with the following script (the mapping to destination ID was stored as properties within the source dimensions).
    *INCLUDE SYSTEM_CONSTANTS.LGL     
    *SELECT(%OPACCT%, "[ID]", "OPACCOUNT", " [TRF_FPA] = 'Y'")
    *SKIP_DIM = COSTCTR
    *ADD_DIM = BRANDS
    *RENAME_DIM OPAccount = Account_F
    *RENAME_DIM CATEGORY = CATEGORY_F
    *RENAME_DIM ENTITY = MARKET
    *RENAME_DIM DATASRC = DATATYPE
    *XDIM_MEMBERSET ENTITY = %ENTITY_SET%
    *XDIM_MEMBERSET CATEGORY = %CATEGORY_SET%
    *XDIM_MEMBERSET TIME = %TIME_SET%     
    *XDIM_MEMBERSET OPACCOUNT = %OPACCT%
    *DESTINATION_APP = FPA
    *CLEAR_DESTINATION
    *DESTINATION OPACCOUNT = %OPACCT%
    *DESTINATION TIME = %TIME_SET%
    *DESTINATION CATEGORY = %CATEGORY_SET%
    *DESTINATION CURRENCY = LC,USD
    *WHEN ENTITY
    *IS %ENTITY_SET%
    *REC(ENTITY=COSTCTR.FPA_MKT,OPAccount=OPAccount.Consol_FPA)     
    *ENDWHEN     
    *COMMIT
    I have tried the following code in the NW version, and it won't validate. Do you know if there's a way to achieve this?
    *XDIM_MEMBERSET CATEGORY<>ACTUAL
    *XDIM_MEMBERSET ACCOUNTHR =BASE_ANNL_SAL,BONUS,BENEFITS_TAX
    *XDIM_MEMBERSET CURRENCY=LC
    *START_BADI DAPP
    DESTINATION_APP=CC_PLAN
    RENAME_DIM="ACCOUNTHR=ACCOUNTCC"
    WRITE=OFF
    *END_BADI
    *WHEN ACCOUNTHR
    *IS "BASE_ANNL_SAL","BONUS","BENEFITS_TAX"
    *REC(ACCOUNTCC=ACCOUNTHR.CCPLANACCT)     
    *ENDWHEN
    Regards,
    Karen

  • How do I enable a Java plug-in via script that was just added to the blocklist?

    I need to enable Java 6u29 that was just added to the blocklist via script because there are several thousand end-nodes involved. Also, I am constrained to Firefox 3.6 due application compatibility issues.

    Probably the only or easiest way to remove or disable the blocklist of older Java versions would be to disable blocklisting by locking the extensions.blocklist.enabled to false via a mozilla.cfg file.<br />
    You are already running a no longer supported Firefox 3.6.x version that won't receive updates.
    You can use a mozilla.cfg file in the Firefox program folder to lock prefs or specify new (default) values.
    Place a file local-settings.js in the defaults\pref folder where you also find the file channel-prefs.js to specify using mozilla.cfg.
    pref("general.config.filename", "mozilla.cfg");
    pref("general.config.obscure_value", 0); // use this to disable the byte-shift
    See:
    *http://kb.mozillazine.org/Locking_preferences
    You can use these functions in mozilla.cfg:
    defaultPref(); // set new default value
    pref(); // set pref, but allow changes in current session
    lockPref(); // lock pref, disallow changes
    lockPref("extensions.blocklist.enabled", false);
    *http://kb.mozillazine.org/extensions.blocklist.enabled

  • Webi - Pass Hierarchy Filter via Document Link

    Hi
    I am creating WEBI reports on BO 4.0 SP2 patch 8.
    I want to pass the parameters from Webi report 1 via document link to Webi report 2.
    Within report 1 you can filter the data by the following:
    Parameter 1: Customer
    Parameter  2: Calender Month
    Parameter 3: Profit center Hierarchy
    Parameter 1 & 2 work perfectly the selected customer and month passes to report 2.
    However Parameter 3: hierarchy is giving me hassles.
    I enter the Hierarchy into the document prompt text and key in editing the document link.
    On selecting the hyperlink I get the error message:
    " Invalid answer 0HIER [ ] for variable ZPCTR_GRP error message WIS 00013."
    Has anybody been able to pass a filtered Hierarchy via Document Links on BO 4.0?
    Regards
    Graham

    Hi,
    I haven't seen this particular issue come through support.
    the warning seems to suggest that an invalid selection has been made, however the brackets [ ]  show nothing!  So perhaps the string's been provided in the wrong format, or text is being returned when infact it needs key. (i'm speculating)
    a few questions to begin:
    - Are you passing a hiearchy interval as a range  parameter ?  (i.e. 2 or more nodes/members from different levels in the hierarchy)
    - Do you notice a difference when using the other viewer technology: DHTML (WEB) vs JAVA (Rich) ?
    It might be worth using the TraceLog service on the webi processing server and DSL_bridge (APS) to capture your workflow, and get more details error messaging.  Also, RSTT trace in BW may catch something of interest.
    Good luck
    Regards,
    H

  • Adding Document Link

    I am trying to insert a shortcut 'Add DocumentLink' like 'Add Document' inside a document library (just replacing upload.aspx with newlink.aspx (id=idHomePageNewLink) it brings up the first form to upload the Document URL & Title when click on OK gives
    error message. We have created views in library with filters to show only specific documents to control access; from any view when they use 'Document Link' from ribbon it always lands up in a different view. please let me know how i can add shortcut link

    Hi M Raki,
    You seems to add custom action in the Ribbon to replace the upload document function.
    You can create custom action using CustomAction element in CAML, the following sample shows how to do this. And to achieve the upload function, if you don’t want to use default upload page, custom a layout upload page to achieve the upload, then redirect
    to the default list view page.
    Add Custom Button to the SharePoint 2010 Ribbon:
    http://blogs.msdn.com/b/jfrost/archive/2009/11/06/adding-custom-button-to-the-sharepoint-2010-ribbon.aspx
    Thanks,
    Qiao Wei
    TechNet Community Support

  • HT2506 In pages how can I link text within the document? I can find a bookmark option and links only allows me to link to a web page

    Hi all,
    This is my first time using this discussion site! Any help would be great, as I am getting very frustrated with pages!
    What I am trying to do is link text at the bottom of a document to a page at the beginning of the document. I can't find a bookmark option adn when I clink insert link it only provides an options to link to a web page. Help! thanks

    Bookmarks are missing (sadly) and with them, the ability to create an in document link.
    I was looking for this feature in a Table of Contents. When you assign a 'style' to text in a document, you can Insert > Table of Contents. Then Pages will keep the TOC updated and you'll be able to 'link' from the page number in the TOC. (Not much help though, for the OP)

  • How to find a text in the Frame maker document via script?

    How to find a particular text in the Frame maker document via script?

    johnsyns wrote:
    Why it doesn't work for the other days? When i tried to change the days other than wednesday. it return nothing.
    Reason why Justin's code does not work for other days is date format mask DAY returns day blank padded to 9 characters which is the longest day name which, yes you guessed right, is WEDNESDAY. You either need to blank pad or use format modifier FM:
    SQL> select *
      2    from (SELECT TO_DATE(SYSDATE+ROWNUM, 'DD-MON-YY') dt
      3            FROM DUAL CONNECT BY ROWNUM <= 27)
      4  WHERE TO_CHAR(dt,'DAY') = 'TUESDAY'
      5  /
    no rows selected
    SQL> select *
      2    from (SELECT TO_DATE(SYSDATE+ROWNUM, 'DD-MON-YY') dt
      3            FROM DUAL CONNECT BY ROWNUM <= 27)
      4  WHERE TO_CHAR(dt,'DAY') = 'TUESDAY  '
      5  /
    DT
    07-APR-09
    14-APR-09
    21-APR-09
    28-APR-09
    SQL> select *
      2    from (SELECT TO_DATE(SYSDATE+ROWNUM, 'DD-MON-YY') dt
      3            FROM DUAL CONNECT BY ROWNUM <= 27)
      4  WHERE TO_CHAR(dt,'FMDAY') = 'TUESDAY'
      5  /
    DT
    07-APR-09
    14-APR-09
    21-APR-09
    28-APR-09
    SQL> SY.

  • Can't open web links in emails via Safari 6.1.6

    Hello...
    I'm working on a Macpro computer with OSX 10.7.5.
    In Safari 6.1.6 I can't open ANY links that are in emails.  Links to other web sites, links to file via you send it, nothing.  I've disabled the block "pop ups" tab in preferences and still nothing.  I don't want to upgrade to the new OSX, as everything else on my computer is running fine.
    Can someone tell me what to do to get this working again….

    I encountered the same problem.  In my case, the culprit was a plug-in in the Internet Plug-Ins sub-folder of my User Account's Library folder.
    Here's how I proceeded, based on a suggestion by Carolyn Samit here:
    <https://discussions.apple.com/thread/5117605?start=0&tstart=0>
    1. Open the Finder.
    2. In the Finder menu bar, click on the heading Go.  Scroll down to "Go to Folder," and then click the mouse button again.
    3. Copy the following phrase:
    /Library/Internet Plug-Ins
    and then paste that phrase into the field in the navigation window that appeared at the end of Step 2.
    3. Click Go.
    4.  If you find a plug-in named AdobePDFViewer.plugin, drag it to the Trash.
    5. Quit and then relaunch Safari.  Then try to load in Safari a PDF from a web site.  Then try saving it.  Once saved/downloaded, try opening the PDF.
    When I followed this procedure, the corrupted-PDF problem went away, thanks to Ms. Samit's suggestion.

  • UDF in documents lines that can be Change after adding the doc.

    Dear all
    How can i create a UDF in documents lines that can be change after adding the doc? He need to mark some of the lines to already audit or not audit and the date of the action.
    Kind Regards
    Margarida

    It also depends on what documents you are wanting to add these comments to. On documents such as the A/R Invoice/ Delivery, and A/P Invoice/ Goods Receipt PO you cannot change the UDFs on the line item after the document is added (regardless of whether the document is closed). Sales Orders/ Quotes and Purchase Orders line item UDFs can be changed as long as the line hasn't been closed (or partially received/delivered/invoiced).
    Hopefully that makes sense. I could give more of an explanation if I knew what documents you were wanting to add these line item comments to.

  • Can i do Expression to keyframes and smooth via script?

    hi guys, who know AE scripts can translate expression to linear keyframes via script(now i use app.executeCommand(app.findMenuCommandId("Convert Expression to Keyframes")) ; command) but , for Comman work i must select every time property of layer(opacity, position, scale, etc) where i have expression.... but i need translate very many layers, i always click on property with expression and then do Convert Expression to Keyframes its to long.., can i do something like this
    for (var j= 0; j<selectedLayers.length; j++) 
                       var SelLaye= selectedLayers[j];                  
                       if (SelLayer.transform.opacity.expression!=null && (SelLayer.transform.opacity.expression!=null) && (SelLayer.transform.opacity.expression!=null)) //check if layer have expression
                             SelLayer.transform.position.select=true;  //and here i need set cursor to position, expression, etc, where i have expression and translate to linear kayframes(but i dont know how)
                             app.executeCommand(app.findMenuCommandId("Convert Expression to Keyframes")) //do translation
                             SelLayer.transform.rotation.select=true;
                             app.executeCommand(app.findMenuCommandId("Convert Expression to Keyframes")) 
                             SelLayer.transform.scale.select=true;
                             app.executeCommand(app.findMenuCommandId("Convert Expression to Keyframes"))
                             //and after this also need do a smoother or something like this for decreasing linear keys for max(because app.executeCommand(app.findMenuCommandId("Convert Expression to Keyframes")) create to many keyframes)
    sorry for bad English

    Sup,
    Earlier Dan Ebberts already wrote the answer on CreativeCow:
    http://forums.creativecow.net/thread/227/13039#13041
    Можно все выбранные значения добавить в массив и потом уже дергать из оттуда, ну либо вручную прописывать в скрипте. Кому как больше нравится.
    AE has "Smoother" panel, but as far as I know you can`t access it via scripting using app.executeCommand(app.findMenuCommandId("Smoother")) or something.
    But there is a script that makes same work , called Smart Baker. You can download it here:
    http://www.creatogether.com/ctg-smart-baker

Maybe you are looking for

  • .PDF Files blurred in InDesign CC 2014. They will still work if I try to do the same in InDesign CC

    .PDF Files blurred in InDesign CC 2014. They will still work if I try to do the same in InDesign CC. I prepare the original in microsoft word and save in a sub-directory as a .pdf. I then use the "Place" command to bring it into the document. Why doe

  • JMS-204: An error occurred in the AQ JNI layer

    Approach 1) works fine but not 2). Approach 1 ================= // Use the DriverManager to get the DB Connection DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver()); java.sql.Connection dbConnection = DriverManager.getConnection("the

  • TS1702 ICloud backup box

    On my screen I have a box that I cannot remove or get in to my IPad. The box states that I have not backed up in 2 weeks and that the back up occurs when the unit is plugged in and locked and connected to Wi-Fi well it is plugged in and it still will

  • Conditionally Show and Hide Input Text

    JDev 11.1.1.5.0 I have two input texts PROFILE and SCORE. SCORE is shown only if my value in PROFILE is E or F. And if, it should be hidden once the PROFILE value is changed to some other value. Also, please note SCORE field should be mandatory if th

  • My itunes store will not open after IOS7 update on my 4s?

    I updated my phone to IOS7 and my itunes store initially worked after this update. However it has now stopped working and it opens then turns to a white screen and closes its self within seconds. Is there anyway of fixing this without resetting my wh