CFD Online Discussion Forums

CFD Online Discussion Forums (
-   FLUENT (
-   -   Macro Trouble -Winows Explorer Crashes with Macro (

Martin Castillo July 13, 2007 01:18

Macro Trouble -Winows Explorer Crashes with Macro
Hello All,

[Windows Vista 64]

I was origionally using a macro for saving the data of an XY Plot, but since there is an explorer window that opens during the save comand it so happens that Fluent often crashed. I would like to take the following macro (.msh file) and create a series of commands under the Solve -> Execute Commands. I have a feeling that this method will stop the windows explorer from crashing.


(cx-macro-define '((pttemp . "(cx-gui-do cx-set-integer-entry \"Execute Commands*IntegerEntry1(Defined Commands)\" 4)\n

(cx-gui-do cx-activate-item \"MenuBar*PlotMenu*XY Plot...\")\n

(cx-gui-do cx-set-list-selections \"Solution XY Plot*Frame9*List9(Surfaces)\" '( 0 11))\n

(cx-gui-do cx-activate-item \"Solution XY Plot*Frame9*List9(Surfaces)\")\n

(cx-gui-do cx-set-toggle-button \"Solution XY Plot*Frame1(Options)*ToggleBox1(Options)*CheckButt on4(Write to File)\" #f)\n

(cx-gui-do cx-activate-item \"Solution XY Plot*Frame1(Options)*ToggleBox1(Options)*CheckButt on4(Write to File)\")\n

(cx-gui-do cx-activate-item \"Solution XY Plot*PanelButtons*PushButton1(OK)\")\n

(cx-gui-do cx-set-text-entry \"Select File*Text\" \"%t.txt\")\n

(cx-gui-do cx-activate-item \"Select File*OK\")\n

(cx-gui-do cx-activate-item \"Solution XY Plot*PanelButtons*PushButton2(Cancel)\")\n")


Thanks in advance for you kind help, Martin

Martin Castillo July 25, 2007 04:18

Re: Macro Trouble -Winows Explorer Crashes with Ma
Well it seems natural, but I seem to answer my own question on this forum. Nevertheless, here is the solution. Under Solve -> Execute Commands i have enabled the following commands:

Command-1 1 Time Step /dis sw 1

Command-2 1 Time Step /plot solution temperature y

Command-3 1 Time Step /plot plot yes %t.txt n n n temperature (0 11)

Please note that:

dis= display

sw= set-window

(0 11)= defined points that I have setup for fluent to observe

This was not an intuitive process to put this code together.


All times are GMT -4. The time now is 20:04.