P
Preston
Hi,
I was wondering if someone here might be able to give a hand to something
I am trying to accomplish. I am trying to write logic to go into an email in
a given folder (resume folder) in my inbox and parse out the applicants name
based on the body contents of the email. I have been able to get the name out
without too much trouble and now want to be able to create a userproperty for
each mailitem parsed and set that property to the name of the applicant.
Ultimately, this will allow me to see the applicants name in the fields
columns. Here is what I have tried.
'map object to subfolder i want and for each mailitem, get and set the
userproperty
'i have left out the string parsing logic and put the string in strName
'e.g.
For each message in mySubFld.items
message.userproperties.add "ApplicantName", olText
message.userproperties("ApplicantName") = strName
next message
'i have also tried the following:
for each message in mySubFld.Items
set myProp = message.userproperties.add("ApplicantName", olText)
myProp.value = strname
next message
neither of these give me any errors but they just don't work. i go back and
run this:
for each message in mySubFld.Items
debug.print message.userproperties.count
next
and get all 0's ?? i'm not sure what's going on here but for some reason
these user properties aren't persistent. They just go away? I get a new field
in the "user-defined fields for this folder" list to add to my columns but it
isn't populated with anything.
Thank you for any help that you can give![Smile :) :)](/styles/default/custom/smilies/smile.gif)
Preston
I was wondering if someone here might be able to give a hand to something
I am trying to accomplish. I am trying to write logic to go into an email in
a given folder (resume folder) in my inbox and parse out the applicants name
based on the body contents of the email. I have been able to get the name out
without too much trouble and now want to be able to create a userproperty for
each mailitem parsed and set that property to the name of the applicant.
Ultimately, this will allow me to see the applicants name in the fields
columns. Here is what I have tried.
'map object to subfolder i want and for each mailitem, get and set the
userproperty
'i have left out the string parsing logic and put the string in strName
'e.g.
For each message in mySubFld.items
message.userproperties.add "ApplicantName", olText
message.userproperties("ApplicantName") = strName
next message
'i have also tried the following:
for each message in mySubFld.Items
set myProp = message.userproperties.add("ApplicantName", olText)
myProp.value = strname
next message
neither of these give me any errors but they just don't work. i go back and
run this:
for each message in mySubFld.Items
debug.print message.userproperties.count
next
and get all 0's ?? i'm not sure what's going on here but for some reason
these user properties aren't persistent. They just go away? I get a new field
in the "user-defined fields for this folder" list to add to my columns but it
isn't populated with anything.
Thank you for any help that you can give
![Smile :) :)](/styles/default/custom/smilies/smile.gif)
Preston