SSRS 2008 R2用于Outlook邮件的URL操作链接

时间:2017-02-22 11:11:29

标签: url reporting-services action ssrs-2008-r2 mailto

我在SSRS 2008中有一个动作网址作为表达式,因此它会打开Outlook并显示一条消息:

="mailto:" & "emailaddress@here" & "?subject=" & "Project Name " & 
Fields!ReferenceNo.Value & "&body=" & "Hi All," + vbcrlf + 
"Please review your outstanding task/s please for " & 
Fields!ReferenceNo.Value & "." & vbcrlf & "Thank you" & vbcrlf & 
"http://sql01/reportserver?%Folder1%2fReport1&rs:Command=Render&Ref=" & 
Fields!ReferenceNo.Value 

电子邮件显示正常,但不会显示附加了正确Fields!ReferenceNo.Value的网址链接。它似乎停在Report1而没有附加

enter image description here

如果我将链接与邮件正文分开运行,请手动输入引用,或者从mailto开始排除表达式。只是当我尝试追加它不起作用的Fields!ReferenceNo.Value时。

1 个答案:

答案 0 :(得分:1)

尝试转义您的网址:

="mailto:" & "emailaddress@here" & "?subject=" & "Project Name " & 
Fields!ReferenceNo.Value & "&body=" & "Hi All," + vbcrlf + 
"Please review your outstanding task/s please for " & 
Fields!ReferenceNo.Value & "." & vbcrlf & "Thank you" & vbcrlf & 
System.Uri.EscapeDataString("http://sql01/reportserver?%Folder1%2fReport1&rs:Command=Render&Ref=") & 
Fields!ReferenceNo.Value 

如果有帮助,请告诉我。