Profile picture for user celso.mattheus

I can't seem to make the Table object work in my dialog boxes. The problem is, I don't even know what I'm doing wrong, what attribute I'm not filling right... 

I don't have a specific question; instead, I would like to know if someone could show me a simple working code for a dialog box with a 2 columns and 2 rows table, so that I could understand how do they work, since the official documentation doesn't have any example for it. 

by Runé Becker
Badge for 'Mastermind' achievement
Posted on Mon, 02/08/2016 - 09:48

Oi Celso,

Did you search ARIS Community for report script code? You could conveniently do that via Google:

https://www.google.de/webhp?sourceid=chrome-instant&ion=1&espv=2&ie=UTF-8#q=report%20table%20site%3Aariscommunity.com

Doing so you would find ARIS scripting tutorials, a collection of posts about ARIS report scripts:

http://www.ariscommunity.com/users/eva-klein/2010-04-27-aris-scripting-tutorials

Among them Output models as table might be what you are looking for:

http://www.ariscommunity.com/users/mwz/2010-05-11-output-models-table

Um abraço

Rune

0
by Robert Goldenbaum
Badge for 'Question Solver' achievement
Posted on Mon, 02/08/2016 - 11:55

Ahm, he is searching for tables in his dialog box :-)

@Celso - sorry, don't have an example for this.

BR Robert

0
by Martin Schröder
Badge for 'Contributor' achievement
Posted on Mon, 02/08/2016 - 17:58

Hello Celso,

the scripting tutorials cover custom dialog coding in part 6 and part 10

As another source of inspiration I studied the off the shelf report scripts by SAG like "create process manual".

i can't offer you a working example, but in this post is included a complete user dialog script example, apparently from ARIS 9 Script Help.

Regards, Martin

0
by Ariene Kroeze
Posted on Tue, 02/09/2016 - 13:38
fDialog()

var gUserDialog=null
function fDialog(){
var aHeaders    = ["", "Support type"]
var aColProps   = [Constants.TABLECOLUMN_BOOL_EDIT, Constants.TABLECOLUMN_SINGLELINE]
var aColWidths  = [10, 90]
var TableProps  = Constants.TABLE_STYLE_DEFAULT

// create template
var Template = Dialogs.createNewDialogTemplate(0,0, 540, 140, "Caption", "fEvents");
// create table
Template.Table( 8, 40, 530, 130, aHeaders, aColProps, aColWidths, "tblSupportTypes", TableProps)
Template.OKButton()
Template.CancelButton()
// create dialog
gUserDialog = Dialogs.createUserDialog(Template);
// show dialog and get Result
var Result = Dialogs.show(gUserDialog)
}

function fEvents (psDlgItem, plAction, plSuppValue){
    var lbReturn = false;  // diag continues
   //            = true       diag ends

    switch(plAction){
      case 1:  // init
         // set values in table
         var aTableValues =[ true, "Common"
                           , true, "Logical G/T supported"
                           , true, "Local"
                           , true, "Other"]
        gUserDialog.setDlgListBoxArray("tblSupportTypes", aTableValues);
        break;
    case 2:  
        // CheckBox, DropListBox, ListBox or OptionGroup: value has been changed
        // CancelButton, OKButton or PushButton has been pressed
        break;
    case 3:  
        // ComboBox or TextBox  the text has been changed
        break;        
    case 4:  
        // DlgItem retains the focus. SuppValue is the item that loses focus (index, 0 based).
        break;
    case 5:  
        // Idle processing
           break;        
    case 6:  // Fiekey (F1-F24) has been pressed.
        break;        
    case 7:  // The user has double clicked on a table or an item in a list.
        // get row nr
        var lRowNr = gUserDialog.getDlgTableValue("tblSupportTypes").getY();  
        // sets the selected column and row.
        gUserDialog.setDlgTableValue("tblSupportTypes", 0 , lRowNr)
        break;
    case 8:  // TableEditChange
        break;
    }

    return lbReturn;
}

0
by Ariene Kroeze
Posted on Tue, 02/09/2016 - 13:47

 

Oh, gosh, I forgot to upload the image in the code above.

0
by Celso Mattheus Cantanhede Silva Author
Posted on Wed, 02/10/2016 - 19:38

Thank you all very much for the details and instructions! That's exactly what I wasn't being able to find through google or in the documentation. Those will be very helpful!

0

Featured achievement

Rookie
Say hello to the ARIS Community! Personalize your community experience by following forums or tags, liking a post or uploading a profile picture.
Recent Unlocks

Leaderboard

|
icon-arrow-down icon-arrow-cerulean-left icon-arrow-cerulean-right icon-arrow-down icon-arrow-left icon-arrow-right icon-arrow icon-back icon-close icon-comments icon-correct-answer icon-tick icon-download icon-facebook icon-flag icon-google-plus icon-hamburger icon-in icon-info icon-instagram icon-login-true icon-login icon-mail-notification icon-mail icon-mortarboard icon-newsletter icon-notification icon-pinterest icon-plus icon-rss icon-search icon-share icon-shield icon-snapchat icon-star icon-tutorials icon-twitter icon-universities icon-videos icon-views icon-whatsapp icon-xing icon-youtube icon-jobs icon-heart icon-heart2 aris-express bpm-glossary help-intro help-design Process_Mining_Icon help-publishing help-administration help-dashboarding help-archive help-risk icon-knowledge icon-question icon-events icon-message icon-more icon-pencil forum-icon icon-lock