Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 02-12-2022, 05:49 PM
cybersurfer5000 cybersurfer5000 is offline VBA caption command Mac OS X VBA caption command Office 2021
Novice
VBA caption command
 
Join Date: Feb 2022
Posts: 6
cybersurfer5000 is on a distinguished road
Default VBA caption command

Hi.


I want to add 100 to the rectangle (named 'ascore') when clicking the up arrow that's right next to the rectangle (see screenshot). The macro is assigned to the up arrow shape. My VBA code is below. It does not work yet.


Error message when run the code in the debugger:

Run-time error '420'
Object required.



Sub ascoreplus()



ascore.Caption = ascore.Caption + 100

End Sub




Anyone sees where I made a mistake?

Thank you very much in advance!
Sophia
Attached Images
File Type: png Screen Shot 2022-02-12 at 7.43.31 PM.png (18.9 KB, 11 views)
Reply With Quote
 



Similar Threads
Thread Thread Starter Forum Replies Last Post
Command button. To multi command Taylormations Word VBA 11 09-14-2020 02:39 AM
Show table list by using chek box command and save document on sharepoint by using command button Zhibek Word VBA 3 08-16-2018 06:19 PM
Help with caption nightmare?? justletmein Word 5 05-09-2014 06:30 PM
VBA caption command Tab in TOF or caption?... JDB Word 1 12-02-2011 12:42 PM
Add-In:How to add command right click command bar phang Outlook 0 01-15-2007 02:53 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 11:42 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft