The simple answer is no - you cannot travel overland between Panama and Colombia, or vice versa. There is no road and no public transportation - the Pan American highway does not run through the Darien Gap region of Panama. The Darien Gap is huge region of primary rainforest that is both dangerous (due to the presence of guerrilla groups and drug traffickers) and almost completely impassable. If you had a guide, a security entourage and a humvee or motorbike, you might just be able to pass through the Darien Gap from Panama to Colombia, but almost certainly you have none of these, so here are some suggestions of how you can travel between Panama and Colombia.
Flights & Airpasses
The simplest option is to catch a flight from Panama City to either Cali, Medellin, Cartagena or Bogota. Try booking these flights with the airlines Copa, Avianca, Aerorepublica and Aires - they're really not so expensive. Aires is normally the cheapest - see the flights to Colombia section for more tips. If you have travelled from outside of the Americas to Latin America (eg. you're visiting from Europe), you should book these flights as an airpass as it's much cheaper than standard tickets. The type of airpass you want to book is called an "All America Airpass" (alterntively called a Hahn airpass).
Capurgana to Puerto Obaldia by scheduled boat
An alternative, cheaper and more adventurous route is as follows (described as if one is travelling from Colombia overland to Panama). Travel to Capurgana, which is on Colombia's Caribbean coast, close to the Panamanian border. To get to Capurgana you'll either need to catch a flight from Medellin, or you can travel overland by bus to Turbo (from either Medellin or Cartagena - neither route is 100% safe), from where it's a two hour boat trip (about $25) to Capurgana. There's some fantastic beaches in Capurgana so you'll probably want to spend a couple of nights. From Capurgana, you can catch a boat (relatively scheduled services for about $20 per person) for one hour to Puerto Obaldia in Panama. From Puerto Obaldia there are flights to Panama City with Aeroperlas for about $70 per person including taxes.
Travel from Capurgana via the San Blas Islands to Panama
From Capurgana, you should also be able to arrange a private chartered boat to take you to the San Blas Islands of Panama, from where you should be able to charter further boats through the San Blas islands until you reach one of the various airports there such as Mamitupo airport. This is quite a long route, and it's unlikely to be cheap unless you get lucky and hitch some rides, but it is extremely beautiful.
Cartagena to Panama & San Blas by Sailing Boat
It's increasingly popular to take a sailing tour from Cartagena through the beautiful San Blas Islands to Panama. This sailing trip is a very scenic 5 day tour - sailing boats usually depart when they have enough passengers wanting to travel. The cost is approximately $300 per person including food and board. Hostel Viena in Cartagena is well known as being a good source of information about skippers who offer such tours. Be warned that the boats that sail from Cartagena to Panama are of highly variable standards, and there are many reports of disasterous experiences, poor quality sleeping accommodation, crazy captains and even shipwrecks. Booking in advance is very difficult and you run this risk of finding yourself with a dodgy skipper - it's best to arrange such a sailing tour locally when you've scoped out the boat and it's skipper.