ali_p,
It all depends on how the username & password are prompted.
There are a few methods of authentication out there, there is HTTP authentication, where your web browser pops up a window asking for the username & password, and you have an OK and Cancel Box, if you hit cancel, it says something to the effect of '401/Unauthorized'.
If this is the method that you are trying to bypass, you can send the username & password via clear text in the url:
http://username:password@url.com/
This would be the case for standard HTAccess style security.
If it is the case where the username & password is embedded in the webpage, that is a completely different topic.
It would be helpful to post the URL where you are grabbing the information from IF its an embedded user/password script (like facebook uses, for instance).
If you can't post the website URL, post the information between <form> and </form> (be sure to use [code] and [/code] tags when posting this).
From this we might be able to point you in the right direction.
Best of luck.