Regarding 2 (Auto mail. )
as per 1 question. i have created user defind field "Assigned To" - RQ_USER_01 and default field "Status" - RQ_REQ_REVIEWED
i need to send out the Auto mail to selected user in Assigned to list whenever status changed. i have added following code. it is asking msg that Please Email Sent but no mail.
please check code and let me know is there any mistake. not error is coming.. also i want to add in that any field changed, mail should triggered. please advice. thanks in advance.
Sub Req_FieldChange(FieldName)
On Error Resume Next
If (FieldName = "RQ_REQ_REVIEWED" )then
SendEmail 'Call the sub procedure
msgbox "Please Email Sent"
End If
On Error GoTo 0
End Sub
Sub SendEmail
Dim strSubject, strComment
strSubject = "Requriement change Notification for " & _
"Project " & TDConnection.ProjectName & _
" in domain " & TDConnection.DomainName
strComment = "The Requirement Status has been Changed to " & _
Req_Fields("RQ_REQ_REVIEWED").Value &_
" by the " & _
" user " & User.FullName
SendReq Req_Fields("RQ_REQ_REVIEWED"), _
Req_Fields("RQ_USER_01").Value,strSubject,strComment
End Sub
Sub SendReq (iObjectId, strTo, strCc, strSubject, strComment)
On Error Resume Next
Dim ReqFact,theReq
Set ReqFact = TDConnection.ReqFactory
Set theReq = ReqFact.Item(iObjectId)
msgbox "Please TO Value " & strTo
msgbox "Please CC Value " & strCc & _
" ,Subject " & strSubject & _
" ,Comment " & strComment
theReq.Mail strTo, strCc, 64, strSubject, strComment
On Error GoTo 0
End sub