-Collapse +Expand
Paradox
Search Paradox Group:

Advanced
Paradox To/From
To/FromCODEGuides
Paradox Store
PRESTWOODSTORE

Prestwood eMagazine

April Edition
Subscribe now! It's Free!
Enter your email:

   ► MB LobbyCorel Paradox / ObjectPAL Coding BoardObjectPAL Topic   Print This     

How to Trap a mouse?

How to Trap a mouse? in ObjectPAL topic (part of our Corel Paradox / ObjectPAL Coding group).

Quick Search: How Trap   How Trap mouse  
rum
Frankfort, KY USA

Are there any examples of how to trap an event for a scroll wheel of a mouse?

I am having an issue with users unitentionally adding a record by scrolling the mouse wheel.   The form proprty AutoAppend is set to false,  and I trap Pg up and Pg down keys to prevent this issue.   Unfortunately I have not been able to trap the mouse wheel.

 Posted 6 years ago (Thread Starter)
Comment Quote
About rum
Visit Profile
Membership pending.
Member subscribes to this thread with a verified email.
Member pending approval.
Web Presence Hidden.
Once above is taken care of, full Profile content will display including back links, about me, my message, custom Profile html, social networking links, message board signature, company profile, etc.

Post ID #18205, 4 replies
Thread Started 10/12/2020 7:16:20 AM
View Counter=716
Last Reply Posted 12/7/2020 6:15:32 AM)
Location=Frankfort, KY USA 
Joined=9 years ago   MB Posts=128  
Moderator
Steven.G
Myrtle Beach, SC USA

I just looked at one of my forms.. auto append off, scroll wheel does nothing.. auto append on, scroll wheel changes records

Steven Green
Senior Software Engineer
Paradox Support Specialist DOS/WIN

Prestwood IT Solutions
8421 Auburn Blvd, Suite 256, Citrus Heights, CA 95610
Office: 916-726-5675 | Fax: 916-726-5676 | http://www.prestwood.com
 Posted 6 years ago
Comment Quote
About Steven.G
Visit Profile
Approved member.
Member subscribes to this thread with a verified email.
Old Account!
If this is your account, sign in to activate web presence data (sign in quarterly to keep active). Alternatively, you can subscribe to our monthly eMag with a valid email address.
Web Presence Hidden.
Once above is taken care of, full Profile content will display including back links, about me, my message, custom Profile html, social networking links, message board signature, company profile, etc.

Post ID #18206 (Level 2) and Parent is 18205
Reply Posted 10/12/2020 7:29:11 AM
Location=Myrtle Beach, SC USA 
Joined=10 years ago   MB Posts=463  
Moderator
Steven.G
Myrtle Beach, SC USA

and I know that was the specific reason I turned auto append off on that form.. I remember the problem it created when somebody decided to play "wheel of fortune" on that form (sigh)

Steven Green
Senior Software Engineer
Paradox Support Specialist DOS/WIN

Prestwood IT Solutions
8421 Auburn Blvd, Suite 256, Citrus Heights, CA 95610
Office: 916-726-5675 | Fax: 916-726-5676 | http://www.prestwood.com
 Posted 6 years ago
Comment Quote
About Steven.G
Visit Profile
Approved member.
Member subscribes to this thread with a verified email.
Old Account!
If this is your account, sign in to activate web presence data (sign in quarterly to keep active). Alternatively, you can subscribe to our monthly eMag with a valid email address.
Web Presence Hidden.
Once above is taken care of, full Profile content will display including back links, about me, my message, custom Profile html, social networking links, message board signature, company profile, etc.

Post ID #18207 (Level 3) and Parent is 18205
Reply Posted 10/12/2020 7:30:28 AM
Location=Myrtle Beach, SC USA 
Joined=10 years ago   MB Posts=463  
Ellio.M
-- UNK

I had a similar problem to get control of the mouse scroll wheel.

Found some code on the board that solved my problem.

I usa a form with a single record table plus a atble frame to show selected query results from the table. The code shown, disables the scroll wheel when in edit mode. While in view mode I can scroll the records as well as the results in the table frame.

(When using a mouse control app that enables scrolling in the editor, such as KatMouse (enabled), scrolling in the running form is not working)

method action(var eventInfo ActionEvent)

var
thetarget UIObject
endvar
;// Original Code on http://www.prestwoodboards.com/ASPSuite/eBoard/Thread.asp?MBID=406#MBID470
;// By HTH somebody - Matthew Wegener -ISoft Data Systems, Inc.
;// Works without : if eventInfo.isPreFilter() then  .....
;// This code executes for each object on the form  ... else....
;// Needed to disable the mousewheel while editing a single record on a form (from a Multi Record layout)
;// while keeping available the mousewheel scrolling option in other table frames linked to different
;// tables on the form.  When not in editing mode, scrolling through the records must remain available.
;// Corel should edit and update the ObjectPal reference if not update Paradox completely and compile
;// everything to 64bit version. undecidedI guess it's about time if you intend to keep the software in the Office Suite cool

If self.isEdit() then

switch

case eventInfo.id() = datapriorrecord:
eventinfo.setErrorCode(UserError)
eventInfo.getTarget(theTarget)
thetarget.action(Fieldbackward)

case eventInfo.id() = datanextrecord:
eventinfo.seterrorcode(UserError)
eventInfo.getTarget(theTarget)
thetarget.action(Fieldforward)

case eventInfo.id() = MoveScrollPageUp:
eventinfo.setErrorCode(UserError)

case eventInfo.id() = MoveScrollPageDown:
eventinfo.setErrorCode(UserError)

endswitch
endIf

endMethod

 Posted 6 years ago
Comment Quote
About Ellio.M
Visit Profile
Approved member.
Member subscribes to this thread with a verified email.
Old Account!
If this is your account, sign in to activate web presence data (sign in quarterly to keep active). Alternatively, you can subscribe to our monthly eMag with a valid email address.
Web Presence Hidden.
Once above is taken care of, full Profile content will display including back links, about me, my message, custom Profile html, social networking links, message board signature, company profile, etc.

Post ID #18283 (Level 4) and Parent is 18205
Reply Posted 12/5/2020 8:50:31 AM
Location=-- UNK 
Joined=16 years ago   MB Posts=3  
Most Recent Post
Moderator
Steven.G
Myrtle Beach, SC USA

just an FYI on your "Corel should update" comment in your code.. ain't gonna happen, for many reasons.. paradox 11 is paradox 11.. that's the canvas we have to work with

Steven Green
Senior Software Engineer
Paradox Support Specialist DOS/WIN

Prestwood IT Solutions
8421 Auburn Blvd, Suite 256, Citrus Heights, CA 95610
Office: 916-726-5675 | Fax: 916-726-5676 | http://www.prestwood.com
 Posted 6 years ago
Comment Quote
About Steven.G
Visit Profile
Approved member.
Member subscribes to this thread with a verified email.
Old Account!
If this is your account, sign in to activate web presence data (sign in quarterly to keep active). Alternatively, you can subscribe to our monthly eMag with a valid email address.
Web Presence Hidden.
Once above is taken care of, full Profile content will display including back links, about me, my message, custom Profile html, social networking links, message board signature, company profile, etc.

Post ID #18286 (Level 5) and Parent is 18205
Reply Posted 12/7/2020 6:12:22 AM
Location=Myrtle Beach, SC USA 
Joined=10 years ago   MB Posts=463  

Revive Thread!

Add a comment to revive this old thread and make this archived thread more useful.

Write a Comment...
Full Editor
...
Sign in...

If you are a member, Sign In. Or, you can Create a Free account now.


Anonymous Post (text-only, no HTML):

Enter your name and security key.

Your Name:
Security key = P1213A1
Enter key:
Icon: A Post    Thread    Idea    Important!    Cool    Sad    No    Yes    Includes a Link...   
Thread #18205 Counter
716
Since 10/12/2020
Go ahead!   Use Us! Call: 916-726-5675  Or visit our new sales site: 
www.prestwood.com


©1995-2026 Prestwood IT Solutions.   [Security & Privacy]