gl gl gl it gl ca gl en gl en gl en en en en en gl en en en gl gl ca en gl en en en en
Exits a Do...Loop, For...Next, a function, a property, or a subroutine.
Exit Do, Exit For, Exit Function, Exit Property, Exit Sub
Only valid within a Do...Loop statement to exit the loop. Program execution continues with the statement that follows the Loop statement. If Do...Loop statements are nested, the control is transferred to the loop in the next higher level.
Only valid within a For...Next loop to exit the loop. Program execution continues with the first statement that follows the Next statement. In nested statements, the control is transferred to the loop in the next higher level.
Sae inmediatamente do procedemento Función. A execución do programa continúa coa declaración que segue a chamada á Función.
Exits the Property procedure immediately. Program execution continues with the statement that follows the Property call.
Sae inmediatamente do procedemento Función. A execución do programa continúa coa declaración que segue a chamada á Función.
A instrución Exit non define o final dunha estrutura e, por iso, non debe confundirse coa instrución End.
Sub ExampleExit Dim sReturn As String Dim sListArray(10) As String Dim siStep As Single For siStep = 0 to 10 REM Fill array with test data sListArray(siStep) = chr(siStep + 65) MsgBox sListArray(siStep) Next siStep sReturn = LinSearch(sListArray(), "B") Print sReturn End Sub Function LinSearch( sList(), sItem As String ) As Integer Dim iCount As Integer ' BuscaLin busca en MatrizTexto: sLista() unha EntradaTexto: REM Devolve o índice da entrada ou 0 (Nulo) For iCount=1 To Ubound( sList() ) If sList( iCount ) = sItem Then Exit for REM sElemen encontrado End If Next iCount If iCount = Ubound( sList() ) Then iCount = 0 LinSearch = iCount End Function
Precisamos da súa axuda!
Impressum (Legal Info) | Privacy Policy | Statutes (non-binding English translation) - Satzung (binding German version) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Mozilla Public License v2.0. “LibreOffice” and “The Document Foundation” are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy. LibreOffice was based on OpenOffice.org.
Help content debug info:
This page is: /text/sbasic/shared/03090412.xhp
Title is: Instrución Exit