|
How about this:
CFtpConnection *pFtp;
....
pFtp = Session.GetFtpConnection(...);
...
...
CFtpConnection& hFtp = *pFtp;
|
|
|
|
|
Hi,
we are building up a collection of articles. A few of them are ready. I hope our collection of tips and tricks will grow up in the next time.
Take a look at it ...
http://www.klangwerker.de/developer/
CU Mario ///
----------------------
www.klangwerker.de
mario@klangwerker.de
----------------------
|
|
|
|
|
http://www.klangwerker.de/developer/
Ps! This is probably the most ugly website ever made
But the content is good beginner stuff.
Jimmy Hoffa
|
|
|
|
|
I am having the problem described at http://support.microsoft.com/support/kb/articles/Q240/8/69.ASP
(basically one of my operators thinks its ambiguous when it isnt, and I presume its because of this bug.) I cant work out if this document is giving me a way around it??
thanks,
Ben
|
|
|
|
|
If you post the code you're having a problem with we might be able to help
|
|
|
|
|
I don't know if this helps but this works:
template<class t=""> void f(T value);
void main() {
int nNum = 3;
const int *p = &nNum;
f(*p);
}
template <class t=""> void f(T value)
{
printf("%d", value);
}
Bret Faller
Odyssey Computing, Inc.
|
|
|
|
|
I would like to use data in CCombobox in my code with a switch method. So, i have choosen the option drop list, because i need that my variable is an integer. In my example i have put firstly in the data of the Combobox a data1, then data2...So, i would like to know if this order stay the same all the time, and if in switch method, case 0 is for data1....
thanks in advance
gerald
|
|
|
|
|
Did you make a member variable with ClassWizard? If so, the value of the variable is the index of the selected item - the same value you get with CComboBox::GetCurSel().
--Mike--
http://home.inreach.com/mdunn/
"Make sure that if you are using a blow torch that you don't set anything on fire."
-- Chris Maunder
|
|
|
|
|
Hi
How do I get a cdialog to know it's finished whit initializing and painting all controls on board? Is there a message going out or something?
Per
|
|
|
|
|
WM_INIT ?
Christian
#include "std_disclaimer.h"
The careful application of terror is also a form of communication.
Eagles may soar, but weasels don't get sucked into jet engines.
|
|
|
|
|
I have a drawing consisting of several lines.
I need some actions to be made when user clicks at some line. How can I implement this using MFC?
I have already done this calculating distance from the clicked point to each line, but it seems to be too complicated.
Andrei the Adroit
|
|
|
|
|
Use a RECT or CRect for the coordinates of your lines. Create a CRgn from your rectangle using CreateRectRgn. Use PtInRegion in your LButton function, to verify whether or not the mouse is in the rectangle. Use OnMouseMove, in which you can move the rectangle.
Note: you can use a CList if you have a large number of lines.
|
|
|
|
|
How to include a MFC DLL in to a project created without MFC ?
|
|
|
|
|
|
Sorry, I put the question in a bad mode.
I have a project that didn't include MFC. I try to include a library file (.lib). This lib file use MFC (I don't have the sources of this lib). I put the lib file and heaer file (.h) in the same directory with the project and I try to build... but I get message like this:
"fatal error C1189: #error : include 'stdafx.h' before including this file for PCH"
and the line where I get the error is in header file and contain:
"#ifndef __AFXWIN_H__
#error include 'stdafx.h' before including this file for PCH
#endif"
But, "stdafx.h" don't exist because the project don't use MFC.
Thanks,
Gabi
|
|
|
|
|
Hi,
I want to find references & code samples for changing the icon of any files.(not only dlls or exes).. Is it possible to change icons of other files... Please help me ASAP..
Thanks in advance
Hami
Hami
|
|
|
|
|
|
Miri
try the following, you need to add Carriage Return and Line Feed characters to the end of the string to get it to create the file in DOS format and not Unix.
CString strMsg = "Line 1\r\nLine 2\r\n";
CFile OutFile;
OutFile.Write(strMsg, strMsg.GetLength());
Michael Martin
Pegasystems Pty Ltd
Australia
martm@pegasystems.com
+61 413-004-018
|
|
|
|
|
Could you use CStdioFile instead, that has a WriteString method.
|
|
|
|
|
Does anyone know a simple class/method that performs
URL encoding and can be used to encode data for HTTP POST
requests?
Thank you!
|
|
|
|
|
1. Both we know in the XP system, we can switch user.
2. If i installed an AP in "user1" and lanch it.
3. Then i switch into "user2", and user2 will lanch the same AP too.
4. How to design the AP can dectect the AP has running in another user?
Evil
|
|
|
|
|
Probably the registry - HKEY_CURRENT_USER is a virtual key, that is mapped to the user logged in.
Dunno about in XP though.
Christian
#include "std_disclaimer.h"
The careful application of terror is also a form of communication.
Eagles may soar, but weasels don't get sucked into jet engines.
|
|
|
|
|
You can create a semaphore with the 'Global\' prefix, just like you would if you were coding for Terminal Server (I think they based the code for Fast User Switching partly on it).
HANDLE hMySemaphore = CreateSemaphore ( SemaphoreAttributes, 1, 1, "Global\\ThereCanBeOnlyOne" );
Note that you'll have to remove the back hack if you’re going to be running the application on Win9x or NT 4.0 (Win2K will just ignore it).
Ben Burnett
---------
On the topic of code with no error handling -- It's not poor coding, it's "optimistic"
|
|
|
|
|
I had tried this way, but it seem work correct in the same user, but can't work when i switch into another user in XP.
|
|
|
|
|
take a look here to get information about fast user switching...
|
|
|
|