VBcoders Guest



Don't have an account yet? Register
 


Forgot Password?



SubClassing to enable response to menus made at runtime

by Nick Smith (8 Submissions)
Category: Custom Controls/Forms/Menus
Compatability: Visual Basic 3.0
Difficulty: Intermediate
Date Added: Wed 3rd February 2021
Rating: (4 Votes)

When making menus with Win32 API functions, have you ever wondered how to call functions when the user clicks on a menu entry? This code shows you how to solve that problem using subclassing, in very few lines of code :) Please rate this.

Assumes
Dont click the stop button on the Visual Basic window, you must exit using the program, or else the windows procedure wont be handed back to the original window, causing an illegal operation error.
API Declarations
see .bas file

Rate SubClassing to enable response to menus made at runtime

Upload

Download this snippet    Add to My Saved Code

SubClassing to enable response to menus made at runtime Comments

No comments have been posted about SubClassing to enable response to menus made at runtime. Why not be the first to post a comment about SubClassing to enable response to menus made at runtime.

Post your comment

Subject:
Message:
0/1000 characters