Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
C

Chris Gao

@Chris Gao
About
Posts
24
Topics
4
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Monitor Network Traffic
    C Chris Gao

    Dear All, I am looking for a way to monitor network traffic, such as total number of bytes have been upload / download. Could anybody give me some clues of doing this? Either using SDK (C++) or .NET Class (C#) would be nice. Many Appreciates! Best regards, Chris G.

    .NET (Core and Framework) csharp c++ sysadmin question

  • Monitor Network Traffic
    C Chris Gao

    Dear All, I am looking for a way to monitor network traffic, such as total number of bytes have been upload / download. Could anybody give me some clues of doing this? Either using SDK (C++) or .NET Class (C#) would be nice. Many Appreciates! Best regards, Chris G.

    System Admin csharp c++ sysadmin question

  • how to get a image in a .bmp file onto a Dialog in the program?
    C Chris Gao

    Hi ewighell, There are some steps of doing this: [1] Load the bmp in mem. Your can use CBitmap::Load to do this. the CBitmap class can give you a handle (HBITMAP) to this bitmap. [2] Create a dc by using CDC::CreateCompatibleDC; select the bmp handle into this dc (CDC::SelectObject). [3] Override the dialog's OnPaint function. use CDC::Bitblt or CDC::StretchBlt to render the bmp on to dialog surface. Regards, Chris

    C / C++ / MFC c++ tutorial question learning

  • Keeping a System "alive"
    C Chris Gao

    Oooooooops~~ "this is in a hospital Emergency Room" ??! have you thought about that your application may fail for whatever reason? Then, who will response for that if it happens? If I were you, I would like to write a formal report to your boss to talk about this issue instead of taking some technical way to hide it. What do you think about it? Regards, Chris

    C / C++ / MFC question

  • Outputs in bold form...
    C Chris Gao

    Em... I tried this approach. It works! I learn a new skill from you. Thank you, Steve. Thanks to the person who post this question too. Regards, Chris

    C / C++ / MFC question

  • new to dlls!
    C Chris Gao

    Hi Mike, Well, I have no idea about the dll thing. Since you talked about something related to soundcard, have you tried "The Synthesis ToolKit in C++ (STK)" library before? You can download it from: http://ccrma.stanford.edu/software/stk/[^] I don't know whether it fit your application, but for mine, it just perfect. Regards, Chris

    C / C++ / MFC help question

  • Dialog box error
    C Chris Gao

    Hi RalfPeter, I guess your dialog class is derived from CDialog. Is that right? If you create a mfc dialog application, use default settings and just go 'finish' to create the code, you may find the following piece of codes in your ...Dlg.cpp file: CtestmfcDlg::CtestmfcDlg(CWnd* pParent /*=NULL*/) : CDialog(CtestmfcDlg::IDD, pParent) { m_hIcon = AfxGetApp()->LoadIcon(IDR_MAINFRAME); } Here you can see that the CDialog class actually need two or one parameter to initialize. You need to do this in your code as well. The IDD is a id to a dialog resource. you can create a new dialog resource by using 'add' option in the drop down menu of the resource explorer window. Regards, Chris

    C / C++ / MFC help question

  • File I/O
    C Chris Gao

    Hi Kuroro, How about fscanf ? Regards, Chris

    C / C++ / MFC help c++ data-structures question

  • Global Variable Question
    C Chris Gao

    Hi Jeremy, I am new to programming too. I think it is really cool to code something in MS Office. I mean that. Well, I think neither of my suggestions work in your case. Em... is your variable accessed very frequently? I mean, how about use registry table to story this variable? The following example really do very well in registry access stuff. http://www.codeproject.com/system/CRegistry.asp[^] Regards, Chris

    C / C++ / MFC c++ question

  • Global Variable Question
    C Chris Gao

    Hi Jeremy, I didn't catch your question very well. If u r talking about two dlls that are called by one executable module, which means that they are running in the same process, I would like you try to declare a variable in the exe file, pass a pointer to it to both dlls and reference this variable to share info. If they are running in different processes, I would suggest you use some ipc apporach, for example Create/OpenFileMapping thing. Regards, Chris

    C / C++ / MFC c++ question

  • How do I know if an OK event came from mouse or Enter?
    C Chris Gao

    Oops, I didn't see other replys just now. Obviously, my suggestion is the worst one. hehe, ignor it. Regards, Chris

    C / C++ / MFC question help learning

  • How do I know if an OK event came from mouse or Enter?
    C Chris Gao

    Hi Ilan, Well, my suggestion is that you declare two time stamps and use them to keep the latest time of left mouse click and Enter key click. In OnOk functions, you may compare the current time with both time stamps and this may give you some idea about which is the source of the action. regards, chris

    C / C++ / MFC question help learning

  • CreateProcess Method
    C Chris Gao

    Hi Steve, I even didn't think about this at all! Thanks!! Chris

    C / C++ / MFC

  • Turn Off monitor??????
    C Chris Gao

    Well, look at this person's article. http://www.codeproject.com/system/display_states.asp#xx1310381xx[Turn off monitor] I tried before, it works. However, if you move your mouse, the monitor will be turned on by os. I didn't try to solve this problem. If you know the solution, please let me know. Thanks. Best regards, Chris.

    C / C++ / MFC c++ json tutorial question

  • Any Suggestions on Memory Leak Detection Tools?
    C Chris Gao

    Hi Naveen, I downloaded this software (Rational Purify). It just what I am looking for. Thanks! Best regards, Chris

    C / C++ / MFC tools performance question

  • CreateProcess Method
    C Chris Gao

    Hi Subramaniam, I don't know what's wrong with your code but I did it like this: STARTUPINFO si; PROCESS_INFORMATION pi; // Start the child process. CreateProcess( NULL, // No module name (use command line). TEXT("C:\\Windows\\system32\\notepad.exe"), // Command line. NULL, // Process handle not inheritable. NULL, // Thread handle not inheritable. FALSE, // Set handle inheritance to FALSE. 0, // No creation flags. NULL, // Use parent's environment block. NULL, // Use parent's starting directory. &si, // Pointer to STARTUPINFO structure. &pi ); // Pointer to PROCESS_INFORMATION structure. It works on my computer. Best regards, Chris

    C / C++ / MFC

  • how to create a virtual serial port, and to monitor it
    C Chris Gao

    Hi Szilard, Well, i don't know how to do it by myself, however, maybe these websites can help a bit: http://www.lvr.com/serport.htm[^] http://www.eltima.com/products/virtual_drivers/[^] Best regards, Chris

    C / C++ / MFC help tutorial

  • Any Suggestions on Memory Leak Detection Tools?
    C Chris Gao

    Hi Steve, Thanks! I downloaded debug-tools-for-windows (dbg_x86_6.6.03.5.exe) from ms$. Emm... umdh.exe looks like a very powerful tool. I don't really make too much sense of it yet. ..... still need sometime to learn. Thank you! Best regards, Chris

    C / C++ / MFC tools performance question

  • Any Suggestions on Memory Leak Detection Tools?
    C Chris Gao

    Hi Joe, Thank you! I have downloaded a trial and using it at the moment. It seems like put a lot stuff in the compiled code. Em... haven't make too much sense yet. trying... trying... trying... Best regards, Chris

    C / C++ / MFC tools performance question

  • Any Suggestions on Memory Leak Detection Tools?
    C Chris Gao

    Hi Nemanja, Yes, I aggree with you! I used this (Visual Leak Detector) before, and it works just well. However, my boss prefer a memproof like application. Em.... Anyway, appreciate you help ! Best regards, Chris.

    C / C++ / MFC tools performance question
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups