-1

I am working on a Work Order Management system, where a user creates a work order, hits the insert button, and after validating the fields I am sending an email.

In the body of the email I would like for the value from a textbox to be clickable via a link (the value is the Work Order Number)

 mm.Body = "WorkOrderNumber" + ":  " + 
"<a href=\"http://someserver/WorkOrderMgnt/ViewAllWorkOrders.aspx\"></a>"
+TextBox13.Text 
+"<-Click on the Work Order Number"
    mm.IsBodyHtml = true;

I don't get a link to click in the email. What I am doing wrong?

Brendan Green
  • 11,676
  • 5
  • 44
  • 76
ExpertWannaBe
  • 117
  • 3
  • 17

1 Answers1

1

As it stands, your output is this:

WorkOrderNumber: <-Click on the Work Order Number

Your hyperlink doesn't output anything to click.

This

mm.Body = "WorkOrderNumber" + ": &nbsp;" + 
    "<a href=\"http://someserver/WorkOrderMgnt/ViewAllWorkOrders.aspx\"></a>"
    +TextBox13.Text 
    +"<-Click on the Work Order Number"

Needs to include the work order number inside the <a></a> tags.

mm.Body = "WorkOrderNumber" + ": &nbsp;" + 
    "<a href=\"http://someserver/WorkOrderMgnt/ViewAllWorkOrders.aspx\">" 
    + TextBox13.Text + "</a>"
    + "<-Click on the Work Order Number"
Brendan Green
  • 11,676
  • 5
  • 44
  • 76