• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

how to copy code

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am a beginner and am interested in trying the code in many examples,but when I copy and then paste to 'TextPad' the code looses all formating. Can anyone suggest how I paste to my test editer so that I don't loose the Java formatting?
 
Ranch Hand
Posts: 4632
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
if you are talking about the many examples posted here (and other forums):
copy/paste the text into word first, then copy/paste from word to your editor
or
use mozilla as your browser - it preserves the formatting
 
Sheriff
Posts: 9109
12
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Welcome to JavaRanch, Dark! Please adjust your display name to meet the JavaRanch Naming Policy.
You can change it here.

Thanks!

I have run into this problem mostly when I'm copying code from an html page. To copy code (from a forum here), you can click on the quote marks and copy the code. Just remember to hit the back button when you're done copying the code. To copy code from another web page, you can click on "View" "Page Source".
 
reply
    Bookmark Topic Watch Topic
  • New Topic