|
Hi i got a project that connect on server ftp and i want to add options :
Send File to the server
Delete File to the server
Get File from the server
and IF it is possible Open file(.txt), make changes , save changes (file will be on the server)
-- modified at 12:00 Sunday 14th May, 2006
Oh yes Microsoft VS C++ 6.0 (MFC applicatoin).
|
|
|
|
|
|
Immunity18 wrote: Hi i got a project that connect on server ftp and i want to add options :Send File to the serverDelete File to the serverGet File from the server
try CFTPConnection Class
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
|
|
|
|
|
hi all
can anybody explain me what is the difference, between C++ structs and classes
thanks
|
|
|
|
|
|
|
Members of structs have public visibility by default, whereas members of classes have private visibility by default. That's it
Ryan "Punctuality is only a virtue for those who aren't smart enough to think of good excuses for being late" John Nichol "Point Of Impact"
|
|
|
|
|
big_denny_200 wrote: can anybody explain me what is the difference, between C++ structs and classes
AFAIK, only one differnence is remain between Struct and Class, that By default member of struct is Public and member of class is private!
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
|
|
|
|
|
Hi,
I am struggling with templates, derived classes and virtual function.
Some help would be highly appriciated.
I have one template class 'RV' and another class 'NormalDistribution' derived from 'RV'
how do I use the NormalDistribution class in the main()??
/////////////////////////////////// template class 'RV' ///////////////
template <typename t="">
class RV { // abstract base template class holding random variables
protected:
T min, max, n;
public:
RV();
void setMinMaxCount(T a, T b, T n)
{ min = a; max = b); }
virtual T generate() = 0;
virtual T pdf(T val) = 0; // virtual functions
virtual T cdf() = 0;
};
template <typename t=""> class NormalDistribution : public RV<t> {
double randNum1,randNum2;
public:
NormalDistribution();
double generate()
{ // some calculations
randNum1 = ra = (((double)rand () / RAND_MAX) * 1);
randNum2 = min + (max-min)*randNum1/n;
rand3=(-log(rand2))/1;
return rand3;
}
double cdf(double val)
{ return (1-exp(-1*val)); }
};
int main()
{
// call 'NormalDistribution' class and assign values to max,min,n and then call generate function
}
////////////////////////////////////////////////
How do I do it?
Thanks,
Tara
Fortitudine Vinsinues!
|
|
|
|
|
Can you tell me how to check a String is double type in MFC?
-- modified at 10:33 Sunday 14th May, 2006
|
|
|
|
|
a string is a string, it is never a 'double' or any other type.
if you want to check if a string represents a floating point number, you need to check for the obvious things: is it all numbers ? does it have an optional single decimal point ? a negative sign in front? an exponent at the end? etc.
Cleek | Image Toolkits | Thumbnail maker
|
|
|
|
|
I agree with Chris Losinger string is string and ...
I guess this link maybe it is some helpful to you here[^]
whitesky
|
|
|
|
|
cuongbao197 wrote: Can you tell me how to check a String is double type in MFC?
you have implement logic to find out that:- you have to check each character of string for Numeral(compulsory),Single 'e' (for exponent,optional) and single Decimal(compulsory). if any of condition fails thne string is definatly not a Float.
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
|
|
|
|
|
Hi all
I have a window (CWnd) which inside i have a CDialog.
the CWnd contains 2 buttons. the dialog inside contains some controls.
i use the editor for tab ordering in the dialog.
i want now when i stand of the last control of the dialog and pressing tab , to jump to my first button in the CWnd, then pressing tab again to jump to the second button, and pressing tab again
to jump into the first control of the dialog....
is there a way to do that? how do i set the proper order?
thanks
Yaron
Interface basics click here :
http://www.codeproject.com/com/COMBasics.asp
don't forget to vote
|
|
|
|
|
You have to specify the "Control" style to the dialog in the More Styles of the Dialog Properties in Dialog Editor. Also don't forget to specify the WS_TABSTOP style to the buttons those are in the CWnd.
- NS -
|
|
|
|
|
Aparantly i was able to make it work when i defined the WS_EX_CONTROLPARENT for the inner dialog
but the problem is that the main window is a CWnd and not a CDialog, so tab isn't working at all if i stand on a control on the CWnd....if i change the class from CWnd to CDialog then all is working 100%
how to solve this?
Yaron
Interface basics click here :
http://www.codeproject.com/com/COMBasics.asp
don't forget to vote
|
|
|
|
|
Can you tell me how to check a character is Upper or Lower in MFC
|
|
|
|
|
IsCharLower();
IsCharUpper();
whitesky
|
|
|
|
|
|
Hi all,
i am looking for the same funtion as RoundRect that CDC has in GDI+?
any?
thanks
Yaron
Interface basics click here :
http://www.codeproject.com/com/COMBasics.asp
don't forget to vote
|
|
|
|
|
I have a project that I am working on that when statically linking to MFC I get the errors listed below. If I link to MFC usinging Dynamic linkage they do not appear. It would be great if anyone could help me resolve this issue.
Much appreciate your time.
Dave
Linking...
LINK : warning LNK4075: ignoring '/EDITANDCONTINUE' due to '/INCREMENTAL:NO' specification
msvcprtd.lib(MSVCP71D.dll) : error LNK2005: "public: __thiscall std::basic_string<char,struct std::char_traits<char="">,class std::allocator<char> >::~basic_string<char,struct std::char_traits<char="">,class std::allocator<char> >(void)" (??1?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@XZ) already defined in FilterEMF_in.obj
msvcprtd.lib(MSVCP71D.dll) : error LNK2005: "public: __thiscall std::basic_string<char,struct std::char_traits<char="">,class std::allocator<char> >::basic_string<char,struct std::char_traits<char="">,class std::allocator<char> >(char const *)" (??0?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@PBD@Z) already defined in FilterEMF_in.obj
msvcprtd.lib(MSVCP71D.dll) : error LNK2005: "public: __thiscall std::basic_string<char,struct std::char_traits<char="">,class std::allocator<char> >::basic_string<char,struct std::char_traits<char="">,class std::allocator<char> >(class std::basic_string<char,struct std::char_traits<char="">,class std::allocator<char> > const &)" (??0?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@ABV01@@Z) already defined in FilterEMF_in.obj
msvcprtd.lib(MSVCP71D.dll) : error LNK2005: "public: char const * __thiscall std::basic_string<char,struct std::char_traits<char="">,class std::allocator<char> >::c_str(void)const " (?c_str@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QBEPBDXZ) already defined in FilterEMF_in.obj
MSVCRT.lib(MSVCR71.dll) : error LNK2005: _free already defined in libcmtd.lib(dbgheap.obj)
MSVCRT.lib(MSVCR71.dll) : error LNK2005: _wcscmp already defined in libcmtd.lib(wcscmp.obj)
MSVCRT.lib(MSVCR71.dll) : error LNK2005: _malloc already defined in libcmtd.lib(dbgheap.obj)
MSVCRT.lib(MSVCR71.dll) : error LNK2005: "public: virtual __thiscall exception::~exception(void)" (??1exception@@UAE@XZ) already defined in libcmtd.lib(stdexcpt.obj)
MSVCRT.lib(MSVCR71.dll) : error LNK2005: "public: __thiscall exception::exception(void)" (??0exception@@QAE@XZ) already defined in libcmtd.lib(stdexcpt.obj)
MSVCRT.lib(MSVCR71.dll) : error LNK2005: "public: __thiscall exception::exception(class exception const &)" (??0exception@@QAE@ABV0@@Z) already defined in libcmtd.lib(stdexcpt.obj)
MSVCRT.lib(MSVCR71.dll) : error LNK2005: _memmove already defined in libcmtd.lib(memmove.obj)
MSVCRT.lib(ti_inst.obj) : error LNK2005: "private: __thiscall type_info::type_info(class type_info const &)" (??0type_info@@AAE@ABV0@@Z) already defined in libcmtd.lib(typinfo.obj)
MSVCRT.lib(ti_inst.obj) : error LNK2005: "private: class type_info & __thiscall type_info::operator=(class type_info const &)" (??4type_info@@AAEAAV0@ABV0@@Z) already defined in libcmtd.lib(typinfo.obj)
msvcprtd.lib(MSVCP71D.dll) : warning LNK4006: "public: __thiscall std::basic_string<char,struct std::char_traits<char="">,class std::allocator<char> >::~basic_string<char,struct std::char_traits<char="">,class std::allocator<char> >(void)" (??1?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@XZ) already defined in FilterEMF_in.obj; second definition ignored
msvcprtd.lib(MSVCP71D.dll) : warning LNK4006: "public: __thiscall std::basic_string<char,struct std::char_traits<char="">,class std::allocator<char> >::basic_string<char,struct std::char_traits<char="">,class std::allocator<char> >(char const *)" (??0?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@PBD@Z) already defined in FilterEMF_in.obj; second definition ignored
msvcprtd.lib(MSVCP71D.dll) : warning LNK4006: "public: __thiscall std::basic_string<char,struct std::char_traits<char="">,class std::allocator<char> >::basic_string<char,struct std::char_traits<char="">,class std::allocator<char> >(class std::basic_string<char,struct std::char_traits<char="">,class std::allocator<char> > const &)" (??0?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@ABV01@@Z) already defined in FilterEMF_in.obj; second definition ignored
msvcprtd.lib(MSVCP71D.dll) : warning LNK4006: "public: char const * __thiscall std::basic_string<char,struct std::char_traits<char="">,class std::allocator<char> >::c_str(void)const " (?c_str@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QBEPBDXZ) already defined in FilterEMF_in.obj; second definition ignored
MSVCRT.lib(MSVCR71.dll) : warning LNK4006: _free already defined in libcmtd.lib(dbgheap.obj); second definition ignored
MSVCRT.lib(MSVCR71.dll) : warning LNK4006: _wcscmp already defined in libcmtd.lib(wcscmp.obj); second definition ignored
MSVCRT.lib(MSVCR71.dll) : warning LNK4006: _malloc already defined in libcmtd.lib(dbgheap.obj); second definition ignored
MSVCRT.lib(MSVCR71.dll) : warning LNK4006: "public: virtual __thiscall exception::~exception(void)" (??1exception@@UAE@XZ) already defined in libcmtd.lib(stdexcpt.obj); second definition ignored
MSVCRT.lib(MSVCR71.dll) : warning LNK4006: "public: __thiscall exception::exception(void)" (??0exception@@QAE@XZ) already defined in libcmtd.lib(stdexcpt.obj); second definition ignored
MSVCRT.lib(MSVCR71.dll) : warning LNK4006: "public: __thiscall exception::exception(class exception const &)" (??0exception@@QAE@ABV0@@Z) already defined in libcmtd.lib(stdexcpt.obj); second definition ignored
MSVCRT.lib(MSVCR71.dll) : warning LNK4006: _memmove already defined in libcmtd.lib(memmove.obj); second definition ignored
MSVCRT.lib(ti_inst.obj) : warning LNK4006: "private: __thiscall type_info::type_info(class type_info const &)" (??0type_info@@AAE@ABV0@@Z) already defined in libcmtd.lib(typinfo.obj); second definition ignored
MS
test
|
|
|
|
|
Did you see MSDN for error LNK2005
whitesky
|
|
|
|
|
Thanks WhiteSky, I went to the help first off. But, the threading model is the same throughout the project. No 3rd party libs or anything that are different threading models.
test
|
|
|
|
|
I think you are trying to use a 3rd party library which is using a different C Run Time then your main application. By looking at error I think your application is using /MTd but at least onee of 3rd Party library is using /MDd. In case it is true then you have to recompile all 3rd party libraries using same CRT.
-Saurabh
|
|
|
|
|
Hi,
I'm trying to create a custom slider. I've got 5 bitmaps that show the slider's know in 5 different states.
All that is left to do is to change the bitmaps as the user drags the slider.
I've looked in all the articles on the site. All of them use a different approach with regerd to custom drawing of sliders: the knob, the channel and the background are independent objects. I couldn't find an article that implements dynamic replacement of bmps as the user drags the knob.
Can anyone shed some light on what's the best way to implement it?
Thanks a lot in advance.
Snir.
|
|
|
|