In my Dungeons and Dragons campaign, my co-players and I are having a little bit of a struggle with my character's feats. My character is a fighter(2)/ranger(2) dual class. For my fighter feat I chose Two Weapon Fighting, then I hit ranger level 2 which now grants me Combat Style. My DM says that I cannot choose Archer, and still perform the two weapon fighting feat, and that it is against my ranger code... But then he says I can select the two weapon fighting and still use a bow and choose bow feats, but the two weapon fighting feat i chose as a fighter cannot be changed. Can my ranger pick Combat Style Archer and still choose two weapon fighting feats?
Yes, your Ranger can select one Combat Style and still select feats that mimic the other.
In fact, I did similar things in the one time I played a Ranger to prove to others in my party you can have fun despite what class you are. In that particular case, I chose Two-Weapon Fighting Combat Style, and selected all the Archery feats. I used an Elvencraft Longbow, which allowed me to use my bow as a Quarterstaff.
There is absolutely no such "Ranger Code" in D&D 3.0 or 3.5 for that matter. If there is an in-game organization, such as the Rangers of the North in Middle-Earth, then that would be specific to your campaign/dungeonmaster. In other words, there is no Ranger Code outside of your DM saying there is one.
And any code that prohibits one form of combat when utilizing another is pretty strange. We all know of Bushido - the Code for the Samurai, but Samurai utilized a Yumi (bow) and Yari (spear), as well as their Katana (bastard sword) and Wakizashi (short sword).
I would ask, in detail, what this Ranger Code is, and why using a bow in addition to two weapons is such blasphemy. The Ranger class is weak enough as it is and gimping them on weapon choice only makes them that much weaker.
Assuming this "Ranger Code" is not a house rule set by your DM, there is nothing in the rules preventing you from picking the TWF feats with your normal feat slots as long as you qualify for them (Eg, Dex 15 for Two Weapon fighting). The actual feat is more powerful than the Ranger Combat Style, since it do not requires you to stay on light armor.
If your DM wants to ensue the "Ranger Code" in his table, there is still one option for you. You can retrain your Fighter feat into a ranged feat, and then use TWF from the Ranger Combat Style. Retraining rules are on the Player's Handbook 2, pg 192.
There is no such restriction, other than in house rules. Rangers get a combat style that permits them to make use of certain feats; there is no fluff that suggests a given ranger has some sort of conviction against fighting in other ways. It's merely a specialization that rangers can pick from.
Similarly, just because a wizard picks Spell Focus: Evocation with their wizard 5 feat slot doesn't mean they are suddenly unable to cast spells from all other schools.