Home > ASP Development > Simple one

Simple one



hi,



i have a column called Country and the records are blank when its U.S.A



when i retrieve them i have this code



and when i do Response.write residentcountry its blank can someone tell me whats wrong







residentcountry=rs("Country")



if residentcountry="" then

residentcountry="U.S.A"

End if



Response.write residentcountry





thanks,



charles

    
Guest


it's probably NULL, not empty. such code will solve this:


Code:


residentcountry = rs("Country")
If (IsNull(residentcountry)) Or (residentcountry="") Then
residentcountry = "U.S.A"
End If
Response.write residentcountry



Was this answer helpful ? Yes No   
Guest


thanks shadow forgot abt isnull



have a nice day



charles

Was this answer helpful ? Yes No   
Guest
 
 
Home - About Infoqu - Contact - Privacy Statement - Link to Infoqu - Bookmark Infoqu

Copyright 2007-2008 by Infoqu. All rights reserved