Former-commit-id:a02aeb236c
[formerly9f19e3f712
] [formerlya02aeb236c
[formerly9f19e3f712
] [formerly06a8b51d6d
[formerly 64fa9254b946eae7e61bbc3f513b7c3696c4f54f]]] Former-commit-id:06a8b51d6d
Former-commit-id:8e80217e59
[formerly3360eb6c5f
] Former-commit-id:377dcd10b9
16 lines
909 B
HTML
16 lines
909 B
HTML
|
|
<html>
|
|
<head>
|
|
<meta http-equiv="content-type"
|
|
content="text/html; charset=ISO-8859-1">
|
|
<title></title>
|
|
</head>
|
|
<body>
|
|
<center>
|
|
<h2> Text Formatter User Guide for Tabular Products</h2>
|
|
<h3>16. Smart Text Products - Python "exec" statement</h3>
|
|
<hr>
|
|
<a href=Slide15.html>Previous Slide</a> <a href=Slide17.html>Next Slide</a> <br><img SRC=Slide16.JPG border=1><br></center>
|
|
<p><p><big>To do this, we use the special "exec" Python command. This is a very handy command which you will see in use throughout the text products. You build a text string of the Python code you would like to execute and then submit it to the "exec" command. So in this case, we loop through the entries of the Definition section creating variables. For example, if we have a Definition entry of "type", we build an exec string that sets the variable, "self._type" to its Definition value. <br><br><br></big>
|
|
</body>
|
|
</html>
|