Unable to wrap link in asp.net hyperlink control

Hi All,

I have below code

<div id="idLinkdiv">
<asp:hyperlink id="lnkbutton1" runat="server" Target="_blank"></asp:Hyperlink>

Open in new window

navigateurl and text is being populated from DB on server side. The url is very large and I am unable to wrap it in the control.
I tried few options but doesn't seem to work.

How to go about this?  Thanks for your time.
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Miguel OzSoftware EngineerCommented:
Could you be more specific about the size of both URL and text and what are your target browsers?

Note: Typically URL should be less than 2000 characters to work with most browsers (typically IE 11) as recommended here
IE 11 accepts longer URLs, but most search engines like URLs < 2048 chars.
JyozealAuthor Commented:
IE9 is my target browser and chrome 40 is optional. URL may not be more than 2000. Max limit set for URL is 1000.
 Text and URL are both same. Thank you.
Miguel OzSoftware EngineerCommented:
IF your text is the same as the URL then there is no blank space, thus the reason the text can not wrap.
Possible solution: Provide a text with blank space that explains what is the purpose of the link.
Determine the Perfect Price for Your IT Services

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden with our free interactive tool and use it to determine the right price for your IT services. Download your free eBook now!

JyozealAuthor Commented:
Thanks for your comments. But that is not the requirement. I have to show the link directly and upon clicking it should open in new window. I can show first few characters like 100 characters and show ellipsis and upon hovering show full link in tool tip. But not sure how to go about that!
JyozealAuthor Commented:
.wraplinkclass {display:block;word-wrap:break-word;word-break:break-all;}

I applied above class and this seemed to work.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
JyozealAuthor Commented:
This worked.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.