Kal
04-01-2008, 11:09 AM
Hi guys I have the following function to replace specific charcters within a string. However it only seems to be replacing the character amphersands and not apostrophes.
Can anyone help me work out why my function doesn't work correctly.
Thanks
Function DataPrep(qwerty)
If NOT isNull(qwerty) then
DataPrep = Replace(qwerty, "'", "-")
DataPrep = Replace(qwerty, "&", "and")
End if
End Function
Code to call the function
DataPrep(rs("sitename"))
Can anyone help me work out why my function doesn't work correctly.
Thanks
Function DataPrep(qwerty)
If NOT isNull(qwerty) then
DataPrep = Replace(qwerty, "'", "-")
DataPrep = Replace(qwerty, "&", "and")
End if
End Function
Code to call the function
DataPrep(rs("sitename"))