大体如下:
dim str as string
if nz(me.上限.value,0)>0 then
str="出租价格>=" & nz(me.下限.value,0) & " and 出租价格<=" & me.上限.value
else
str="出租价格>=" & nz(me.下限.value,0)
end if
if nz(me.朝向.value,"")<>"" then
str=str & " and 房屋朝向='" & me.朝向.value & "'"
else
str=str & " and 房屋朝向='*'"
end if
Me.Form.Filter = str
Me.Form.FilterOn = True