Results 1 to 9 of 9
  1. #1
    animatedjay is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2012
    Posts
    5

    Cool i need a simple macro code to check of uncheck a box


    I am new to coding and i need a macro code to uncheck a yes/no check box when another field (date field) is updated. Macro code only since this is a web database and vb is not available. The only actions available are those listed in the screenshot below. Basically i need... if Date field is not null then uncheck the box.

  2. #2
    pbaldy's Avatar
    pbaldy is online now Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    No screen shot, but the action would be SetValue, with a condition testing the date field.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  3. #3
    animatedjay is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2012
    Posts
    5

    SetValue is not one on the list. ( that is why i'm having a tough time )Click image for larger version. 

Name:	Capture.PNG 
Views:	10 
Size:	15.6 KB 
ID:	7806

  4. #4
    pbaldy's Avatar
    pbaldy is online now Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    I don't have 2010 on this machine, but there's a button on the ribbon that says "Show all Actions". Does that add it to the list? It normally would, but I haven't worked much with web databases.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  5. #5
    animatedjay is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2012
    Posts
    5
    Unfortunately no. These are the limitations of putting an access database on a share point site. This would have to be achieved by (i think) setting a temp value of the existing field and then setting the property of the check box? i don't know. That's why i'm asking the forum.

    Oh, and the answer to your question is.... John Galt is a fictional character in Ayn Rand's novel Atlas Shrugged (1957). Although he is not identified by name until the last third of the novel, he is the object of its often-repeated question "Who is John Galt?" and of the quest to discover the answer.

  6. #6
    pbaldy's Avatar
    pbaldy is online now Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    Fired up a VM with 2010 on it, and you appear to be correct that SetValue is not available in a web database. Untested, but it appears you could use SetProperty in its place, since one of the properties you can set is the Value property. See if that gets you anywhere.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  7. #7
    animatedjay is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2012
    Posts
    5
    Tried that but the "after update" event is not available for Web databases. is what it tells me. This is frustrating!

  8. #8
    pbaldy's Avatar
    pbaldy is online now Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    I was excited when I first heard about the web database at a Microsoft event in 2008, but the reality of it has proven more restrictive than I find practical, so I haven't created any (personal opinion; smarter people than I have done great things with them). How about a data macro to change the field value?
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  9. #9
    animatedjay is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2012
    Posts
    5
    i'll try anything. what i have is this... there is a table of devices. 4000 laptops, desktops, printers etc. this table has the device serial number, Asset Tag, and a check box for Out on Loan (plus other device info, like make, model, location, etc.) Then there is another table for device that are Out On Loan. I have to keep the tables separate so i can report on a history of the same devices that were loaned out. if i had it all on the same table, that would only tell me the last time the device was loaned out. Hence the 2 tables.... anyway. For the out on loan table i have the device asset tag field, the loaned start date, the loaned end date and the Out on loan check box again (not tied to the devices table). The tech enters (on the out on loan table via a form) the device asset tag, and the start date. the out on loan checkbox's default value is set to true. when the device is returned the tech enters in the loaned end date and unchecks the out on loan checkbox. i need to have this out on loan checkbox from the out on loan table reflect the out on loan check box from the devices table. I have tried to tie the tables together via relationships and/or queries but without success. please help. Thank you.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Noob Question macro to check checkbox
    By bradmitchell in forum Access
    Replies: 1
    Last Post: 05-13-2012, 10:08 PM
  2. Right Click checkbox to uncheck?
    By JubilantJeff in forum Forms
    Replies: 7
    Last Post: 12-19-2011, 02:12 PM
  3. simple VB code help
    By avworx in forum Programming
    Replies: 2
    Last Post: 03-29-2011, 07:09 PM
  4. Check/Uncheck Checkbox on "Enter" click
    By emilyrogers in forum Forms
    Replies: 2
    Last Post: 02-17-2011, 10:24 AM
  5. Can't create a simple macro......
    By Sarge, USMC in forum Access
    Replies: 1
    Last Post: 01-05-2011, 11:48 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums