| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849 |
- <html>
- <head>
- <title>Blitz3D Docs</title>
- <link rel=stylesheet href=../css/commands.css type=text/css>
- </head>
- <body>
- <h1>Goto label</h1>
- <h1>Parameters</h1>
- <table>
- <tr>
- <td>
- label = any valid exisiting label
- </td>
- </tr>
- </table>
- <h1>Description</h1>
- <table>
- <tr>
- <td>
- This branches the flow of the program to a designated label. With the use of Functions inside of Blitz, it isn't very practical to use Gotos, but you may still find it useful. If you require the need to return execution back to the calling statement, you may use Gosub instead. See the example.
- <br>
- <br>
- See also: <a class=small href=Gosub.htm>Gosub</a>, <a class=small href=Function.htm>Function</a>.
- </td>
- </tr>
- </table>
- <h1><a href=../2d_examples/Goto.bb>Example</a></h1>
- <table>
- <tr>
- <td>
- Print "The program starts ..."
<br />
- Goto label1
<br />
- Print "This line never gets printed .."
<br />
- End
<br />
-
<br />
- .label1
<br />
- Print "We just jumped here!"
<br />
-
<br />
- ; wait for ESC key before ending
<br />
- While Not KeyHit(1)
<br />
- Wend
- </td>
- </tr>
- </table>
- <br>
- <a target=_top href=../index.htm>Index</a><br>
- <br>
- Click <a href=http://www.blitzbasic.co.nz/b3ddocs/command.php?name=Goto&ref=comments target=_blank>here</a> to view the latest version of this page online</body>
- </html>
|