473,473 Members | 2,145 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

WM_COMMAND in Win32

1,059 Top Contributor
In the program there two custom

WNDCLASS
1. holder
2. inp_b

a holder class window is generated in main window on WM_CREATE.

9 inp_b window is generated in holder window WM_CREATE 9 instance.

The problem is I want to receive WM_COMMAND in holders's WndProc on click. But I am not getting any.

What point possibly i am missing.

The whole source code is attached. you can check if you want
Attached Files
File Type: zip name.zip (23.3 KB, 118 views)
Aug 8 '10 #1
1 3585
johny10151981
1,059 Top Contributor
Solved it by myself.

From holder class window WndPorc user action (WM_LBUTTONDWON) I have called the function SendMessage with mother hwnd as HWND parameter. user defined message number as message value. at WPARAM handler of current window and in the LPARAM field current Message that is being processed in WndProc.

Expand|Select|Wrap|Line Numbers
  1. case WM_LBUTTONDOWN:
  2. HWND Mother;
  3. Mother=(HWND)GetWindowLong(hWnd,GWL_HWNDPARENT);
  4. SendMessage(Mother,50001,(WPARAM)hWnd,(LPARAM) WM_LBUTTONDOWN);
  5. break;
  6.  
Aug 10 '10 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

5
by: Bryan Parkoff | last post by:
Please provide me the information when it is not in the correct newsgroups. I have been using C and C++ language for a long time when it is time for me to learn Win32 API functions that they can...
3
by: Søren Badstue | last post by:
Hey there, I have just learned C++ for Windows programming, and try to understand the PeekMessage and the WM_COMMAND. When I click on a Menu-Item, I can reseive a WM_COMMAND in one of my...
4
by: Just Me | last post by:
I've seen this in examples: Case User.WM_COMMAND Select Case (m.WParam.ToInt32 And &H7FFF0000) \ &H10000 My question is why is the most significant bit ignored?
8
by: Tony Johansson | last post by:
Hello! I just wonder what the difference is between a native win32-app and MFC. What I know is that you can use Win32 API in both cases. I think an MFC application is connected with a GUI...
2
by: Danny | last post by:
Hi I want to be able from my csharp button to start an application ( which I can do) and then somehow send a message to the win32 application that says "press the button" The win32...
1
by: Qudus | last post by:
How to use WM_COMMAND when press the push button through BS_PUSHBUTTON in WINDOWS XP Platform give me the example of it in the source code visual c++ Thank You
0
by: jbenezech | last post by:
Hi all , I have a perl/java app running under Win32. The application consists of a perl service (Win32::Daemon) and of java classes. The perl service calls every xx hours java classes to perform...
3
by: somuchh8 | last post by:
Hi, I'm having a lot of trouble with the Win32::Spawn module in perl. Here is my situation, I have a Win32::Spawn call which looks like this: my $success = undef; my $cmdline =...
3
by: newguy194 | last post by:
I am writing a GUI for a program which scrambles text messages, but I believe I am running into buffer overflows somewhere and have tried various ways of stopping the overflows from happening. When...
3
johny10151981
by: johny10151981 | last post by:
Hi, Here a code part that create a group box and radio button hGroup=CreateWindowEx(0,L"BUTTON",L"Choose Connection type",...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
0
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.