What is the program that you are trying to install?
It is possible that that program is already in the Ubuntu repository. Edit the file /etc/apt/sources.list:
sudo gedit /etc/apt/sources.list
Find the lines about 1/2 way down that refer to the Universe repo. Remove the # at the beginning of the lines (there are comments that tell you what to do). Also, add the word multiverse at the end of that line. They should look somethinglike:
deb http://yourMirror.ubuntu.com dapper universe multiverse
deb-src http://yourMirror.ubuntu.com dapper universe multiverse
Now run "sudo aptitude update".
Open up the "Synaptic" package manager, and search for your program in there. Hopefully, it is, and you can just install it.
I hope this helps