Skip to content

ATL / WTL / STL

Discussions on ATL, WTL and STL programming

This category can be followed from the open social web via the handle atl-wtl-stl@forum.codeproject.com

3.1k Topics 9.9k Posts
  • std::map and error checking

    c++ csharp visual-studio help question
    5
    0 Votes
    5 Posts
    0 Views
    M
    In this case, there's nothing you need to do. If something goes wrong, it'll throw a C++ exception. Most likely causes will be that a new element can't be constructed, or that there is insufficient memory. But maybe this is not what you meant. You say you want error checking; why do you want error checking? What is that you want to accomplish? Perhaps the solution is different.
  • How to force C++ allocate memory from disk?

    c++ design performance help tutorial
    3
    0 Votes
    3 Posts
    1 Views
    F
    thank you for your advice, i will have a try. :)
  • status display in a dialog

    c++ csharp visual-studio announcement
    2
    0 Votes
    2 Posts
    0 Views
    G
    have a look at this - its what I used for years when I did MFC A Logging Listbox Control[^] [edit] I can probably remember how to use it in a Dialog based app if you think you want to use it Joseph's site is http://www.flounder.com/logctl.htm[^] [/edit] 'g'
  • 0 Votes
    3 Posts
    0 Views
    B
    As you already know, that compiles. I see the second option as being a bit more clear and used it. Thank you for your time. Thanks for your time If you work with telemetry, please check this bulletin board: http://www.bkelly.ws/irig\_106/
  • Remove COM Objects from VC++ projects

    c++ com tutorial question
    8
    0 Votes
    8 Posts
    0 Views
    P
    How to use that command I want to remove it from my code.
  • 0 Votes
    1 Posts
    0 Views
    No one has replied
  • VC++ Crashing?

    c++ debugging help question
    3
    0 Votes
    3 Posts
    0 Views
    C
    Try to run in Windows 2000 compatibility mode. First thing that comes to mind
  • c++ exporting class variables

    c++ help csharp debugging question
    2
    0 Votes
    2 Posts
    0 Views
    M
    Using DLL Export you can export your C/C++ variables and functions to make them available. However, you can not just export an entire class and use it in C#. The direct problem here is that you are accessing a member function (Test) without an instance of your test-class being created. Probably the best way to interface in a class based manner between C++ and C# is to use COM; that is, create a COM class in C++, export it, and then use the COM class in C#.
  • hello

    com help question
    1
    0 Votes
    1 Posts
    1 Views
    No one has replied
  • 0 Votes
    4 Posts
    0 Views
    L
    yourchandrashekhar@gmail.com wrote: and another key and initialization vector in decryptData(). Why would you expect it to work with different keys? Use the best guess
  • Suggestion for project type

    csharp c++ visual-studio tools
    14
    0 Votes
    14 Posts
    0 Views
    G
    I forgot about this [requirement] >> The user will be able to edit the data and write out to a new file. So maybe the tabs have some sort of edit - possibly hex edit control on them Its not impossible - a 'commit changes' or 'write to file' button on the main dialog would loop through the tabs writing the data obtained from the edit control on it. I think I would write, from an abstraction point of view ... 3. GUI Code 2. Tab Manager - Possibly linked to buffer manager/dirty flag - you need to know the order of the tabs and if they have been changed or not 1. File Parser/Writer its about bed time for me too :zzz:
  • memcpy, not understanding something

    c++ csharp visual-studio question
    5
    0 Votes
    5 Posts
    0 Views
    D
    Richard MacCutchan wrote: You are specifying the source address as &mp_search_pointer which is the address of the pointer, rather than the pointer itself. I suspect that is not what you intended. Exactly right. The address of the pointer gives you a block of memory just 4-bytes long, containing a memory address. The pointer itself gives you the allocated memory you're looking for.
  • 0 Votes
    1 Posts
    1 Views
    No one has replied
  • 0 Votes
    3 Posts
    0 Views
    M
    In the end, no one of us can see into the future, therefore it is not possible to say that your program will work with another version of the DLL in the future. Just because it is... you know... the future. cheers Marco Bertschi Software Developer Twitter | Facebook | Articles You have absolutely no idea how glad I am that I have no idea at all. - OriginalGriff
  • COM Forward compatibility ?

    question com announcement
    1
    0 Votes
    1 Posts
    1 Views
    No one has replied
  • 0 Votes
    2 Posts
    1 Views
    L
    Apart from the fact that you need to use the WCHAR and PWSTR types to refer to your characters there is no difference. Use the best guess
  • Hidden window cannot get WM_COPYDATA message?

    c++ com question
    2
    0 Votes
    2 Posts
    0 Views
    L
    1. Please enclose your code in <pre> tags so it looks clear, as: LRESULT OnCopyData(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled) { ::MessageBox(NULL, _T("OnCopyData...1"), _T("INFO"), MB_OK); return 0; } 2. Please explain what your problem is. Use the best guess
  • CoCreateInstance Problem & GetLastError 0x0000007e

    help question announcement
    11
    0 Votes
    11 Posts
    3 Views
    Y
    LRESULT CYHtapiCom::OnInitDialog(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled) { CAxWindow wnd; CLSID clsid; LPUNKNOWN pUnkCtrl, pUnkCont; HRESULT hr = CLSIDFromProgID(OLESTR("VoipTestCom.SimpleClient"), &clsid); hr = CoCreateInstance(clsid, NULL, CLSCTX_ALL, IID_IUnknown, (void**)&pUnkCtrl); CComQIPtr spPerStm(pUnkCtrl); spPerStm->InitNew(); wnd.Attach(m_hWnd); wnd.AttachControl(pUnkCtrl, &pUnkCont); return TRUE; }
  • [SOLVED] IHTMLDOCUMENT2 get_Script problem in thread

    c++ tutorial javascript com help
    3
    0 Votes
    3 Posts
    0 Views
    M
    Thanks for the quick response, Richard. The second line returns S_OK and m_spDoc contains a non-zero value. It's all about STA, I'm almost sure, but have no clue how to go about it :) Edited: DONE! Thanks to: http://social.msdn.microsoft.com/Forums/en-US/iewebdevelopment/thread/94728897-4c44-4f58-a09b-c4c4609a2116/[^]
  • 0 Votes
    2 Posts
    4 Views
    L
    Please do not post the same question in multiple forums; choose one and stick to it. Use the best guess