View Single Post
Old 05-26-2016, 08:13 AM
PlausiblyDamp's Avatar
PlausiblyDamp PlausiblyDamp is offline
Ultimate Contributor

Forum Leader
* Expert *
Join Date: Nov 2003
Location: Newport, Wales
Posts: 2,058

Your code assumes
If Not Rs.EOF Then
will never be false, if the line of code
Rs.Open("Select  * from Countries where Country like '" & Country_Name & "'", CN)
didn't have any matches the variable C_Code would never be assigned a value.
Intellectuals solve problems; geniuses prevent them.
-- Albert Einstein

Posting Guidelines Forum Rules Use the code tags
Reply With Quote