DMiller01
Mechanical
- Jul 17, 2008
- 70
I am automating setup notes to appear when you generate shop docs.
I have learned enought tcl to do a crude implementation that works. To accomplish this I have add code in the shopdoc_programview_text.tcl file.
I'd like to polish the code to make it more robust and easiler to maintain but I am having trouble with what I would expect to be a very simple programming task.
I would like to read a txt file containing the setup notes to be added to the shop doc output file. I have tried using , "gets", "read" and "scan" to read the txt file and then "puts" to write it to the shop doc file. However it does not show up in the shop doc output file. I suspect that my "puts" command is not set up correctly. But it is possible that I'm not reading test.
I have also tried UG's MOM_output_literal also without success. If anyone has suggestion and/or would like more detail please let me know. A snippet of code is attached so you can see one of the many things I have tried.
I am using NX 6.0 with XP-pro
DaveM
I have learned enought tcl to do a crude implementation that works. To accomplish this I have add code in the shopdoc_programview_text.tcl file.
I'd like to polish the code to make it more robust and easiler to maintain but I am having trouble with what I would expect to be a very simple programming task.
I would like to read a txt file containing the setup notes to be added to the shop doc output file. I have tried using , "gets", "read" and "scan" to read the txt file and then "puts" to write it to the shop doc file. However it does not show up in the shop doc output file. I suspect that my "puts" command is not set up correctly. But it is possible that I'm not reading test.
I have also tried UG's MOM_output_literal also without success. If anyone has suggestion and/or would like more detail please let me know. A snippet of code is attached so you can see one of the many things I have tried.
I am using NX 6.0 with XP-pro
DaveM