|
Sorry for not giving clear picture.
I made the code change as you suggested. It worked. I mean that compiler error is gone. But it is giving other compiler errors.
In debug mode i did not get any compilers which i am getting in release mode(including the one i posted yesterday. not a single compiler error). I am getting 996 errors in release mode.
What should i do.
|
|
|
|
|
so as i said, i cannot guess what's wrong unless you provide relevant infos...
what are the first errors ?
have you tried to do a rebuild all ?
|
|
|
|
|
Hi,
The first error is c2065 error (the one i posted). I made changes in the code as you said. It worked. But now i am getting C2079 error for the line
static struct xdr_ops xdrposix_ops;
and C2197 error for the line
return (XDR_PUTLONG(xdrs, (long *)fp));
Where XDR_PUTLONG definition is like this
#define XDR_PUTLONG(xdrs, longp) \
(*(xdrs)->x_ops->x_putlong)(xdrs, longp)
. Like this i am getting many error. I did a rebuild. Still it did not work.
The same is being built in debug more without any errors.
Regards, Eswari
|
|
|
|
|
hey man, are you stupid, or you just don't to get helped fast ?
if i tell you C2079 and C2197, do you know what error it is exactly ?
i doublt about it. for me, it's the same... and I won't look at the msdn just because you're too lazy to copy past the exact error message from the compiler output
|
|
|
|
|
Sorry.
This is what i am getting
error C2079: 'xdrposix_ops' uses undefined struct 'xdr_ops' for this line
static struct xdr_ops xdrposix_ops in the code.
|
|
|
|
|
Also i am getting the following error
error C2440: '=' : cannot convert from 'int (__cdecl *)(NC_string *)' to 'int (__cdecl *)(void)' for this line of coding in the file
xlen_funct = NC_xlen_string ;
where first one is function defined as int (*xlen_funct)() ;
second one is function defined as int NC_xlen_string(NC_string *cdfstr)
Any help is appreciated.
Regards, Eswari
|
|
|
|
|
subramanyeswari wrote: xlen_funct = NC_xlen_string ;
where first one is function defined as int (*xlen_funct)() ;
second one is function defined as int NC_xlen_string(NC_string *cdfstr)
then if the 2 propotypes are different, you cannot assign one to the other...
|
|
|
|
|
hi,
i am writting wrapper over C++ functions to call them in C. the problem is with return type const char*. it is compling properly. but it cant find dll entry point for the function.
the function in .h file is
const char* __declspec(dllimport) __stdcall myfunction(par1, par2);
i am using Visual Studio 2005 IDE. when i move mouse cursor over myfunction it shows return type as int.
what is the problem?
|
|
|
|
|
huuuuu, a wrapper on C++ functions for C ?
isn't it the opposite that we usually do ?
what kind of functions are you wrapping ?
moreover, you say that the dll entry point is not found. in what is this related to const char* ?
|
|
|
|
|
You need to specify C linkage instead of C++ linkage. To specify C linkage, use extern "C" for function declarations:
extern "C" const char* __declspec(dllimport) myfunction(par1, par2); Also, note that the dllimport should be dllexport if you're compiling the DLL project.
To check what is being generated, use the dumpbin command-line utility: dumpbin /exports mydll.dll. You can also use this on .lib file.
Be sure you are pointing to correct lib/dll in your project - otherwise you will waste a lot of time trying to figure out why changes are not showing up.
Best wishes,
Hans
|
|
|
|
|
Hello experts!
Not really a visual C++ question, but can anyone of you show or provide me a ftp interface I can use within a C++ unix program. I found the excellent CFTPClientClasses here on Codeproject, but don't get it compiled without major changes ( which I have no time for) on unix. Destination system is SUN Solaris 9, Forte Developer 7 compiler. Any hint is welcome. Thanks!
-- modified at 9:38 Monday 7th May, 2007
|
|
|
|
|
A while back I saw a C++ FTP class on SourceForge - don't remember the name right now. Try a search.
|
|
|
|
|
|
MarcoNedwig wrote: I found the excellent CFTPClientClasses here on Codeproject, but don't get it run on unix.
It compiled, but wouldn't run?
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Sorry I wrote it incorrectly. I couldn't compile it with major changes.
|
|
|
|
|
Ok, so what does CFTPClientClasses() do internally? Does it use a platform-neutral API?
MarcoNedwig wrote: I couldn't compile it with major changes.
What major changes did you make such that you couldn't compile it?
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
It has a platform independent api. You can see the article here :
http://www.codeproject.com/internet/ftpclientclass.asp
|
|
|
|
|
Hi,
I need to change the text color of a group box, How to do??
I did as as below
HBRUSH C3DColorCardDlg::OnCtlColor(CDC* pDC, CWnd* pWnd, UINT nCtlColor)
{
HBRUSH hbr = CDialog::OnCtlColor(pDC, pWnd, nCtlColor);
pDC->SetTextColor(EFC_RGB_WHITE);
if(nCtlColor==CTLCOLOR_STATIC)
{
pDC->SetBkMode(TRANSPARENT);
pDC->SetTextColor(EFC_RGB_WHITE);
return m_hbrDlgBkGnd;
}
}
but no use.
Any suggestions would be helpful.
Thanks in Advance
Today is a gift, that's why it is called the present.
|
|
|
|
|
Take a look at WM_CTLCOLORBTN .
Best wishes,
Hans
|
|
|
|
|
...or replace CTLCOLOR_STATIC with CTLCOLOR_BTN in your code.
Mark
"Posting a VB.NET question in the C++ forum will end in tears." Chris Maunder
|
|
|
|
|
hi !
Everybody !
sorry to ask a question on thread.kindly can any body guide me. can I debug multithreading application?
"Success lies not in the result , But in the efforts !!!!!"
Amit Mistry - petlad -Gujarat-India
|
|
|
|
|
Why not?
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.
|
|
|
|
|
May I ask you one more question on thread?
"Success lies not in the result , But in the efforts !!!!!"
Amit Mistry - petlad -Gujarat-India
|
|
|
|
|
hum, i'd say go ahead, as we're on the forum for it...
if you don't ask, we won't be able to answer.
but if the question is not respecting the guidelines, be ready to be flamed ! lol
|
|
|
|
|
Thank you sir!
sir when I debug my application. As I debug, all the handles created properly for threads and I have pass the structure pointer (paramters) but value passed through the pointer is same at each call .
what should i do?
should I have to take array of pointers for struct varibale?
-- modified at 9:50 Monday 7th May, 2007
"Success lies not in the result , But in the efforts !!!!!"
Amit Mistry - petlad -Gujarat-India
|
|
|
|