Ah, ok, thank you for the response. Shouldn't it be possible to do something like:
For I=0 to 100000
"the code"
I=I+1
If |exp1-target| < 0,001
end For
100000 itterations should definitely be enough :)
I have done most of my (very limited) programming in Matlab so if this way of...
I want to itterate the value of one expression (measurement) with input from another expression (length)
The first expression is directly relatetd to the second one.
I want to start with a value (say 2000) for the second expression (exp2), the first expression (exp1) is then 414.8119359...
I believe that is the code i cut some of the
" Dim output1 As Expression = Nothing
output1 = workPart.Expressions.FindObject("output1")
Dim output2 As Expression = Nothing
output2 = workPart.Expressions.FindObject("output2")
Dim output3 As...
These are expressions that have their value defined as a measurement, for instance the distance between 2 surfaces or an angle between 2 objects that change for each iteration, the measurements update and i do not need to create new measurements each time.
Got it working! Running a test tonight as i expect it to take 4-5hours..
I hope it's ok to post altered code from NXJournaling.com?
'spreadsheet_update
'NXJournaling.com
'April 13, 2015
'
'Update a model from a range of values in a spreadsheet.
'The specified expression in the part file must...
The code you linked to works like a charm, thank you! I have managed to get the model to take a value from the excel sheet, put it into an expression, update the model according to the new expression, get the next value from the spreadsheet, update end so on. I have spent half a day looking for...
I want to import a value from an excell sheet (lets say from column A row one)to a predefined expression (called "SmStroke") update the model according to this newly imported value (a constraint in the model is defined by "SmStroke"), export a number of measurements also defined as expressions...