CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > FLUENT > Fluent UDF and Scheme Programming

Execute external program in fluent udf

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 9, 2014, 04:35
Default Execute external program in fluent udf
  #1
New Member
 
Hoon-Hwe Cho
Join Date: Apr 2014
Posts: 1
Rep Power: 0
ccekkan is on a distinguished road
Hi guys!


I want to execute external program (e.g. test1.exe) in fluent udf.

So I used 'system' function to do that as follows.

'system("\"C:\\User\\20140408_SPCC\\test\\test1\\t est1\\test1.exe\"")'

However, I got a error message 'system: undeclared variable' though I used 'stdlib.h' and 'windows.h' files.

Please kindly let me know how to execute the .exe file.

Expecting help!
Sincerely thanks

Hoon
ccekkan is offline   Reply With Quote

Old   March 31, 2017, 00:00
Default
  #2
New Member
 
terryphi
Join Date: Mar 2017
Posts: 6
Rep Power: 9
terryphi is on a distinguished road
I would also like to know a solution to this.
terryphi is offline   Reply With Quote

Old   March 31, 2017, 04:38
Default
  #3
Senior Member
 
Join Date: Nov 2013
Posts: 1,965
Rep Power: 27
pakk will become famous soon enough
To be sure: don't try this with interpreted udf's, but use compiled udfs.

But (without knowing any context about the purpose of the external exe-file), I don't know if using a UDF to call it is the best solution. It is easier to do this in a scheme macro.

Code:
(system "C:\User\20140408_SPCC\test\test1\test1\test1.exe")
And do a macro hook (or whatever it is called, I don't remember) in the right place.
pakk is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
looking for a smart interface matlab fluent chary FLUENT 24 June 18, 2021 10:07
ATTN ALL: SOLUTON TO UDF COMPILE PROBLEM Rizwan Fluent UDF and Scheme Programming 40 March 18, 2018 07:05
fluent udf, saving data in udf mohsen zendehbad Fluent UDF and Scheme Programming 15 June 14, 2017 00:23
solving a conduction problem in FLUENT using UDF Avin2407 Fluent UDF and Scheme Programming 1 March 13, 2015 03:02
UDF for Viscoelastic Fow in Fluent skris2009 FLUENT 2 September 20, 2011 00:59


All times are GMT -4. The time now is 13:15.