Re: Updating Subject field using controls from message body
- From: "AndrewLivingston" <andrew@xxxxxxxxxxxxxxxxxxxxxxx>
- Date: 16 Jun 2006 04:57:57 -0700
Sue,
Had a look and I am still clueless. I think it's a sign that I have
huge holes in my knowledge of this kind of thing. I want to know
though!
The code I am using is:
Function Item_Send()
Item.UserProperties("UserSubject") = Item.UserProperties("QueryType") &
" - " & Item.UserProperties("Contact Name") & " - " &
Item.UserProperties("Site Name")
End Function
I changed the Subject field to UserSubject just so each of the fields
would be listed similarly.
Am I correct in assuming that the Function Item_Send() triggers upon
clicking the Send button?
What am I doing wrong?!?
Thanks for all your help!
Andrew
----------------------------------------------------------------------
Sue Mosher [MVP-Outlook] wrote:
You have the syntax for UserProperties correct, but you're using it for the wrong property. UserProperties is for custom properties like "Site Name" not built-in properties like Subject. For the latter, it's just Item.Subject. Take a look again at the page I suggested.
--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003
http://www.turtleflock.com/olconfig/index.htm
and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
http://www.outlookcode.com/jumpstart.aspx
"AndrewLivingston" <andrew@xxxxxxxxxxxxxxxxxxxxxxx> wrote in message news:1150285412.618546.66790@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Nope, I am thick...
My code is:
Function Item_Send()
Item.UserProperties("Subject") = "DES Query " & Item."Contact Name" & "
at "Item."Site Name"
End Function
I can tell that I am sure I haven't done the free text, but the field
names won't work either...
Many thanks for that.
After reading the primer and trying things out, I can't get it to work.
Basically, I have two fields that the user will fill in, SiteName and
ContactName, that I want to append to the Subject so to be able to
file, sort, and track. Something like:
DES Query from Andrew Livingston at Cheltenham Contact Centre on
09/06/06
Am I just thick?
Andrew
Sue Mosher [MVP-Outlook] wrote:
Put code in the Item_Send event handler:
Function Item_Send()
Item.Subject = "new subject"
End Function
See http://www.outlookcode.com/d/propsyntax.htm if you need a primer on reading field values.
--
.
- Follow-Ups:
- Re: Updating Subject field using controls from message body
- From: Sue Mosher [MVP-Outlook]
- Re: Updating Subject field using controls from message body
- From: AndrewLivingston
- Re: Updating Subject field using controls from message body
- References:
- Updating Subject field using controls from message body
- From: andrew
- Re: Updating Subject field using controls from message body
- From: Sue Mosher [MVP-Outlook]
- Re: Updating Subject field using controls from message body
- From: AndrewLivingston
- Re: Updating Subject field using controls from message body
- From: Sue Mosher [MVP-Outlook]
- Re: Updating Subject field using controls from message body
- From: AndrewLivingston
- Re: Updating Subject field using controls from message body
- From: Sue Mosher [MVP-Outlook]
- Updating Subject field using controls from message body
- Prev by Date: Re: Outlook form: Action Names in Action tab has been deleted after user preview the form
- Next by Date: Re: Updating Subject field using controls from message body
- Previous by thread: Re: Updating Subject field using controls from message body
- Next by thread: Re: Updating Subject field using controls from message body
- Index(es):