|
Sorry, there was a misunderstanding, my replies were for chandu004 and his fprintf approach.
Anyway, I dont know why ODBC behave that way. But why don't you use COM ?
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
|
|
|
|
|
i know chadu,s approch was not correct. actually i am not much more comfertable with COM
so i had tried to do it throgh odbc.
thank u
|
|
|
|
|
Well I think CP article search engine may help you [^].
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
|
|
|
|
|
yes master,
i agree to all of your points and iam aware of them.
for some applications, where the requirement is only to see the data in excel, i use this lite weight technique. and iam aware that, it has its own side effects. thats why i quoted in my post that, "here is a technique but iam not sure weather it is useful for your requirement".
and your explanation
CPallini wrote: You're simply writing a text file (that Excel can import, of course).
was impressive.
thank you.
--------------------------------------------
Suggestion to the members:
Please prefix your main thread subject with [SOLVED] if it is solved.
thanks.
chandu.
|
|
|
|
|
Hi chandu004
How are you?
|
|
|
|
|
Hi, I have a class derrived from CEdit. I need to resize it when it reaches its max text limit in order to accomodate the new character. But if I incremant it by a fixed size there is a problem. As each character is taking different space. like 'l' , '.' and '2' wiil require different space. So a constant number doesen't fit the bill. Also when I press backspace the Edit control should decreament by exact size required by the chartacter (I fill this is somewhat more difficult as you need to know the size of a character) back space is going to delete.Please help if anybody has the solution.
|
|
|
|
|
Hi,
use MoveWindow to Change the size.
thanks,
Nitheesh
|
|
|
|
|
Hi,
We have created a dialog based application in vc 8 for excel automation (Excel 2003). When we are using the wrapper class, we are getting the following errors.
------ Build started: Project: AutoProject2, Configuration: Debug Win32 ------
Compiling...
AutoProject2.cpp
AutoProject2Dlg.cpp
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(1219) : error C2371: 'FontPtr' : redefinition; different basic types
e:\program files\microsoft visual studio 8\vc\include\comdef.h(312) : see declaration of 'FontPtr'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(1297) : error C2786: 'BOOL (__stdcall *)(HDC,int,int,int,int)' : invalid operand for __uuidof
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(1297) : error C2923: '_com_IIID' : 'Rectangle' is not a valid template type argument for parameter '_Interface'
e:\program files\microsoft visual studio 8\vc\platformsdk\include\wingdi.h(3514) : see declaration of 'Rectangle'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(1297) : error C3203: '_com_IIID' : unspecialized class template can't be used as a template argument for template parameter '_IIID', expected a real type
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(1301) : error C2786: 'BOOL (__stdcall *)(HDC,int,int,int,int,int,int,int,int)' : invalid operand for __uuidof
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(1301) : error C2923: '_com_IIID' : 'Arc' is not a valid template type argument for parameter '_Interface'
e:\program files\microsoft visual studio 8\vc\platformsdk\include\wingdi.h(2765) : see declaration of 'Arc'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(1301) : error C3203: '_com_IIID' : unspecialized class template can't be used as a template argument for template parameter '_IIID', expected a real type
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(1308) : error C2371: 'PicturePtr' : redefinition; different basic types
e:\program files\microsoft visual studio 8\vc\include\comdef.h(326) : see declaration of 'PicturePtr'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(1689) : error C2504: '_IMsoDispObj' : base class undefined
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(1731) : error C2504: '_IMsoDispObj' : base class undefined
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(1833) : error C2504: '_IMsoDispObj' : base class undefined
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(1852) : error C2146: syntax error : missing ';' before identifier 'GetRGB'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(1852) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(1852) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(1852) : warning C4183: 'GetRGB': missing return type; assumed to be a member function returning 'int'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(1854) : error C2061: syntax error : identifier 'MsoRGBType'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(2189) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(2189) : warning C4183: 'GetTransparencyColor': missing return type; assumed to be a member function returning 'int'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(2191) : error C2061: syntax error : identifier 'MsoRGBType'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(2235) : error C2061: syntax error : identifier 'MsoRGBType'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(2237) : error C2061: syntax error : identifier 'MsoRGBType'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(2246) : error C2504: '_IMsoDispObj' : base class undefined
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(2335) : error C2504: '_IMsoDispObj' : base class undefined
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(2453) : error C2504: '_IMsoDispObj' : base class undefined
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(2579) : error C2504: '_IMsoDispObj' : base class undefined
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(5491) : error C2011: 'Font' : 'struct' type redefinition
e:\program files\microsoft visual studio 8\vc\include\comdef.h(310) : see declaration of 'Font'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(7783) : warning C4003: not enough actual parameters for macro 'DialogBoxW'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(7783) : error C2059: syntax error : ','
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(17141) : error C2011: 'Picture' : 'struct' type redefinition
e:\program files\microsoft visual studio 8\vc\include\comdef.h(324) : see declaration of 'Picture'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(18104) : error C2146: syntax error : missing ';' before identifier 'Scripts'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(18104) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(26976) : error C2059: syntax error : '('
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(26976) : error C2059: syntax error : ')'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(26976) : error C2143: syntax error : missing ')' before '|'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(26976) : error C2143: syntax error : missing ')' before '|'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(26976) : error C2143: syntax error : missing ';' before '|'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(26976) : error C2059: syntax error : ')'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(26976) : error C2059: syntax error : ')'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(26976) : error C2238: unexpected token(s) preceding ';'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(30578) : error C2146: syntax error : missing ';' before identifier 'MailEnvelope'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(30578) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(30578) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(30598) : error C2146: syntax error : missing ';' before identifier 'Scripts'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(30598) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(30598) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(30980) : error C2146: syntax error : missing ';' before identifier 'GetScripts'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(30980) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(30980) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(30980) : warning C4183: 'GetScripts': missing return type; assumed to be a member function returning 'int'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(31000) : error C2146: syntax error : missing ';' before identifier 'GetMailEnvelope'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(62897) : warning C4183: 'GetMailEnvelope': missing return type; assumed to be a member function returning 'int'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(63522) : error C2146: syntax error : missing ';' before identifier 'HTMLProject'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(63522) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(63522) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(63532) : error C2146: syntax error : missing ';' before identifier 'CommandBars'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(63532) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(63532) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(63576) : error C2146: syntax error : missing ';' before identifier 'VBProject'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(63576) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(63576) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(63578) : error C2146: syntax error : missing ';' before identifier 'Permission'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(63578) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(63578) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(63580) : error C2146: syntax error : missing ';' before identifier 'SharedWorkspace'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(64067) : error C2146: syntax error : missing ';' before identifier 'GetHTMLProject'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(64067) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(64148) : warning C4183: 'GetSync': missing return type; assumed to be a member function returning 'int'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(64160) : error C2146: syntax error : missing ';' before identifier 'GetSmartDocument'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(64160) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(64160) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(64160) : warning C4183: 'GetSmartDocument': missing return type; assumed to be a member function returning 'int'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(64161) : error C2146: syntax error : missing ';' before identifier 'GetDocumentLibraryVersions'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(64161) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(64161) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(64161) : warning C4183: 'GetDocumentLibraryVersions': missing return type; assumed to be a member function returning 'int'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(68608) : error C2146: syntax error : missing ';' before identifier 'GetNewWorkbook'
f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(68608) : fatal error C1003: error count exceeds 100; stopping compilation
Generating Code...
Build log was saved at "file://f:\Sangeetha\AutoProject2\AutoProject2\Debug\BuildLog.htm"
AutoProject2 - 222 error(s), 34 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========<base href="http://mail.tessolve.com/cgi-bin/webmail/">
How to correct these errors?
Thanks in advance,
Sangeetha. J
With Regards,
Sangeetha.
|
|
|
|
|
25, M, Ind.
Nobody can give you wiser advice than yourself. - Cicero
.·´¯`·->Rajesh<-·´¯`·.
Codeproject.com: Visual C++ MVP
|
|
|
|
|
How to do excel automation using vc++ 8?
With Regards,
Sangeetha.
|
|
|
|
|
Sangeetha_J wrote: f:\sangeetha\autoproject2\autoproject2\debug\excel.tlh(1219) : error C2371: 'FontPtr' : redefinition; different basic types
See here.
"Love people and use things, not love things and use people." - Unknown
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Hi David,
Am getting about 231 errors when trying to create an wrapper class for MS Excel 2003 using visual studio 2005. My requirement is to create an application that reads an excel file using visual studio 2005. In our system, MSOffice 2003 is installed. Our application should be capable of supporting versions other than MS office 2003 also. Please give me any suggestions.
With Regards,
Sangeetha.
|
|
|
|
|
Maybe try to replace
#import "C:\\Program Files\\Microsoft Office\\Office12\\EXCEL.EXE" no_namespace
by
#import "C:\\Program Files\\Common Files\\Microsoft Shared\\Office12\\MSO.DLL" \
rename( "RGB", "MSORGB" )
using namespace Office;
#import "C:\\Program Files\\Common Files\\Microsoft Shared\\VBA\\VBA6\\VBE6EXT.OLB"
using namespace VBIDE;
#import "C:\\Program Files\\Microsoft Office\\Office12\\EXCEL.EXE" \
rename( "DialogBox", "ExcelDialogBox" ) \
rename( "RGB", "ExcelRGB" ) \
rename( "CopyFile", "ExcelCopyFile" ) \
rename( "ReplaceText", "ExcelReplaceText" )
It's work for me
|
|
|
|
|
Hi all,
I have made a simple dialog box application, in that i have made a list control. In that list control items are being displayed one by one. My problem is as the number of items increases my list control shows a horizontal scroll bar. But i want that instead of horizontal scroll bar a vertical scroll bar should be displayed.
How to do it...
Thanks in advance
|
|
|
|
|
I'm assuming this is a List View control.
Have you tried setting the LVS_ALIGNLEFT style, instead of the LVS_ALIGNTOP style? Just a guess, but not a bad one.
Or try using LVM_SETITEMPOSITION and position the items yourself. You'd need to do this after adding each one, and do it for all when the control's size changes.
Iain.
Iain Clarke appears because CPallini still cares.
|
|
|
|
|
What do you need exactly,can you be more specific.
|
|
|
|
|
Hello All,
I am developing one application for internet usage monitoring(User open which site)
Now i need help to start where?
Thanks in advance
Manish Patel.
B.E. - Information Technology.
|
|
|
|
|
Errr don't know. Some suggestions:
1) Open up your favorite IDE and start writing some code.
2) Read the posting guidelines.
3) Read a C++ book.
4) ...
|
|
|
|
|
Thanks for your reply,
I know how to start IDE and all that stuff.
I want to know the starting point for Internet Usage Traking.
Any idea?
Thanks
Manish Patel.
B.E. - Information Technology.
|
|
|
|
|
And what do you mean exactly by "Internet Usage Traking". Maybe if you would explain a bit more in detail what you are looking for we could help...
|
|
|
|
|
I want to track web browsing.
Meanse whenever user open new web site in web browber then my programe should get notice about it.
Manish Patel.
B.E. - Information Technology.
|
|
|
|
|
manish.patel wrote: Meanse whenever user open new web site in web browber then my programe should get notice about it.
Perhaps you are wanting a BHO.
"Love people and use things, not love things and use people." - Unknown
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Thanks for your great help.
Its useful for Internet Explorer.
Is there any alternative for Firefox and other web browsers?
Thanks
Manish Patel.
B.E. - Information Technology.
|
|
|
|
|
IPAudit[^] can do more than what you want. It is open source, does the job and does it well.
Nobody can give you wiser advice than yourself. - Cicero
.·´¯`·->Rajesh<-·´¯`·.
Codeproject.com: Visual C++ MVP
|
|
|
|
|
Hi All,
I am preparing for an COM interview.
Can i know the difference between BSTR and VARIANT data types used in
COM ?
Difference between COM and DCOM ?
Any FAQ's on basics of COM ?
Regards
Suhi
|
|
|
|