|
[Sponsors] |
[DesignModeler] DesignModeler Scripting: How to get Full Command Access |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
August 19, 2016, 07:39 |
|
#41 |
New Member
Aung Ko Latt
Join Date: Jul 2016
Location: Germany
Posts: 12
Rep Power: 10 |
Thank you so much Kapi
that works well |
|
August 26, 2016, 08:02 |
|
#42 |
New Member
Aung Ko Latt
Join Date: Jul 2016
Location: Germany
Posts: 12
Rep Power: 10 |
Dear mates,
Thanks for your guidance and help! Now I have already done for python vs excel and bla bla. now i stuck in one place. In Design Modeller of my workbench workflow, I imported one geometry (in .igs file format) and then I finished editing and done. Now I would like to replace that geometry with another geometry (in .igs file format) in Design Modeller. What command lines in JScript should I use to do it ? and how? Thanks for giving time to read my message! Best Regards, |
|
August 31, 2016, 21:33 |
|
#43 |
Senior Member
Join Date: Apr 2014
Location: Melbourne
Posts: 584
Rep Power: 14 |
not sure how to replace it even manually.
Unless you delete that file and import the new one. How would you do it manually? |
|
September 5, 2016, 10:31 |
|
#44 |
New Member
Aung Ko Latt
Join Date: Jul 2016
Location: Germany
Posts: 12
Rep Power: 10 |
Dear Kapi,
According to Wasabi post on another thread, we can replace another geometry by manually. Please kindly find the attached photo. Referring to that photo, you can give another geometry(in another path) in Source and then you have to choose 'Yes' in Refresh option below the box. And then update the geometry and you will get replaced geometry. Hope you understand my description. Best Regards, Aung Ko Latt |
|
September 5, 2016, 11:31 |
|
#45 |
New Member
Aung Ko Latt
Join Date: Jul 2016
Location: Germany
Posts: 12
Rep Power: 10 |
Hello Everyone,
I would like to ask you one thing about CFX-Solver. I am going to do CFX solving in Linux. I already got .def file when I finished in CFX setup in Ansys Workbench. I named that file as 'CFX.def'. In Linux, I have a folder and I put that CFX.def inside this folder. In that folder, I put another script called 'RUNCFX.pl'. I write code inside that perl 'RUNCFX.pl' script that will use also 'CFX.def' file. I wrote perl script in order to run different(two or three) velocities by using 'CFX.def' file. By manually, I have to open CFX solver >> Tools >> Command line in order to run that .pl file. In CFX solver command window, i wrote ' perl RUNCFX.pl'. That thing is that "is there any batch command in command prompt in Linux to run that RUNCFX.pl file in CFX solver automatically"? in order to neglect by doing manually. I already read "Command-Line Options and Keywords for cfx5solve". I didn't find out the solution. Is there someone who knows how to call .pl in CFX in command prompt? Best Regards, Aung Ko Latt |
|
September 5, 2016, 20:56 |
|
#46 |
Senior Member
Join Date: Apr 2014
Location: Melbourne
Posts: 584
Rep Power: 14 |
ask CFX question in CFX forum!
dont post multiple unrelated question in same thread. Start new thread in CFX and post this question thr! Also, I will try to see what code can help you replace and refresh! |
|
September 7, 2016, 23:26 |
|
#47 |
New Member
Timothy Acosta
Join Date: Sep 2016
Posts: 1
Rep Power: 0 |
Hi There!
I'm currently doing a failure progression where you have to suppress certain bodies when that particular body exceeds a certain pressure. And I'm totally new to Scripting in Design Modeler. Or even JScripts. I've read up on the all the previous post and have opened up the Ans.Modeler.ObjectsCOM.dll library. I found the scripts needed but i don't entirely understand how the inputs are. [id(0x00000089)] HRESULT Select3dFace( [in] int Index, [in] double xs, [in] double ys, [in] double zs, [out, retval] int* selected); so I interpret this as. var Select = agb.Select3dFace(Index,xs,ys,zs); agb.Regen(); Is this right? What I basically need to automate is Selecting Certain Bodies then Suppressing them? Could anybody lead me to a clear direction? |
|
September 7, 2016, 23:52 |
|
#48 |
Senior Member
Join Date: Apr 2014
Location: Melbourne
Posts: 584
Rep Power: 14 |
rather going to the library u went, i would go to ansys script installed on your system to find some functions.
like: C:\Program Files\ANSYS Inc\v170\aisol\AGP\AGPages\scripts you will get some idea from it. First try to go to help section in ansys and see how scripts are created and use them. |
|
November 17, 2016, 05:12 |
|
#49 |
New Member
Paul
Join Date: Apr 2012
Posts: 27
Rep Power: 14 |
Hello everyone,
It's time to refresh this thread! Can anyone advise me how can I select faces created as a result of some feature in DM? For example, I have a blend feature imposed on a sharp edge, and I want to create a NS composed from faces created by this blend feature. Thanks in advance, Delcraft |
|
April 16, 2019, 12:27 |
|
#50 |
New Member
Andrew M
Join Date: Apr 2018
Location: Toronto
Posts: 18
Rep Power: 8 |
Hey Guys,
Does anyone know if there's a way to DELETE a feature after I've created it via DM script commands? For Example: I have a script to create a BOOLEAN using the command "var NewBoolean= ag.gui.CreateBoolean()" and the corresponding example code shown below. However in my automated process I would like to be able to select and delete this (and other) defined functions. var NewBoolean= ag.gui.CreateBoolean() NewBoolean.Name = "Combine Function" NewBoolean.Operation = 0 ag.listview.ActivateItem("Tool Bodies") agb.ClearSelections() body1 = ag.fm.Body(1) agb.AddSelect(agc.TypeBody, body1) body2 = ag.fm.Body(2) agb.AddSelect(agc.TypeBody, body2) ag.listview.ItemValue = "Apply" ag.b.Regen() Last edited by michal28; April 17, 2019 at 15:06. |
|
April 17, 2019, 14:50 |
|
#51 |
New Member
Andrew M
Join Date: Apr 2018
Location: Toronto
Posts: 18
Rep Power: 8 |
Within the agEventHandler.js file I have found commands just as agTreeDeleteSelectedFeature(0); and agDelete(0); but they only seems to give me object errors.
Is anyone familiar with this kind of DM command? |
|
September 13, 2019, 06:34 |
|
#52 |
Member
Dimitrios S. P.
Join Date: Jan 2018
Posts: 63
Rep Power: 8 |
Good day everyone,
does anyone know how to open .dll files to inspect objects? I have tried using visual studio 2017 to open "C:\Program Files\ANSYS Inc\v181\aisol\bin\winx64\Ans.Modeler.AppletCOM.dl l", but it responds with the error "has no valid CLR header and cannot be disassembled" |
|
December 20, 2019, 09:03 |
|
#53 |
New Member
Pavel
Join Date: Dec 2019
Posts: 1
Rep Power: 0 |
Good day everyone,
I am trying to write a Jscript for design modeler which will export created geometry into a .step file. And I got stuck with exporting command. I suppose it must look like ag.gui.Export("C:/work/Geom1.stp"); or ag.b.Export("C:/work/myFile.stp") but they don`t work. I tried to use CreateExport, SaveAs, Save, SaveFile instead of Export but they also don`t work. I will appreciate any help. Thank you in advanse. |
|
February 16, 2020, 16:13 |
|
#54 |
New Member
Kikurato
Join Date: Feb 2020
Posts: 1
Rep Power: 0 |
I'm sorry, do not tell
How can I create a name selection for a body plane in jscript |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Rotor 67 full compressor geometry | jf | Main CFD Forum | 3 | January 28, 2024 06:14 |
[ICEM] ICEM Scripting Issues | tylerplowright | ANSYS Meshing & Geometry | 33 | September 27, 2021 17:35 |
Physical size of geometry in DesignModeler | Michael Rasmussen | CFX | 9 | June 16, 2017 04:27 |
[DesignModeler] find features of Gambit in DesignModeler | code_source | ANSYS Meshing & Geometry | 13 | April 30, 2014 08:33 |
[Other] exchange of parameter values between TurboGrid and DesignModeler in Workbench | la7low | ANSYS Meshing & Geometry | 2 | February 21, 2011 16:12 |