Having Null Trouble 
I am trying to create a function that will pass out either....
The string that is passed in
or
"Null" (as a string)
problem is, i am having trouble passing Null into a function
if I try to pass in a Null String access really doesnt like it :0(
example
____________________________________
Function passString(Optional InputString As String) As String
If Len(InputString) <= 0 Then
passString = "Null" 'Supposed to be like this (NOT PassString = Null)
Else
passtring = "'" & InputString & "'"
End Function
rivate sub ATest()
Dim MyString as string
MyString = null
msgbox MyString
end sub
_____________________________________
Can anyone help, this shouldn't be this difficult. I must be losing it
____________________________________
I am trying to create a function that will pass out either....
The string that is passed in
or
"Null" (as a string)
problem is, i am having trouble passing Null into a function
if I try to pass in a Null String access really doesnt like it :0(
example
____________________________________
Function passString(Optional InputString As String) As String
If Len(InputString) <= 0 Then
passString = "Null" 'Supposed to be like this (NOT PassString = Null)
Else
passtring = "'" & InputString & "'"
End Function
rivate sub ATest()
Dim MyString as string
MyString = null
msgbox MyString
end sub
_____________________________________
Can anyone help, this shouldn't be this difficult. I must be losing it
____________________________________