Is it possible to add a line attribute?

Hello

I need a add a new attribute to a table row, but I can't find a way to do it. I already added some attributes to the document and page elements by adding a new persistent interface to kDocBoss and kSplineItemBoss respectively and it management in the provider. For text attributes, I added a new boss and he succeeded in the provider thanks to:

/ * Text attribute script providers must use the TextAttrScriptUtility

class to access and modify text attributes.  This provider shows

How to use this utility.  Suppliers third text attribute script should

Follow this same pattern.

*/

scoped_ptr < TextAttrScriptUtility > tasu.

I can't use TextAttrScriptUtility for lines and seems it isn't a boss for a line that I can use to add a new interface, like I did for document elements and page. In addition the IScript object * I get in the method AccessProperty is a kScriptCellRefBoss without database (: GetUIDRef gives me an empty object).
Is it possible to add an attribute of row with the SDK?

I use SDK 9.0/10/11/11.2

Thanks in advance

Massimo

I have foiund the solution on my own using ITableCommands and ItableAttrAccessor, I put a sample of the script provider if someone will have the same question:

ErrorCode PBTaggerIDMLRowScriptProvider::AccessProperty_PBCycleAttr(IScriptRequestData* data, IScript* script)

{

Result ErrorCode = kSuccess;

{}

InterfacePtr cellRef (script, UseDefaultIID());

GridArea grid;

cellRef-> GetRange (grid);

RowRange range = grid. GetRows();

InterfacePtr tableModel (cellRef-> QueryModel());

If (data-> {IsPropertyGet())}

Download

ScriptData outData;

InterfacePtr tableAcc (tableModel, UseDefaultIID());

DataWrapper listA = tableAcc-> QueryRowOverrides (start);

const AttributeBossList * list = listA.get ();

InterfacePtr attr (static_cast< const="" ipbtaggerrowattrcycle*="">(list of-> QueryByClassID (kPBTaggerRowAttrCycleBoss, IPBTaggerRowAttrCycle::kDefaultIID)));)))

If (! attr)

break;

WideString cycle = attr-> Get();

outData.SetWideString (cycle);

data-> AppendReturnData (script, p_PBTaggerCycleRowData, outData);

}

else {}

PUT

ScriptData scriptData;

If (data-> {HasRequestData (p_PBTaggerCycleRowData))}

result = data-> ExtractRequestData (p_PBTaggerCycleRowData, scriptData);

WideString cycle;

result = scriptData.GetWideString (cycle);

Assert(result == kSuccess);

If (result! = kSuccess)

break;

InterfacePtr attr (: CreateObject2< ipbtaggerrowattrcycle="">(kPBTaggerRowAttrCycleBoss));

Assert (attr);

attr-> Set (cycle);

InterfacePtr tableMod (tableModel, UseDefaultIID());

List of AttributeBossList;

list. ApplyAttribute (attr, kPBTaggerRowAttrCycleBoss);

const AttributeBossList * list_const = &list;

tableMod-> ApplyRowOverrides (range, list_const);

}

}

} While (kFalse);

return the result;

}

Tags: InDesign

Similar Questions

  • is [8i] possible to add a line number that increases after a column?

    I have the following the sample table and data:
    CREATE TABLE ords
    (     ord_nbr          NUMBER     NOT NULL
    ,     step_nbr     NUMBER
    ,     area_code     VARCHAR2(2)
         CONSTRAINT caln_pk PRIMARY KEY (ord_nbr)
    );
    
    INSERT INTO     ords
    VALUES (1,1,'A1');
    INSERT INTO     ords
    VALUES (1,2,'B1');
    INSERT INTO     ords
    VALUES (1,3,'B1');
    INSERT INTO     ords
    VALUES (1,4,'B2');
    INSERT INTO     ords
    VALUES (1,5,'A1');
    INSERT INTO     ords
    VALUES (1,6,'C1');
    INSERT INTO     ords
    VALUES (1,7,'X1');
    INSERT INTO     ords
    VALUES (1,8,'C2');
    INSERT INTO     ords
    VALUES (1,9,'C2');
    INSERT INTO     ords
    VALUES (1,10,'Z9');
    The results that I want to look like:
    ORD_NBR     STEP_NBR     AREA_CODE     SEQ_NBR
    -----------------------------------------------
    1     1          A1          1
    1     2          B1          2
    1     3          B1          2
    1     4          B2          3
    1     5          A1          4
    1     6          C1          5
    1     7          X1          6
    1     8          C2          7
    1     9          C2          7
    1     10          Z9          8
    I want only the SEQ_NBR to increase if the area changes... I wonder if there is that I need to transform that into a hierarchical sort query, so that there is a relationship between step 1 and step 2, step 2 and step 3, etc.

    I played a bit with ROW_NUMBER, RANK, DENSE_RANK, but I can't understand how to add this column SEQ_NBR...

    Any suggestions?

    Hello

    That's what you asked for:

    SELECT     ord_nbr, step_nbr, area_code
    ,     SUM (new_grp) OVER ( PARTITION BY  ord_nbr
                                  ORDER BY          step_nbr
                      ) AS seq_nbr
    FROM     (
             SELECT  ord_nbr, step_nbr, area_code
             ,         CASE
                    WHEN  area_code = LAG (area_code) OVER ( PARTITION BY  ord_nbr
                                                               ORDER BY       step_nbr
                                            )
                    THEN  0
                    ELSE  1
                      END          AS new_grp
             FROM    ords
         )
    ORDER BY  ord_nbr
    ,            step_nbr
    ;
    

    I'm guessing what role ord_nbr plays in this problem.

    user11033437 wrote:
    I have the following the sample table and data:

    CREATE TABLE ords
    (     ord_nbr          NUMBER     NOT NULL
    ,     step_nbr     NUMBER
    ,     area_code     VARCHAR2(2)
         CONSTRAINT caln_pk PRIMARY KEY (ord_nbr)
    );
    

    Part of your constraint PRIMARY KEY be lost? It seems that ord_nbr is not separate, so it cannot be a primary key by itself.

    ... I wonder if there is that I need to transform that into a hierarchical sort query, so that there is a relationship between step 1 and step 2, step 2 and step 3, etc.

    I played a bit with ROW_NUMBER, RANK, DENSE_RANK, but I can't understand how to add this column SEQ_NBR...

    You have some very good instincts!
    I think you could do this as a CONNECT BY query, but I don't think it would be any easier or more effective. It is good to keep CONNECT BY in mind and recognize that CONNECT BY is a possible solution for this kind of problem.
    Of course, this looks like a problem DENSE_RANK. That's what I have trid first, but I couldn't find a solution more simple than the one above.

    Thanks for posting the CREATE TABLE and INSERT. It is very useful.
    If you are using Oracle 8.1, it is very important. You must mention your version in the message body and not just hope that someone notice "8i" in the line object or tags.

    Published by: Frank Kulash, February 18, 2010 14:22

  • Possible to add the line to OBIEE answers

    Hello
    I have a dimension D1, F1,

    D1 F1
    A 10
    B 20
    c 30
    When I'm generating a report in fact I get three rows and, I have to get 4th place as d = b + c output as follows,

    D1 F1
    A 10
    B 20
    c 30
    -----------------
    d 50

    is it possible to OBIEE answers?

    Thanks in advance?

    Published by: Maya on January 9, 2012 21:24

    Yes... Pivot of use see point calculated to calculate B + C

  • Add bus lines?

    Hello

    I was wondering if it is possible to add buses lines (with verification by Apple of course) as public transport network which has 22 lines around my town, but the Maps app informs he...

    Sincerely

    Hello

    It is a community of user-oriented support.

    If you want to send a feature request to Apple, you can do it here:

    https://www.Apple.com/feedback/iPhone.html

  • How to set the default value of the attribute with a sequence number? Is it possible to add a string to seq.no. like abc0001?

    Mr President.

    How to set the default value of the attribute with a sequence number? Is it possible to add a string to seq.no. like abc0001?

    Concerning

    For the date, you can use groovy expression adf.currentDate to set the current date. reference http://adfgouravtkiet.blogspot.in/2012/11/how-to-set-default-values-for-entity.html

    You already have ways to use the sequence.

    How do you add a new value in the form. You're creating a new line of your page (user interface) and by engaging with validation operation? Unless you commit you will not be able to see anything in the table.

    Thank you

  • V9 Acrobat JavaScript Alert Box - possible to add space or line break after each element of the array?

    I have a Document level Javascript used to identify empty mandatory fields and fires on shares of paper, print and save. The script identifies the required fields empty, counties and outputs of an alert box indicating the number of required fields empty and lists the name of the ToolTip fields. The script identifies the required fields with an asterisk at the end of each balloon.

    Is my question possible to add a space or a line break after the decimal point for each item?

    Here is a picture of the exit where the items listed are all grouped together.

    Alert box array items need space or line break.jpg

    Here is the code:

    function validateFields()

    {

    a counter for the number of empty fields

    var = 0 flg

    count all the fields of the form

    var n = this.numFields

    create a table to contain the names of the required fields

    If they are determined to be empty

    fArr var = new Array();

    Browse all fields and look for ones that are required

    all fields that have a ' *' in their ToolTip are required

    for (var i = 0; i < n; i ++) {}

    var fn = this.getNthFieldName (i);

    var f = this.getField (fn);

    ToolTip is the property of 'userName' of the fields\;

    TT = f.userName var

    test the ' *';

    If (TT. IndexOf('*')

    ! =-1 & & f.value == f.defaultValue) {}

    increment the counter of empty fields;

    FLG ++;

    Add the fields username (ToolTip) to the list of the names of fields empty.

    fArr [fArr.length] = tt;

    }

    }

    now display a message if there are blank fields

    if(FLG>0) {}

    App.Alert ("there are '+ flg + areas that require a value\n\n' + fArr, 3")

    }

    else {}

    This.Print ();

    }

    }

    The required property is very easy to use. It's just a Boolean (true/false) value, then you can use it like this in your code. Instead of this line:

    If (tt.indexOf('*')! =-1 & f.value == f.defaultValue) {}

    Use this:

    If (f.required == true & f.value == f.defaultValue) {}

  • Is it possible to add the name to the subject line when you submit a pdf form

    Hello

    I created a form with Live Cycle and add a button which form submittingthe in PDF format. I was wondering is it possible to add the name to the subject line just after Hank, as seen in the image below?

    Concerning

    submittab.jpg

    It is easy enough to accomplish your needs using scripts on a regular button rather than the button send email.

    Look at this amazing example created by Paul who explains a number of ways to present data in form by e-mail.

    http://forums.Adobe.com/message/2109208#2109208

    Nith

  • Possibility to add arrowheads to a line in AE?

    Hello

    I have a shape with a line layer. Is it possible to add arrowheads at each end of this line in AE?

    Add a shape of polygon with 3 sides and move it into place. You know, you can have infinitely many points and groups in a shape layer.

    Mylenium

  • &lt; xsl: attribute name = "break-before" &gt; page &lt; / xsl: attribute &gt;-add blank lines

    Hello.
    < xsl: attribute name = "break-before" > page < / xsl: attribute >-add blank lines.
    When to transfer the lines to the next page with the command
    < xsl: attribute name = "break-before" > page < / xsl: attribute >, a new page at the beginning of a blank line, then the data. And so on all pages. If < xsl: attribute name = "break-before" > page < / xsl: attribute > removed, the XML Editor displays all the lines correctly.

    I can send RTF and XML files.

    Does anyone know how can I solve this problem?
    Thank you

    Send me the xml files and the [email protected] model. I'll take a look. Also, can you clarify your needs and deliver a little clearer in your email?

    Thank you!

  • tabular: Add the line: line does not get inserted

    Hi all

    I have a tabular presentation based on a products table, quantity, unit_price and product_id columns

    in the form of Tha also has a calculated field price (unit_price * amount) and a total on the price column

    When the user changes unit_price or quantity, the price is calculated together total whith, this is done using javascript

    I want to accomplish is add when you click line, and then the total row of the report should remain the last row

    I managed to do it, but when I add a line and then fill in the same row is ignored by apex, 0 rows inserted

    This is because when you change a field in the hidden input field fcud_xxxx does not change to would be "to 'C'

    How can I fix this, I have to write a change event for each column?

    any other ideas?

    I put the code on apex.oracle.com

    workspace: martijnke

    login/password: demo/demo

    application: 78396: apex advance

    Start the application and click orders, and then click on any order to go to the edit page 4 control elements

    Click Add line and see what happens

    the javascript code is on page 4, the function is called switch_last_row()

    I found this in widget.tabular.js:

       // Register change handler on new row form fields, change "fcud_*" hidden element to C if a change occurs
            lNewRowIndex = tabular.pad( ( tabular.gNumRows + tabular.gNewRows ), 4 );
            $( ":input[id^=f][id$=_" + lNewRowIndex + "]", apex.gPageContext$ ).change( function() {
                $( "#fcud_" + lNewRowIndex, apex.gPageContext$).val( "C" );
            });
    

    Why change this event not working for my vacuum dial-up?

    DB: 11 GR 2

    Apex 5.0.2

    KR

    Martin

    Martijnke wrote:

    I have a tabular presentation based on a products table, quantity, unit_price and product_id columns

    in the form of Tha also has a calculated field price (unit_price * amount) and a total on the price column

    When the user changes unit_price or quantity, the price is calculated together total whith, this is done using javascript

    I want to accomplish is add when you click line, and then the total row of the report should remain the last row

    I managed to do it, but when I add a line and then fill in the same row is ignored by apex, 0 rows inserted

    This is because when you change a field in the hidden input field fcud_xxxx does not change to would be "to 'C'

    How can I fix this, I have to write a change event for each column?

    any other ideas?

    I put the code on apex.oracle.com

    workspace: martijnke

    login/password: demo/demo

    application: 78396: apex advance

    Thanks for the creation of the example. Makes it so much easier to understand the problem and to work there.

    Start the application and click orders, and then click on any order to go to the edit page 4 control elements

    Click Add line and see what happens

    the javascript code is on page 4, the function is called switch_last_row()

    I found this in widget.tabular.js:

    1. Sign change on the form fields Manager new line, change "fcud_ *" element hidden C if a change occurs
    2. lNewRowIndex = tabular.pad ((tabular.gNumRows + tabular.gNewRows), 4);
    3. $(«: entrée [id ^ = f] [id$ = _ » + lNewRowIndex + «]», apex.gPageContext$) .change (function() {}
    4. $(«_#fcud__»_+_lNewRowIndex,_apex.gPageContext$).val ('C');
    5. });

    Why change this event not working for my vacuum dial-up?

    It does not work because the use of the method. html() in this function replaces the DOM elements these managers events are related to the:

    function switch_last_row(){
          var l_total =  $('td[headers="CHECK$01"] b').parent().parent().html();
      var l_last = $('td[headers="CHECK$01"]');
      var count = l_last.length;
      //$('td[headers="CHECK$01"] b').parent().parent().html(l_last[count - 1].innerHTML);
      var v_html = $(l_last[$('td[headers="CHECK$01"]').length - 1]).parent().html();
          //alert(l_total);
          //alert(v_html);
          $(l_last[count - 1]).parent().html(l_total);
          $(l_last[count - 2]).parent().html(v_html);
    }
    

    Event managers are left intact by using an approach much more simple that moves the total line node below the newly added in the DOM instead of exchanging their content:

    function switch_last_row() {
      var totalRow = $('td[headers="CHECK$01"] b').closest('tr');
      totalRow.next().after(totalRow);
    }
    

    I created a demonstration of this in page 4 a new application in your workspace. However, this leads to a number of other problems. As I'm not sure of the magnitude that these additional questions were present or planned in the original, I left things to this page 4 and started from scratch on pages 586 and 587. In general, the JS code in the example seems to be too procedural. It does not entirely the ability to work at a higher level of abstraction using jQuery (' write less do more ") and the DOM objects. Doing this, in conjunction with dynamic actions APEX gives more compact code, better separation of concerns and an application that is much easier to debug and maintain. Compare the use of the CSS level page and unique dynamic action to bind several columns of report versus change events manually adding/changing the attributes of style event and online at the column level.

  • Is it possible to add an editable region where codeOutsideHTMLIsLocked = 'true '.

    Is it possible to add an editable when codeOutsideHTMLIsLocked = 'true' and an editable region is added?

    When I try the following, the first line is grayed out and cannot be changed, but the rest is not grayed out and apparently all editable.

    <!-InstanceBeginEditable name = 'model'->

    I'M EDITABLE

    <! - InstanceEndEditable - >

    I'M NOT EDITABLE

    <! doctype html >

    "< html > <!-InstanceBegin template="/Templates/main.dwt.cfm "codeOutsideHTMLIsLocked ="true"->

    < head >

    < meta charset = "utf-8" >

    <!-InstanceBeginEditable name = "doctitle"-->

    < title > Untitled Document < /title >

    <! - InstanceEndEditable - >

    <!-InstanceBeginEditable name = "head"->

    I'M EDITABLE

    <! - InstanceEndEditable - >

    < / head >

    < body >

    I'M NOT EDITABLE

    <!-Name = 'body'-> InstanceBeginEditable

    I'M EDITABLE

    <! - InstanceEndEditable - >

    < / body >

    <! - InstanceEnd - > < / html >

    I use Dreamweaver CS6 Version 12.0 Build 5861

    Take a look at templates using Dreamweaver to design a page layout, Scripts in the section server models.

  • Is it possible to add the car rental search field in a form?

    Hello

    was wondering if its possible to add a field of automatic search form and also receive the location of the person who submits the form with the form.

    Memo

    Hey Memo,

    Muse only currently allow you to add text single line, multi-line text box, but there is no way to add the geolocation Muse online form option. You can try this

    HTML5 geolocation

    I hope this helps.

  • Is it possible to add text to the cells and apply the character style in the cell

    I work in InDesign on Mac 5.

    I have two tables of formatting with information that will be eventually combined. I implemented the scripts I found on these forums to add the columns needed, merge lines and fill the cells merged with the appropriate color, but can't two remaining tasks.

    1. is it possible to add text to a cell of some?

    2 and it is possible to apply a character style to cells? (different cells than those that I need to add some text)

    I played with this code but do not know if it is even close...

    {

    table. Rows [0]. Cells [0]. InsertText (' CS/PS");

    }

    {

    table. Rows [0]. Cells [0] .appliedCharacterStyle ("bold");

    }

    Here are the scripts that I have combined so far for the table...

    Add column

    myTable = app.selection [0];

    MyColumn = myTable.columns [1];

    for (a = 0; < 1; a ++)

    {

    myTable.columns.add (LocationOptions.AFTER, myColumn);

    }

    Merge lines

    table = app.selection [0];

    If (table.hasOwnProperty ("baseline") table) = table.parent;

    If (instanceof cell table) table = table.parent;

    If (instanceof column table) table = table.parent;

    If (instanceof row table) table = table.parent;

    If (instanceof Table table)

    {

    table. Rows [0]. Cells [0]. Merge (table.rows [0] .cells [1]);

    }

    {

    colours alternating in merged lines

    r = table.rows [1];

    n = app.activeDocument.swatches.item ("orange");

    b = app.activeDocument.swatches.item ("PANTONE 3005 C");

    for (c = 0; c < r.cells.length; c ++)

    {

    If (c & 1)

    r.Cells [c]. Properties = {fillColor:b};

    on the other

    r.Cells [c]. FillColor = n;

    }

    }

    Hello

    1. If you want to add the text, go further in:

    table. Rows [0]. Cells [0] .insertionPoints [0] .silence = ' CS/PS;

    2 similar with application of styles:

    table. Rows [0]. Cells [0] .texts [0] .appliedCharacterStyle = "bold" / / If this style is present in your doc

    Jarek

  • Y at - there no possibility to hide a line?

    Y at - there no possibility to hide a line? Other than data security level there at - it another option to hide a row. I need the value of this line to be summarized in the total general. But it should not be displayed to users. Is it possible to do...

    Hello

    Conditional formatting-> add a condition-> select the column and supply provided you want to hide the line
    -> Options of Style CSS custom (HTML only)-> check use Custom CSS Style and add the text box display: no
    Repeat all the columns in that particular line

    Hope help u...

    See you soon,.
    Aravind

  • I need to find all of the XML elements and add a line break for the text of each of them

    I need to find all XML elements and to add a line break the text of each of them.

    Is it possible with a script?

    Try this piece of code as it is. I hope that's what you want...

    var myDoc = app.activeDocument;
    var inddRooElement = myDoc.xmlElements.item(0);
    var xPathElements = inddRooElement.evaluateXPathExpression("//*");
    var elementCount = xPathElements.length;
    for(var eId=0; eId
    

    ----------------

    Green4ever

Maybe you are looking for