If the program you want to use has a main(), then it's probably only for testing/demonstrating purposes. If yes just delete it, then use the functions/classes you need from it.
ok i did that (change the main to a function and call it when i run my program's main; added in header) but the Microsoft Visual studio doesnt not like finding where it is. i tried finding when compile look for additional directories, but it doesnt work. even if i put my project into the same directory. What is wrong??