[GiDlist] batch file

Moderator: GiD Team

Post Reply
Geißler, Peter

[GiDlist] batch file

Post by Geißler, Peter »

Hi all,

I have a question in regards to writing a batch file. Is it possible to define and declare a variable in a batch file. For example:

Set a_x = 5.0
Set a_z = 2.0
Geometry create point
%a_x, 0.0,% a_z
Escape escape

Best regards
Peter
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://listas.cimne.upc.edu/pipermail/gidlist/attachments/20141028/255000a7/attachment.htm
User avatar
escolano
Posts: 1918
Joined: Sun Sep 05, 1982 10:51 pm

[GiDlist] batch file

Post by escolano »

No, the batch file is not a programming language, is only a sequence of GiD
process keyword commands.



To do things like this you must create a Tcl prodedure that send ‘process
commands’ to GiD with GiD_Process,

e.g.



proc create_point { x z } {

set y 0.0

GiD_Process Geometry Create Point $x $y $z

}



create_point 5.0 2.0



Or you can create the .bch file with some external program where everything
has been replaced to the final GiD process commands



Geometry Create Point 5.0 0.0 2.0

(this final .bch file could be created somehow based on some kind of
template evaluated by your external program)



Regards



Enrique Escolano



De: gidlist-bounces at listas.cimne.upc.edu
[mailto:gidlist-bounces at listas.cimne.upc.edu] En nombre de Geißler, Peter
Enviado el: martes, 28 de octubre de 2014 11:23
Para: gidlist at listas.cimne.upc.edu
Asunto: [GiDlist] batch file



Hi all,



I have a question in regards to writing a batch file. Is it possible to
define and declare a variable in a batch file. For example:



Set a_x = 5.0

Set a_z = 2.0

Geometry create point

%a_x, 0.0,% a_z

Escape escape



Best regards

Peter

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://listas.cimne.upc.edu/pipermail/gidlist/attachments/20141028/c360136a/attachment.htm
Post Reply