Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Calculating pixels of a string
Message
From
16/05/2010 13:26:07
 
 
To
All
General information
Forum:
ASP.NET
Category:
Other
Title:
Calculating pixels of a string
Environment versions
Environment:
VB 9.0
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
MS SQL Server
Application:
Web
Miscellaneous
Thread ID:
01464824
Message ID:
01464824
Views:
99
Has anyone ever found a routine that would calculating the amount of pixels a certain string takes? If you look at this site http://www.groupeacadia.com, you will see that the next upcoming seven events are having a title at the top of each entry. For most of them, the title is too long. So, we have to cut it and add ... at the end. However, no matter the formula I am using, there could always be a possibility that a certain string will wrap on two lines. This is what we are trying to avoid. So, if we could calculate the amount of pixels that it takes, we could then remove one character at a time until it fits.
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Next
Reply
Map
View

Click here to load this message in the networking platform