Connection Problem

Today I installed LAMP, then owncloud, when i try to connect to my owncloud with the router ip it connects fine, but if i try to use its IP or my DNS it doesnt want to connect, just says
"Access Error: 404 -- Not Found" i checked all the steps and everything seems to work, anything else i should try?

Error 404 already indicates that you reach a webserver, so your network setup is probably correct. I suspect that you reach different virtual hosts via IP and via DNS name. Can you share your apache-config?