Sounds like you might be mixing AWT components in your Swing application. AWT components will paint over top of Swing components.
If you need further help then you need to create a [url http://homepage1.nifty.com/algafield/sscce.html]Short, Self Contained, Compilable and Executable, Example Program[/url] (SSCCE) that demonstrates the incorrect behaviour, because I can't guess exactly what you are doing based on the information provided.
Don't forget to use the [url http://forum.java.sun.com/help.jspa?sec=formatting]Code Formatting Tags[/url] so the posted code retains its original formatting.
> i need a scroll pane in which i have variable no. of textareas and these text
> areas should have individual scrollers inside them.
can you add a textArea to a scrollpane?
can you add multiple scrollpane's to a panel?
can you add a panel to the contentPane?
if you can do the above, you should be able to add the panel to a scrollpane,
then add the scrollpane to the contentpane.
if this is all too much, post a small compilable/runnable program that
demonstrates your problem