Created
December 9, 2018 11:53
-
-
Save jfdeclercq/c447a16e1615102b8cca1776b22c24db to your computer and use it in GitHub Desktop.
DiagramNote.ajs #jArchi
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Script to add a note to a view with name of the view, date and your name | |
//Thank you to J-B Sarrodie | |
// Get the first view in the current selection | |
var view = selection.filter("archimate-diagram-model").first(); | |
// Get current date | |
var currentDate = new Date(); | |
// Create a new note and set its text | |
var note = view.createObject("note", 10, 10, -1, -1); | |
note.text = view.name + "\n" + currentDate.toString() +"\n" + "YOUR NAME"; | |
note.fillColor = "#e2e2be"; | |
console.log("Note added to " + view.name); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment