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
M

marcoslav

@marcoslav
About
Posts
19
Topics
10
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • angle between two points
    M marcoslav

    Suppose I know two points, How to compute a angle in degrees bwtween those two points.

    The Lounge tutorial

  • time difference
    M marcoslav

    How to get time difference in seconds. CTime t1; t1.GetCurrentTime(); after some time say after 3 seconds CTime t2; t2.GetCurrentTime(); Now I want difference between t2 and t1 in seconds that is 3 seconds; Marcoslav

    C / C++ / MFC tutorial

  • Help me to use windows hook exactly.
    M marcoslav

    Thanks it worked. But it went in to infinite loop, cos it was creating messagebox to show that some window was created. so for messagebox themselves also messagebox was getting displayed.. so infinite loop. My first virus I guess ;)

    C / C++ / MFC c++ debugging help tutorial

  • Help me to use windows hook exactly.
    M marcoslav

    Purpose of my program is to get notification (a messagebox) whenever a new window is created on the operating system. In my win32 dll I put following code. #include "stdafx.h" #include "hookdll.h" HHOOK WndHook; HINSTANCE hInst; __declspec(dllexport) bool InstallHook(void); __declspec(dllexport) bool UninstallHook(void); __declspec(dllexport) LRESULT CALLBACK WndHookProc(int, WPARAM, LPARAM); BOOL APIENTRY DllMain( HANDLE hModule, DWORD ul_reason_for_call, LPVOID lpReserved ) { switch (ul_reason_for_call) { case DLL_PROCESS_ATTACH: case DLL_THREAD_ATTACH: case DLL_THREAD_DETACH: case DLL_PROCESS_DETACH: break; } hInst = (HINSTANCE)hModule; return TRUE; } // This is an example of an exported variable HOOKDLL_API int nHookdll=0; // This is an example of an exported function. HOOKDLL_API int fnHookdll(void) { return 42; } // This is the constructor of a class that has been exported. // see hookdll.h for the class definition CHookdll::CHookdll() { return; } __declspec(dllexport) bool InstallHook(void) { if(WndHook == NULL) WndHook = SetWindowsHookEx(WH_SHELL, (HOOKPROC)WndHookProc, hInst, 0); return (WndHook != NULL); } __declspec(dllexport) bool UninstallHook(void) { if(WndHook != NULL) { if(UnhookWindowsHookEx(WndHook)) WndHook = NULL; } return (WndHook == NULL); } __declspec(dllexport) LRESULT CALLBACK WndHookProc(int nCode, WPARAM wParam, LPARAM lParam) { if (nCode<0) return CallNextHookEx(WndHook, nCode, wParam, lParam); /* my codes...*/ ::MessageBox(NULL,"Window created","here",MB_OK); return CallNextHookEx(WndHook, nCode, wParam, lParam); } Now watch my client program.. MFC exe, dialog based. On its OkButton handler I put following code. I am not using load library and getProce address , because I am linking the library in the project settings and copying the hookdll in the debug directory of my application . void CHookclientDlg::OnOK() { InstallHook(); } But my client application can not call InstallHook. Is this coding right or will it inform all the windows creation. (other applications , threads). Please tell me Marcoslav

    C / C++ / MFC c++ debugging help tutorial

  • web page completely loaded or not?
    M marcoslav

    How may I know if the webpage is completely loaded or not in my CHTMLView in my SDI application? I use Navigate2(..) function to load the webpage. Marcoslav

    C / C++ / MFC question

  • Bye Bye Bill Gates [repost]
    M marcoslav

    does that mean ,one can masterise dot net.. no more upgratation or next version? other wise we had taken something and bill brought next thing in the market .

    The Lounge php com

  • activex
    M marcoslav

    I need simple ATL activex tutorial

    ATL / WTL / STL c++ com tutorial

  • It's that day of the week again
    M marcoslav

    i have six days working ;(

    The Lounge com question

  • ATL with C code
    M marcoslav

    noone answers there in ATL so posted here

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

  • ATL with C code
    M marcoslav

    Hi, I have a dialog box in my ATL exe, I want to use/link a C Library. AFter clicking OK button on the dialog on of C functions should execute . How to do this. linking the Clibrary and opening the C function. Can I use the C code direct in ATL module ? how? marcoslav

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

  • copycats
    M marcoslav

    ToddHileHoffer wrote:

    Also, if those "friends" don't beleive you then are they really friends?

    Yes , it seems to be the case.

    The Lounge help question

  • What do you eat for breakfast?
    M marcoslav

    you call chicken as simple food.. oops.

    The Lounge html com question

  • copycats
    M marcoslav

    recently I made a good program for my firm and showed it to my friends. But they dont believe me. They say its all cut and paste from internet. Everything is available on net.. classes and all. I agree I took help from some forums. But I disagree that It was all cut and paste. I built good algorithms and achieved few good things by my logic. I think all coders have to take help from net on regular basis.. does this mean we are copy cats?

    The Lounge help question

  • saveas from web browser
    M marcoslav

    I want to save my webpage on the hard disk as .mht file , not as html. But every time I have to select option for .mht.. (.htm is default) How to make this option default.. .mht

    The Lounge html tutorial

  • ATL with C code.. pls looooooooooooooook hereeeeeeeeeeeeeee
    M marcoslav

    Hi, I am posting here cos none answers in ATL group. I have a dialog box in my ATL exe, I want to use/link a C Library. AFter clicking OK button on the dialog on of C functions should execute . How to do this. linking the Clibrary and opening the C function. marcoslav -- modified at 3:10 Friday 16th June, 2006

    ATL / WTL / STL c++ tutorial

  • Adnan's emotions... A white paper [modified]
    M marcoslav

    Adnan Siddiqi wrote:

    my friend

    I can not believe you. If tomorrow you people announce Jehad, you may kill me .

    The Back Room help

  • Adnan's emotions... A white paper [modified]
    M marcoslav

    I am new , but after reading all posts, truth seems to be bitter to you Mr. Adnan marcoslav

    The Back Room help

  • have you ???
    M marcoslav

    Has someone DID it in office with the collegue or with self?? :~ marcoslav

    The Back Room question

  • Brainpower....
    M marcoslav

    F**k this society. I have been coding all along. I dont have social life. My marital life is in shambles. No friends. I watch TV in my spare time. I go alone for shopping or to watch movies. I feel inferior, insecure. I am a loner. Nobody loves me , o r loves to talk to me. they gets bores by me easily. I dont have god physique. But certainly not suicidal 'cos All I think is of dot net and the next great assignment my boss has promised me. SOmetimes I feel though, I should have more friends and miss my college and childhood days. But I am happy with myself. I enjoy myself. I am happiest when noone is around. marcoslav

    The Lounge linux 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