Android Question alert : Return type (Sub signature) should be set explicitly.

Discussion in 'Android Questions' started by palmaf, Feb 16, 2015.

  1. palmaf

    palmaf Member Licensed User

    I used the IIF function as described in the forum, but now compile i from this alert : Return type (Sub signature) should be set explicitly. How to correct ? Thanks

    this is the code

    Sub IIF(c As Boolean, TrueRes As String, FalseRes As String)

    If c Then Return TrueRes Else Return FalseRes

    End Sub
     
  2. eurojam

    eurojam Well-Known Member Licensed User

    I think you have to declare the return type:
    Code:
    Sub IIF(c As Boolean, TrueRes As String, FalseRes As Stringas string
     
    edm68, DonManfred and Erel like this.
  3. palmaf

    palmaf Member Licensed User

    Correct , Thanks Eurojam
     
Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice