Documentation: Difference between revisions
+Stata
m (added forth comments) |
(+Stata) |
||
Line 1,402:
FooClass comment: 'This is a comment ....'.
</lang>
=={{header|Stata}}==
Documentation is written in files with extension .sthlp, in Stata's markup language, SMCL.
For instance, say we have an ado file '''hello.ado''':
<lang stata>prog def hello
di "Hello, World!"
end</lang>
The documentation file, hello.sthlp, could be:
<pre>{smcl}
{title:Syntax}
{p 8 14 2}
{cmd:hello}
{title:Description}
{pstd}
{cmd:hello} will print the infamous message "Hello, World!" to Stata Results window.</pre>
Put these two file in a directory visible in the ado path. Then call the programm by typing <code>hello</code>, and open its help file by typing <code>help hello</code>.
=={{header|Swift}}==
|