Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

!!!! Mouse wheel scroll code for two forms !!!

Status
Not open for further replies.
Aug 4, 2004
84
US
Hello, all!

Just let me say that this site again, is amazing. Secondly, I have used the following link from a thread on this site,


to prevent the mouse wheel form scrolling through records. I have the code in one form and want to use it on another form. The code works great, however when I save the new code in VB, the database tells me there is already code saved as this name,(which makes sense) and would you like to replace?

I don't want to replace the code correct? Do I have to change what i save the code as for the new form? For example save as SubClassWindow2 instead of SubCLassWindow?

thanks

AB
 
Might this be a case where you could save the code once as a public sub in a module, and then call it in each of the forms?
 
I can't view your link - or I'd give you the exact syntext

I would say you need to SAVE the code in a module, then on OPEN or LOAD put =YourFunctionName

or, you can put in the code for the on OPEN or LOAD event
call YOURFUNCTIONNAME

if your function requires any parameters you'll have to pass them of course.



Randall Vollen
National City Bank Corp.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top