Contents
Index 🔎︎

# Function Statement

Gosa deebii murteessuuf sagantaa xiqqaa akka himannootti fayyaduu danda'u qindeessi.

## Caasimaa:

Ulaagaalee ilaali

## Ulaagaalee:

Caasimaa:

Function Name[(VarName1 [As Type][, VarName2 [As Type][,...]]]) [As Type]

garee himaa

[Exit Function]

garee himaa

Faankishiinii Xumuraa

Ulaagaalee:

Maqaa: Maqaa sagantaa xiqqaa gatii faankishiniidhan deebi'u qabatuuf.

VarName: Ulaagaalee sagantaa xiqqaatti darbe.

Gosa: Jefuraa gos-ibsituu.

## Fakkeenya:

    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
    REM Linsearch searches a TextArray:sList() for a TextEntry:
    REM Gatiin deebii kasaa galtuu ykn 0(Null)dha.
        For iCount=1 To Ubound( sList() )
            If sList( iCount ) = sItem Then
                Exit for REM sItem found
            End If
        Next iCount
        If iCount = Ubound( sList() ) Then iCount = 0
        LinSearch = iCount
    End Function