Quantcast
Channel: ARIS Report Scripting
Viewing all 257 articles
Browse latest View live

Is there a way to get Connected Models from a Model

$
0
0

Hi,

I am trying to get the Connected Models (as shown below) from Model object in Report,

 

 

but I am not able to find methods that returns Connected Models from Models, I could get the Connected Objects using Report class Model - Method getSuperiorObjDefs. Is there any relevant available for Report similar to Macro class Designer - Method getSuperiorModels ?

Thanks,

JeyaKarthik N R


Formatting Text in Report Forms

$
0
0

Hi,

Is it possible to change the font properties (text color, bold, size...) in the form reports ?

I see it is possible to apply html format in a DialogTemplate text:

var userDialog = Dialogs.createNewDialogTemplate (1000, 430, "Title");
userDialog.Text (560, 35, 100, 15, "<b>Table: </b>");
userDialog.Text (560, 35, 100, 15, "<font color=\"red\">Table: </font>");

but I can't find the way to do the same or similar for list items (tables, DropListBox...), I have this code:

var userDialog = Dialogs.createNewDialogTemplate (1000, 430, "Title");
userDialog.Table (560, 55, 435, 340, ["Column 1", "Column 2"], [Constants.TABLECOLUMN_SINGLELINE, Constants.TABLECOLUMN_SINGLELINE], [40, 60] , "TBL_ID1", Constants.TABLE_STYLE_DEFAULT);

// putting the content in the table
var tblContent = [["foo1", "foo2"], ["foo10", "foo11"]];
this.dialog.getPage(0).getDialogElement("TBL_ID1").setItems( tblContent );

 

Any ideas ¿?

 

Many thanks.

Recursive call to find 'superior' object

$
0
0

I have been trying to write a script to find the process-oriented superior of objects.

Initially I thought this would not be very difficult, though I am unable to find a good solution.

I am looping through all Object Occurrences, then I get a connection list for each object:

aCnxDefList = aObjOcc[j].ObjDef().CxnList(); // CxnDef[]

, then I loop through connections comparing names of the known top level superiors with all aCnxDefList[k].SourceObjDef().Name(nLocale). If I don;t get a match, then I call a recursive function:

nCurrentLevel = get_nesting_level(aCnxDefList[k].SourceObjDef(), 0);

I am using a recursive function, but I am unable to walk up to the superior for some reason.I would appreciate any suggestions. Here is the code for the function:

// Takes in Source Object Def
function get_nesting_level(my_ObjDef, myLevelCount) {
    aCxnDef = my_ObjDef.CxnList(Constants.EDGES_IN);
    myLevelCount++; // increment new nesting level
    
    // cycle through 'Connections IN' to find superior connection match for "CORE", "MANAGEMENT", "ENABLING"
    for (var i=0; i < aCxnDef.length; i++) {
        curSrc_ObjDef = aCxnDef[i].SourceObjDef();
        sObjName = aCxnDef[i].SourceObjDef().Name(nLocale);
        
            // All objects are children of the following 3 objects
            if((sObjName == 'X') ||
                (sObjName == 'Y') ||
                (sObjName == 'Z'))
                {
                // we found the matching top level!!!
                return (myLevelCount);
                }
                else
                {
                // we did not find the superior yet - recurse another level
                return get_nesting_level(curSrc_ObjDef, myLevelCount);
                }
    }
}

Escape user dialog

$
0
0

Hallo all together,

my problem is the escape from a user dialog in a report.

I've created a dialog window in my report similar to the example on the help side "Report class DialogObject". I've adapted it to my report as a single side dialog and it works, excepted one feature. I can click "OK" and the dialog ends and I can click "Escape" and it also ends.

But how can I read in my report, which button has finalized the dialog?

Therefore I could'nt find any notes in the help side.

I wold be happy if is somebody who can help me.

Many thanks.

How to insert attached document in an output document ?

$
0
0

Hi,

I have a report that output information of objects in a .doc or .pdf.

The problem is when the attribute "Documentation" of the object had attached a document, I can't find the way to insert it (attached with icon, not its contents) in the table.

(Attached sample image in MS Office Word, and if you open the icon open the document attached)

Any help ?

Actually If the atribute "Documentation" had an image attached I print it but if had other documents does nothing.

 

Short Code:

output = Context.createOutputObject();

var document = objDef.Attribute(Constants.AT_DOCUMENTATION, LANGUAGE).getExternalDocument();

if (document.isValid()) {
    if ( document.getFileExtension().search(/jpg|jpeg|png|gif|emf|tif|tiff/i) != -1 ) {

         var img = Context.createPicture(document.getDocument(), Constants.IMAGE_FORMAT_PNG);
         output.OutGraphic(img, -1, imgWidth, imgHeigth);

   } else {
          // Insert document as an icon ¿?
   }
}

 

Many Thanks.

Logging Semantic Check success/Errors

$
0
0

Hi,

I want to create a report that runs semantic checks on all the models under a DB/group and maintains the success/failure message in a model attribute.

Is there a way to catch the message displayed by semantic check output dialogue/log and if so how can i put this on an attribute?

Thanks,

Puneet

 

Creation of an OLE object in a macro

$
0
0

Hello everyone,

I am working with a macro in ARIS Architect to insert a picture (specifically a logo) as an OLE object.
With a report I can do that easily with the following instruction instruction:

createComObjOcc (int x,int y, int width, int height, ComObjOcc source, boolean bCreateNewDef)

Unfortunately, using a macro there is not a similar instruction and I can't call a report because the macro is executed when the model is open.

How could I solve the problem? Did anyone have the same problem?

Thank you very much for your willingness.

Change Management in Architect vs Designer

$
0
0

Good day,

In experimenting with using different user access and privilege setups, there is a difference in functionality of the Change Management features in Architect vs Designer. Does anyone have a table or doc or help that describes theses differences and how user management effects it?

Secondly, has anyone written a script to specifically run the "Reset all change management attributes" that a user can run on an Object from within Designer?

Regards,

Barend Fair

 


Get alternate language

$
0
0

Hallo,

with Context.getSelectedLanguage() I can get the LocaleID to get attributes and names in the standard language.

But how can I get the alternate or fallback language?

If there is anyone who can help me I would be very happy.

Many thanks.

Holger

Effective Solution Delivery Capability (ARIS + Confluence + JIRA)

$
0
0

Do you have a "wall" between Business & IT

Do you have an integrated solution delivery process (SDLC) or a fragmented environment where there is little or no Business & IT alignment? You can keep on restructuring your business, but without defined processes the structure will never be effective. Your solution delivery capability should be underpinned by well defined processes. After all, the SDLC is just a process that is executed by people & enabled by technology. A broken or ineffective process cannot be fixed by changing the organizational structure. http://clk.im/Solution-Delivery-Capability 

Database backup inside a report

$
0
0

Hallo folks,

for creating a backup inside a report I have the following function DbBackup:

function DbBackup()
{
    var ADB   = ArisData.getActiveDatabase();
    var oFile;
    var oDbAdmin;
    var lOK;
    var sPath = "C:\\Download";
    var sFile = "WorkDB "+Date();

    Context.setSelectedPath(sPath);
    Context.setSelectedFile(sFile);
    oFile     = new java.io.File(sPath, sFile);
    oDbAdmin  = Context.getComponent("ServerAdmin");
    lOK       = oDbAdmin.backupDatabase(ADB, oFile);

    return;
}

 

This function runs through without creating an error.
But unfortunately it does not create any backup file and the answer of "oDbAdmin.backupDatabase(ADB, oFile)" is "false". (lOK = false)
The path "C:\Download" exists on my computer and I run the report on my local server for development.
When starting a backup of this database manually I have no problems. That works fine.

Now I would be very happy if anybody can help me and show me where my mistake is.
Many thanks in advance,
Holger

objects and variables in local script service for APG

$
0
0

Hi,

Does anyone have an overview of which objects and variables are available when writing a custom local script service for APG?

Looking at the out-of-the-box services I can see that there is an input object, which has all the input variables as properties and there is an output object which has all the output variables as properties. But what else is there? Do we have all the objects from the Reports and Semantick Checks?

In the ARIS User Management services an object called "userManagement" is used to update UMC related data, but where can I find the methods for this object?

 

Hope someone can help me.

 

Best regards,
Simon W. Abildgaard

ARIS Administration books

$
0
0

Hi!

I am searching for books regarding ARIS administration online but I can only see Rob Davis'"ARIS Advance Process Modelling and Administration" which was published last 2010. Since ARIS has been upgraded already, I would like to know if this is still helpful with today's current setup, with how to maintain/housekeep the databases and how to create reports (if it is discussed on the book).

If not, can you please advise other books that can help me with ARIS administration?

Many thanks!

Regards,

Julie Grace

Report error (-32239)

$
0
0

Hi, community,

I've got a problem with my report. ARIS shows me an error window (Error creating report: -32239) when report is started.

It looks like this:

 

I use Merge Fields in my output file template  to fill in with arguments from script.

If i block several strings which contain output text, error code changes. Like this :

I cant determinate the cause of my problem ,because when i start the same report in ARIS debugger (or start in a context of model/object while debugger is open), it works.

Please help to solve this problem.

Thank's for your help

Andrey

Report script using external JAR file no longer working after installing v9.8.6

$
0
0

Hello ARIS community,

We have a custom script that we developed that uses an external JAR file.  This JAR file enables the report script to retrieve contact information for people in our corporate active directory by a web service.  This had been working all the way up to v9.8.1.  We have recently installed v9.8.6 and now we get the error

Unmarshalling Error: unexpected element (uri:"http://webservice", local:"deactivate")

Expected elements are <{http://webservice}nickname>,{http://webservice}hrSystem, ...

I submitted an empower ticket with Software AG, but I was told that since this is a custom script, they cannot help me.  I believe it must be something in the new version of how it is handling SOAP request from web service that is causing the error.  Maybe I have to modify the JAR file?  If anyone has any suggestions, I would greatly appreciate it.

As a test, I installed v9.8.6 on a test server and tried to run the report script.  It failed with the same error.  I uninstalled v9.8.6 and then reinstalled v9.8.1.  I ran the report script and it completed successfully.

Regards,

Allen


Report: How to get the current page and line number

$
0
0

Hello community,

currently I'm writing an report to write the content of several models into a word document.

Is there any possibility to get the current page number and the current line number?

I know, I can write the current page number with "File.OutputField(Constants.FIELD_PAGE, ...)" directly into the document. But I need it in a variable for later use.

And the line number or the position on the current page I need to see if the next chapter, table or picture suites in the current page or should I begin the next page.

Many thanks in advance to everyone who has an idea.

Greetings Holger

Edit user selection of dialog

$
0
0

Hello, 

i'm trying to edit a user selection a user did in a dialog. This dialog is part of an executable process in the ARIS Process Governance. 

Unfortunately, i can't find a possibility to add users to this selection or to delete existing ones via localService or report. 

Can someone help me?

Many thanks in advance! 

Regards, 

Richard 

For discussion, in this example i just want to add someone from UMC to an existing selection:

var me = userManagement.findUserByLogin("loginName");
var myDisplayName = me.displayName;
var myId = me.UUID;
                    
function isUserChooserEmpty(selection) {
    try{
        selection.participantGroup.participants.participant[0].id.idValue;
        return false;
    }catch(e){
        return true;
    }  
}

if(!isUserChooserEmpty(input.userSelection)){
    var users = input.userSelection.participantGroup.participants.participant;
    users.add(me); //This is not working because the object is of type AInputXMLData. Here is the problem.
    output.updatedUserSelection = users;
}else{
    output.updatedUserSelection = "updatedUserSelection is empty";
}

Optimize UMC extracting reports possibilities

$
0
0

Hi , at the moment i generate the reports with the UMC by selecting them , that's all but is there any additional information avaible at UMC and find a way to automate the information gathering with UMC ?

Or from where the UMC gather that information ? Is there any folder where i can access ? 

 

Thanks ,

 

Sergio.

Access to collaboration comments via report

$
0
0

Hello,

one thing in our preparation for migration from ARIS 7.2 to ARIS 10 Connect is the question:

- Is it possible to get the comments that are made in Connect on a model within a report? (Comment, issue date of the comment)

I can't find such commands in the ARIS script help page.

Many thanks

Bernd

Delete a model in a report

$
0
0

Hello community,

with the command line:

oTmpModel = oTmpGrp.CreateModel(Constants.MT_EEPC_TAB, sTmpModName, LOC)

I can create a new model for temporary use. That works fine. But after the usage I don't need this model anymore.

How can I delete this model?

I would be very happy if anyone can help me.

 

Best regards

Holger

Viewing all 257 articles
Browse latest View live