|
in your headers, did you thought to well add such code :
<font color=blue>#if</font> !<font color=blue>defined</font> (__MY_HEADER_H_INCLUDED__)
<font color=blue>#define</font> __MY_HEADER_H_INCLUDED__
<font color=green>
<font color=blue>#endif</font> <font color=green>//__MY_HEADER_H_INCLUDED__</font>
TOXCCT >>> GEII power [toxcct][VisualCalc 2.20][VisualCalc 3.0]
|
|
|
|
|
No, i didn't add any such code.where should i add it.please tell in detail.
Ankush Mehta
|
|
|
|
|
i thought it was clear enough... it must round all your definitions in the header it is on...
so, the #if and #define must be before what you declare in the header (others #include can be before that, as they may have their own exclusive statements already) ans the #endif put at the end of the file...
if you have several headers in that case, choose different #define macros for each header, to avoid any problems...
you could look into any compiler header to see how to do...
TOXCCT >>> GEII power [toxcct][VisualCalc 2.20][VisualCalc 3.0]
-- modified at 5:39 Wednesday 14th December, 2005
|
|
|
|
|
well, please forgive me for asking rather stupid questions. i am a newbie.Let me restate what i have done.
the libraries msacc9.olb,excel9.olb provided by ms-office for automation are added to the project.These libraries contain header files msacc9.h & excel9.h. i include these header files at the top of the .cpp file of my application like this.
#include"msacc9.h"
#include"excel9.h"
Now, please give me directions to resolve the clash(classes like _Application are in both libraries)
Ankush Mehta
-- modified at 6:13 Wednesday 14th December, 2005
|
|
|
|
|
The directives that toxcct suggested you to add should enclose all the 'code' in all of your .h files. Are you using AppWizard to generate the files for new classes ? If yes, these directives are automatically inserted in your code.
So if this is the case, the problem is probably elsewhere. Then post the exat and COMPLETE error message.
|
|
|
|
|
|
yeah, toxcct you are right.
Following errors are generated:
error C2011: 'FormatConditions' : 'class' type redefinition
error C2011: 'Module' : 'class' type redefinition
error C2011: 'Modules' : 'class' type redefinition
error C2011: '_Application' : 'class' type redefinition
These classes exist in both the headers(but they have different definitions.e.g, _Application object is an open access db for access header file while _Application object for excel header file is an open excel).I have used appwizard to generate related files.These headers are provided by msoffice.
Any Ideas please......
Ankush Mehta
|
|
|
|
|
What line i am following................
i heard of namespace.as i am a newbie, i am not sure about this.at the top of my main .cpp file i tried using this:
namespace anyname1
{
#include "msacc9.h"
}
namespace anyname2
{
#include "excel9.h"
}
But this again didn't work out...
Seeking help......Please.........
Ankush Mehta
|
|
|
|
|
Please Guide how can i print a webpage in a console application. Actually i achieved printing using webbrowser control in dialog based application.Now i want to print in console application.
In other words,in dialog based application i used web browser control(Active X component), dragged it on my Dialog form & used its methods to achieve printing.
Now how can i achieve printing webpage in console based application.ShellExecute won't work to print a webpage(neither in dialog-based nor in console), it is confirmed.
Please Guide... It is a bit urgent
Ankush Mehta
|
|
|
|
|
In VC++ , property pages are of three types - small, medium, large.
I have no of properties to set for activex control for which the specified
size property page is not suffient. So how to increase the size of the property page while creating activex control.
|
|
|
|
|
Sac87Rak wrote: In VC++ , property pages are of three types - small, medium, large.
What do you mean by this? As it's just a dialog box, a property page can be made any size you want. The size of the property sheet, however, is governed by the size of the largest property page.
"Take only what you need and leave the land as you found it." - Native American Proverb
|
|
|
|
|
Sir,
I am writing a activex control and it has lots of properties.
I can't put all these properties on same page so for that i want big
property page in which i can put all properties of the control in same
property page.
sachin
|
|
|
|
|
Sac87Rak wrote: I am writing a activex control and it has lots of properties.
Ok, but I still fail to see the problem.
Sac87Rak wrote: I can't put all these properties on same page so for that i want big
property page in which i can put all properties of the control in same
property page.
This makes no sense. First you say that you can't put all of the properties on the same page, then you say that you want to put all of the properties on the same page. Which is it?
"Take only what you need and leave the land as you found it." - Native American Proverb
|
|
|
|
|
Thank u sir,
I got a solution, i can increase size of property page but it gives warning
: saying that property page is not of standard page size'
Any way thanks for ur help
Sachin
|
|
|
|
|
I've never seen such a message. Does it come from within MFC?
"Take only what you need and leave the land as you found it." - Native American Proverb
|
|
|
|
|
yes it comes from MFC when we compile our application with property page's size greater than specified sizes
|
|
|
|
|
Then it should be easy enough to track down and see what conditions are causing it to be displayed.
"Take only what you need and leave the land as you found it." - Native American Proverb
|
|
|
|
|
I had dervied a class from CFileDialog in VC 6.0 and it show the file name as editbox. Now when I shifted it to VC 7.1, it shows a white rectangle there. I cant enter anything. I have seen its classtype it is ComboBoxEx32. What should I do for its solution ??? ... Moreover, I have gone through the articles here and found not much help.
|
|
|
|
|
Ibraheem Khan wrote: What should I do for its solution ???
I don't understand the problem. How does the filename box being a combobox instead of an edit control change things?
"Take only what you need and leave the land as you found it." - Native American Proverb
|
|
|
|
|
Hi,
I am working on writing a MFC application supporting both container and server of compound document. After I inserted my object into Microsoft word, I also inserted another compound server object(for example Microsoft equation 3.0) into my object. But, after i edited a equation and got back to word, if i want to edit the equation object again, the equation was gone. And the system pop up a message box which say "unable to update client".
However, if I inserted my oject into Microsoft Excel/Power Point and do the same thing as above, everything is ok.
Why a nested compound document work well in Microsoft excel/power point but not Microsoft word?
Moreover, if i insert a Microsoft wordpad object into Microsoft word, and then insert a microsoft panint object into this Microsoft wordpad object, there are the same error like my compound document object.
Does anyone can help me in this regard?
ddzhou
|
|
|
|
|
Hi
I have an application in which i am using the SHChangeNotifyRegister API to get the file system events. If I perfome file operations in the network path I am not getting any notifications. Can anyone help me in this regard.
Thanks in advance
-- modified at 3:27 Wednesday 14th December, 2005
|
|
|
|
|
i have a question ??
how do u specify the directory path in SHChangeNotifyRegister ??
i mean,
if i have 3 drives, C: D: and E:
how do i receive notification only from D: ???
Try using FindFirstChangeNotification / FindNextChangeNotification / FindCloseChangeNotification
set of API's.
try specifying the network path.
i am not sure whether this will work, but just give it a shot.
Deep George Zachariah.
|
|
|
|
|
Thanks . obviously you cannot give the network path in the APi. I gave CSIDL_DRIVES i am getting notifications from all the local drives. but if i connect to a network system and perform file operations I am not getting the notification.
|
|
|
|
|
I have created one Combo box and one List Box in the dialogbox in Visual Studio.
I am working in Visual C++.NET framework.
now I want to access these controls in to the file, then how do I get the control over them? means objects?
and in the list box I have a browse button also, on clicking that button the folders (As in windows) shoulds be opened. Can anyone sent the code for that?
Thank you
|
|
|
|
|
i did not get the first part of ur question.
anyways, here is the code to display the open dialog box.
NOTE:
this is vc++ SDK (win32) code. i dont know whether u can use the same code in vc++.net
but i think there would only be minor differences.
OPENFILENAME opn;
TCHAR lpszFile[255];
TCHAR lpszFileTitle[255];
HWND hWndOwner; // handle of the owner window.
HINSTANCE hInst; // instance handle of the application.
opn.lStructSize = sizeof(opn);
opn.hwndOwner = hWndOwner;
opn.hInstance = hInst;
opn.lpstrFilter = "All Files (*.*) ";
opn.nFilterIndex = 0;
opn.lpstrTitle = "Open Dialog";
opn.Flags = OFN_EXPLORER;
opn.lpstrFile = lpszFile;
opn.nMaxFile = 255;
opn.lpstrFileTitle = lpszFileTitle;
opn.nMaxFileTitle = 255;
GetOpenFileName(&opn);
Deep George Zachariah.
|
|
|
|