Helper function problems

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Chumley the Walrus

    #1

    Helper function problems

    I'm trying to use a helper function inside a datalist control to
    simply display an image if it exists:
    <%
    Function ShowIm(sItem as string)
    If sItem <> "" Then
    response.write <img height=13 width=16 _
    src=((Container .DataItem("Imag esubprod1"))

    End If
    End Function
    %>
    <%# ShowIm(DataBind er.Eval(Contain er.DataItem, "Imagesubprod1" ))%>

    ...gives me an error:Statement cannot appear within a method body. End
    of method assumed. Not sure why this is happening.

    thanx
    Chum
Working...