• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 5044
  • Last Modified:

Opening a PDB ( C++ Program Data Base )

I am looking for a tool to open and view the contents of a PDB file. ( Preferrably not the C++ product itself ).
0
greatscott
Asked:
greatscott
  • 5
  • 4
1 Solution
 
mrwad99Commented:
You could always use notepad (drag and drop) but I think you are after something a little more advanced....
0
 
greatscottAuthor Commented:
I am looking for something more sophisticated. Just to confirm: a PDB file contains program source code?
0
 
mrwad99Commented:
A PDB file contains debug information only; as far as I know it does not contain source code.  You will not find anything useful there as far as I know.
0
Live webcast with Pinal Dave

Pinal Dave will teach you tricks to help identify the real root cause of database problems rather than red herrings. Attendees will learn scripts that they can use in their environment to immediately figure out their performance Blame Shifters and fix them quickly.

 
greatscottAuthor Commented:
Then perhaps I am going down the wrong road. What does contain source code for C++ in Visual Studio?
0
 
mrwad99Commented:
.cpp and .h files.....
0
 
anupvijayCommented:
If you mean the source code in binary after compilation.....then they would be in .obj files.
But you can't open it in notepad or any editor (u can in hex editors!).

What is that you actually are looking for ?
A few more details please.....

Cheers.
0
 
greatscottAuthor Commented:
I am looking to find source code files for C++. The PDB files have a header: Microsoft C/C++ MSF 7.00. So I'm looking for the source code. I'm looking for confirmation that the source code isn't in the PDB files. As I understand it, source code for C++ from Micorosoft is in .CPP and .H files.
0
 
mrwad99Commented:
>> But you can't open it in notepad or any editor (u can in hex editors!).

You can open *any* file within notepad, as long as security allows it and it is not in use or protected in some way.  Doing so to an object file will not produce meaningful results, but you can still see what is in it..

The pdb file does contain some elements of source code, but it is that mangled that it will not be of any real use I would imagine.  Just open one in notepad and see.

Either way, if you are looking to get complete source code for a piece of software from a pdb file, put simply it is just not going to happen.  Best way to go is to get the source code itself :)
0
 
greatscottAuthor Commented:
Thanks. Can you confirm that the header: "Microsoft C/C++ MSF 7.00" validates that the product was compiled in C? or could the VB compiler use that header in PDB files as well?
0
 
mrwad99Commented:
I would imagine so.  I would not imagine that a VB compiler would add that to a pdb file; it would not make sense.  Read more about pdb files at http://www.jorgon.freeserve.co.uk/Other/pdb.htm
0

Featured Post

Never miss a deadline with monday.com

The revolutionary project management tool is here!   Plan visually with a single glance and make sure your projects get done.

  • 5
  • 4
Tackle projects and never again get stuck behind a technical roadblock.
Join Now