Solved

Can ASP.Net 2.0 textbox handle superscript and subscript?

Posted on 2008-10-20
6
1,119 Views
Last Modified: 2012-06-27
Hello,

I am wondering if there is a way for multiline textboxes to accept superscipt as in x2 + y2 = . where the 2's display as exponents. If not, is there a third party component maybe that could do this?

Thank you
0
Comment
Question by:vstack
  • 3
  • 2
6 Comments
 
LVL 43

Expert Comment

by:TimCottee
ID: 22756211
Hello vstack,

You have a couple of options I guess. The simple answer is no however. The more complicated answer is that you can specify a specific font which allows the use of the extended characters that such as ?, ?, ? (Ascii Chr(251),(252) & (253)). Or implement an html textarea using something like freetextbox, fckeditor, obout editor, tinyMCE etc that can handle superscript etc.

Regards,

TimCottee
0
 
LVL 43

Expert Comment

by:TimCottee
ID: 22756221
And of course in this view they don't show as the actual characters! ¹ ³ ²
0
 

Author Comment

by:vstack
ID: 22756458
Thanks TimCotee,

I don't think the text editors like freetext will work for me but how did you do the trick with the 'show as the actual characters! ¹ ³ ²'?

How did you specify a specific font  to handle the superscript? Which font?

Thank you




0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 43

Accepted Solution

by:
TimCottee earned 500 total points
ID: 22756725
vstack,

That was using the RTF entry option rather than plain text here.

Here is an example of this, though it seems that I don't need to pick a particular font (sometimes you do, it just depends on what characters are available in what font).

x² + y² = z²

TimCottee
0
 

Author Comment

by:vstack
ID: 22757746
Thanks for the help.  I am not sure if what I am trying to accomplish is practically doable.  I wanted the user, me, to simply paste the Course Objectives section into a multiline text box, then I would save the textbox as a text file and read the newly created file line by line, pushing each line into the db as an objective.  This works fine and saves a gazillion lines of data entry.  Once our current batch of course info sheets, about 1200 is saved to db then all new info sheets would be developed inside this software.  No need to read any more files.  The only caveat is this special character thing.

Any suggestions?  

I'll award you the points anyway as I learned something new today which is always a good thing.

Thanks
0
 

Expert Comment

by:sobreiro01
ID: 22763619
Hi,

The asp.net text box, is redered as a "<input type="text>" tag in HTML.
Try to always thing in what is really the .NET components, once they are used on the web, so thay a in the reality HTML controls with some functionality added to make it work server side.

However, you can do anything with it, just thing in what you should do in HTML, and then, do it.
You can add attributes to the textbox by using AddAttributes method of the instance of the control you are working.

Hope this helps.
André Luiz Sobreiro
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
javascript window.createPopup() not working in chrome but works in IE browser 3 96
Please explain "Multi-Tenant Services" 5 60
Angular JS Route 3 44
Split in Javascript 5 30
Just a quick little trick I learned recently.  Now that I'm using jQuery with abandon in my asp.net applications, I have grown tired of the following syntax:      (CODE) I suppose it just offends my sense of decency to put inline VBScript on a…
One of the pain points with developing AJAX, JavaScript, JQuery, and other client-side behaviors is that JavaScript doesn’t allow for cross domain request for pulling content. For example, JavaScript code on www.johnchapman.name could not pull conte…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

947 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now