Solved

Opening a PDB ( C++ Program Data Base )

Posted on 2004-05-01
10
4,372 Views
Last Modified: 2007-12-19
I am looking for a tool to open and view the contents of a PDB file. ( Preferrably not the C++ product itself ).
0
Comment
Question by:greatscott
  • 5
  • 4
10 Comments
 
LVL 19

Expert Comment

by:mrwad99
ID: 10967842
You could always use notepad (drag and drop) but I think you are after something a little more advanced....
0
 

Author Comment

by:greatscott
ID: 10972758
I am looking for something more sophisticated. Just to confirm: a PDB file contains program source code?
0
 
LVL 19

Expert Comment

by:mrwad99
ID: 10972849
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
Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

 

Author Comment

by:greatscott
ID: 10972882
Then perhaps I am going down the wrong road. What does contain source code for C++ in Visual Studio?
0
 
LVL 19

Expert Comment

by:mrwad99
ID: 10973307
.cpp and .h files.....
0
 
LVL 2

Expert Comment

by:anupvijay
ID: 10988108
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
 

Author Comment

by:greatscott
ID: 10988227
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
 
LVL 19

Expert Comment

by:mrwad99
ID: 10989334
>> 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
 

Author Comment

by:greatscott
ID: 10989848
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
 
LVL 19

Accepted Solution

by:
mrwad99 earned 50 total points
ID: 10989878
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

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
XCode crashes while uploading to app store. 5 263
Problem to save 10 167
Using ANSI C how to Read a .csv file 10 81
Why is compiler in oracle server ? 9 66
Have you thought about creating an iPhone application (app), but didn't even know where to get started? Here's how: ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ Important pre-programming comments: I’ve never tri…
Preface I don't like visual development tools that are supposed to write a program for me. Even if it is Xcode and I can use Interface Builder. Yes, it is a perfect tool and has helped me a lot, mainly, in the beginning, when my programs were small…
The goal of this video is to provide viewers with basic examples to understand how to use strings and some functions related to them in the C programming language.
Video by: Grant
The goal of this video is to provide viewers with basic examples to understand and use for-loops in the C programming language.

832 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question