Open the link in new window in crystal report

 ̄綄美尐妖づ 提交于 2019-11-28 12:38:56

Your Field contains a URL and if you want to make that URL as hyperlink in crystal report, it can be done.

Consider the following sample report, which contains search engine's names and their links



Now your requirement is to open Google by clicking www.google.com.
Right Click the field which you want to make Hyperlink, and select Format Field.
You will get the Format Editor as like the following image. Select Hyperlink tab and select Hyperlink Type as A Website on the Internet
Select the formula field in Hyperlink Information and use your column which has URL in it and save formula. Now press OK and Preview the report.



You could see the link opens when you press the Field. You can also change the font color of the field to show that is a LINK.

EDIT
{link}+'?sWindow=New'
Using '?sWindow=New' after your link may open your link new tab
Try this and get back with your results !

The report viewer has a property called HyperlinkTarget. Set it to "_blank" to open in a new window.

<CR:CrystalReportViewer ID="crvReportView" runat="server" AutoDataBind="true" HyperlinkTarget="_blank" />

add a target= "_blank" to your html tag i.e.:

<a href="default.asp" target = "_blank">HTML Tutorial</a>
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!