You really didn't provide enough information about the "2007 335i" for anyone to give you accurate pricing advice. Is it an E90, E92, or E93? Also, 45,000 miles is about average for a 2007.
If the car is a CPO'd E92 (Coupe), then you should be able to get it for under $25,500. FYI, the car will be worth around $21,000 wholesale (trade-in value) the minute you drive it off the dealer's lot.
2013 BMW 328i Sedan, 6MT, M-Sport
2004 BMW M3 Coupe, 6MT