Search This Blog

Thursday, July 9, 2015

link button property to open in new tab?

 By Adding following onClientClick even in your link button we can open the url in new tab.

OnClientClick="aspnetForm.target ='_blank';"

so on click it will call Javascript function an will open respective link in News tab.

<asp:LinkButton id="lbnkVidTtile1" OnClientClick="aspnetForm.target ='_blank';" runat="Server" Text="New Tab"  />

and another option is you can go for Hyper link control to achieve this. By default it has the Target property and you can set that to _blank.

thank you,

No comments:

Post a Comment

Restricting Custom People Picker to only one Sharepoint group programatically

Refer the following script files in your page,     <!-- For People Picker -->     <script type="text/javascript" src...