You've printed
strSQL
but it's
sql
that is not correct
sql="select ID,PICS from table1 where ID="& val(Combo ) &"
the bit I've underlined should not be there
For the 2nd part of your problem see micke.andersson's solution above - there are plenty of examples around