Compiled UDF
Anybody has tried to use thread_loop_c in compiled UDF(OS: Win2k Professional)? I wrote one like this:
#include "udf.h" extern Domain* domain; DEFINE_ON_DEMAND(test) { Thread *t; cell_t c; thread_loop_c(t,domain) { begin_c_loop(c,t) { } end_c_loop(c,t) } } I can compile the file and get the .dll file. But when I tried to run the udf in Fluent, it gave the error message: Error: FLUENT received fatal signal (ACCESS_VIOLATION) 1. Note exact events leading to error. 2. Save case/data under new name. 3. Exit program and restart to continue. 4. Report error to your distributor. Error Object: () Seems I cannot use thread_loop_c. Has anybody encountered similar problem? Thanks. Lu |
Re: Compiled UDF
Hi,
the reason of error is "extern Domain* domain". this macro does not work on any Windows . So you have to replace this macro to "Domain *domain = Get_Domain(1)". Thanks. |
Re: Compiled UDF
Thank you. It works!
|
All times are GMT -4. The time now is 00:44. |