473,326 Members | 2,095 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,326 software developers and data experts.

Readiing header files in vc++

105 100+
Hi all,

I have a defined existing class (created by my somebody) to read/write a header file that gives the description of an image. Now I have to read a header file and how can I utilise this class in my project to read header file.

How do I actually start??Start with a new project??Could anyone please guide me how to start utilising existing classes in VC++.Thanks in advance.
Mar 2 '07 #1
5 1605
lqdeffx
39
You could very well have multiple projects open and listed, which I believe you just have to select which project is the primary. So you could very well create your own and just add their project into yours, so to speak. Once that is situated, simple look at the API made available to you from this persons class.
Mar 2 '07 #2
mickey22
105 100+
Hi,

Thank you for your reply. But I dont understand what u mean by -- looking at the API from person's class.I have my own project and so I had to add the header files and .cpp associated with this class.Is that correct.But my question is where do I include header file name.I am actually new to vc++.I am sorry if I am asking too many questions.If you dont mind, could you please explain me little bit in detail.Thanks
Mar 2 '07 #3
lqdeffx
39
sorry, by API (application program interface) i meant all the public functions in that class that you were given. It would probably be simplier to just create your own project, include that person's files (.h & .cpp). then go from there. If you were to create an object of that person's class, it would show you what functions are available to you, mind you if you are using MSVC++. so for example it would look something to the effect:

Expand|Select|Wrap|Line Numbers
  1. // yourfile.cpp
  2.  
  3. // depending on what they have included, you might not need to include
  4. //  anything -- redundancy is bad
  5.  
  6. #include "otherpersonsfile.h"
  7. using namespace std
  8.  
  9. int main( void )
  10. {
  11.    otherperson foo;
  12.    // now using the object you can see what functions are available to you by
  13.    // by typing "foo" then "."
  14.  
  15.    return 0;
  16. }
  17.  
Mar 2 '07 #4
mickey22
105 100+
Hi,

Sorry for replying so late.Thank you for giving me the idea and I will try to start working in that way.Thank you once again.
Mar 5 '07 #5
mickey22
105 100+
Hi,

I have some prob.

Firstly I have added .h and .cpp file to my project which include the class I have to use.This class is used to read header file and they are functions which creates header file, loads them and saves them like createheader( ); etc.

My question is where should I specify header file name??

As u said I can create obj of this class say A in my project .can I do it in this way

A a;

using this object should I call createheader( ); ????

Could you please specify steps.Thanks a lot. I am little bit new to using VC++.
Mar 5 '07 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Massimiliano Alberti | last post by:
My program is heavily template based, and I use the VC++, so I have to keep the templates in the header file. My .cpp files are quite empty (they are more a connection between header files). Now,...
1
by: Glenn M | last post by:
I have visual c++ 6.0 and i want to use a function (setupuninstalloeminf) in setupapi.h that was not part of the original setupapi.h shipped with vsc++ but was added later. how do i go about...
2
by: Karthik | last post by:
When I try to compile my VC++ program (am Using VS6.0). I get the following error in a header file ATLCONV.H. c:\program files\microsoft visual studio\vc98\atl\include\atlconv.h(52) : error...
4
by: Andrew Ward | last post by:
Hi All, I was wondering if it is possible to use precompiled headers without having to include a <stdafx.h> or whatever in every source file. My problem is that I have a project that makes heavy...
1
by: Tom | last post by:
This has got to be something really simple, but I'm pretty baffled... In the header file I define the class interfaces, in the CPP file the class functions, and the CPP file #includes the...
9
by: Daniel | last post by:
Hi, While I compile my old C++ source in VC.Net, rebulild whole project, there are always some header files are unvaliable like "fstream.h", "Dxguide.h".....etc. Did VC.Net remove the VC++'s...
4
by: Agos | last post by:
I'm trying to learn VC++.NET. I used till now Borland C++ Builder 6. I had a program starting like this: #include <fstream.h> #define TEMP_FILES 200 ...... ....... fstream chunk_file; With...
9
by: chat | last post by:
Hi, every body. I have 3 files like this: -------------------------------------------------------- file name : header.h #ifndef TEST_H #define TEST_H int a=1; double b=0.5;
2
by: NvrBst | last post by:
I'm not too much of a C++ programmer but I have a bunch of C programs (they compile with GNU) and want to get them to compile in VC++ 2008. In Unix I go "./configure" and it makes a "Makefile". ...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.