Current location: Hot Scripts Forums » Programming Languages » ASP.NET » Form text to image


Form text to image

Reply
  #1 (permalink)  
Old 09-28-10, 10:31 AM
bluerocker bluerocker is offline
New Member
 
Join Date: Sep 2010
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Form text to image

I was not sure how to describe what was going on in this site but I am looking for direction to do what this web page is doing. I need to be able to have a customer type characters into a text field and then for it to appear on a straight or curved line. Then, if the customer likes it, they can add that info to their order.

Im not looking for any shopping cart info, just the form field to a type on a curve function. Any direction would be greatly appreciated. Anyone interested in doing the program is welcome to email me with a price to do so as well.

Thank you,

QuickShip Aluminum Survey Caps for Rebar | Ships in two business days
Reply With Quote
  #2 (permalink)  
Old 09-28-10, 02:59 PM
Yeroon's Avatar
Yeroon Yeroon is offline
Code Master
 
Join Date: Aug 2007
Location: Netherlands, Nijmegen
Posts: 850
Thanks: 2
Thanked 20 Times in 20 Posts
Hi,

I am very poor at math when it comes to writing function for circles etc, so hope you dont need help on that part.

here a very crude sample to give you an idea what to look for. The idea is you have a basic image that your draw letters on. Save it as some temp image and show to the user. If you have a fixed number or maximum number of letters the math gets easy though. So if you could be more specific about your specific need I can come up with something a little more sophisticated. This link is about creating an analog clock. it could also help you further:

Analog Clock Samples and examples - C#, VB.NET, ASP.NET

Code:
Bitmap myBitmap = new Bitmap(Server.MapPath("~/image.jpg"));
            Graphics g = Graphics.FromImage(myBitmap);
            string s = "s,o,m,e,l,e,t,t,e,r,s";
            g.TranslateTransform(100,100, MatrixOrder.Append);
            int rotate = 0;
            
            foreach (string letter in s.Split(",".ToCharArray()))
            {
                
                g.RotateTransform(rotate);
                g.DrawString(letter, new Font("Tahoma", 40), Brushes.Black, new PointF(10, 10));
                rotate = rotate + 10;
            }

            
            
            myBitmap.Save(Server.MapPath("~/image4.jpg"));
__________________
Feel free to thank people if they help you by clicking thanks at a post.
=================================
Make it idiot proof and someone will make a better idiot.
=================================
Realise the impotence of proof reading everything you publish
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
raw text in form translated into HTML in DB? Orid PHP 2 04-03-09 03:50 PM
mouse over image and text script Hank Script Requests 0 11-21-06 10:37 AM
Draggable Tables Ares JavaScript 10 08-03-06 06:55 AM
Copy body text into form text box simon@edgehillcu JavaScript 11 03-30-06 04:53 AM
add text to image... ygeordy JavaScript 1 09-27-05 05:54 PM


All times are GMT -5. The time now is 02:46 PM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.