netbumbler
ISP
Hi all,
I'm pulling some data from the active user list table using the openschema function to enumerate the active user list. For example I'm trying to take each entry for 'login_name' and drop it to a text file. The problem is this: I'm trying to create a modified string that includes data from the openschema method with some other data - but when I write the line it adds line-feeds for each reference from the openschema function - THEN - when I do a len(.fields("login_name") it reports a length of 32 even though the visible result is only 'Admin'... there must be some additional characters appended to the end of the string - but my string manipulation skills in VBA are pretty thin. Can anyone help me decipher this? Code snip follows at the bottom.
Thanks,
Chris
set rst1 = cnn1.openschema(adschemaproviderspecific, , _
"{947bb102-5d43-11d1-bdbf-00c04fb92675}")
with rst1
do until .EOF
str3 = .Fields("login_name")
msgbox str3
rem note: will show 'admin'
msgbox len(Str3)
rem note: will show 32
str1 = date & ":" & .fields("login_name") & _
environ("USERNAME")
print #1, str1
.movenext
loop
end with
NOTE: results of the print command will be as follows:
03/04/2004 : Admin
chris
I'm trying to get the result to look like this:
03/04/2003 : Admin chris
I'm pulling some data from the active user list table using the openschema function to enumerate the active user list. For example I'm trying to take each entry for 'login_name' and drop it to a text file. The problem is this: I'm trying to create a modified string that includes data from the openschema method with some other data - but when I write the line it adds line-feeds for each reference from the openschema function - THEN - when I do a len(.fields("login_name") it reports a length of 32 even though the visible result is only 'Admin'... there must be some additional characters appended to the end of the string - but my string manipulation skills in VBA are pretty thin. Can anyone help me decipher this? Code snip follows at the bottom.
Thanks,
Chris
set rst1 = cnn1.openschema(adschemaproviderspecific, , _
"{947bb102-5d43-11d1-bdbf-00c04fb92675}")
with rst1
do until .EOF
str3 = .Fields("login_name")
msgbox str3
rem note: will show 'admin'
msgbox len(Str3)
rem note: will show 32
str1 = date & ":" & .fields("login_name") & _
environ("USERNAME")
print #1, str1
.movenext
loop
end with
NOTE: results of the print command will be as follows:
03/04/2004 : Admin
chris
I'm trying to get the result to look like this:
03/04/2003 : Admin chris