Hi,
In my code below when i get to the line:
test2 = Evaluate({@If(@Contains(} & texty & {;"<division>");@ReplaceSubstring(} & texty & {;"<division>";"}+test1+{");"")}, sysdetsdoc)
SysDetsDoc.texty = test2
why am i getting a "Type Mismatch" error..can someone please advise how i can overcome this issue and will using SysDetsDoc.texty = test2 work as i am trying to return the values in the field for eg SysACO from the sysdetsdoc
Thanks in advance
My code below:
Dim texty As String
If test6(0) = "ACO" Then
texty = "SysACO"
Elseif test6(0) = "ACO PA" Then
texty = "SysACOPA"
Elseif test6(0) = "Admin Manager" Then
texty = "SysAM"
Else
texty = "SysAAM"
End If
Set staffname = tempdoc.GetFirstItem( "SMStaffName" )
contents = staffname.Text
If contents <> "" Then
test2 = Evaluate({@If(@Contains(} & texty & {;"<division>");@ReplaceSubstring(} & texty & {;"<division>";"}+test1+{");"")}, sysdetsdoc)
SysDetsDoc.texty = test2
test4 = Evaluate({@If(@Contains(} & texty & {;"<site>");@ReplaceSubstring(} & texty & {;"<site>";"}+test3+{");"")}, sysdetsdoc)
SysDetsDoc.texty = test4

Evaluate & Type Mismatch Error (Nadeem Shaikh 28.Jul.04)
. . 