-
Notifications
You must be signed in to change notification settings - Fork 1
/
NOTES
38 lines (25 loc) · 1015 Bytes
/
NOTES
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
TO DO NEXT
- Switch to use "Modules" vs "Components"
- Build filename from template string in Module
var app = adsk.core.Application.get();
var ui = app.userInterface;
var data = app.data;
var design = app.activeDocument.design;
var docs = app.documents;
var hubs = data.dataHubs;
var pHub = hubs.item(0); // found through trial and error.
//TODO write a method to find hub by name
var lfProj = pHub.dataProjects.item(7); // found through trial and error
//TODO write a method to find project by name
var lfRoot = lfProj.rootFolder;
var workingFolder = lfRoot.dataFolders.itemByName('microservice');
var files = workingFolder.dataFiles;
var testFile = files.item(1); // found through trial and error
//TODO write a method to find file by name
//docs.open(testFile);
var params = design.allParameters;
var length = params.itemByName('length');
var filet = params.itemByName('filet');
length.value = 15
ui.messageBox('parameter '+length.name);
var filtered = OrigArry.filter((val)=>{return val!='abc'});