+ Reply to Thread
Results 1 to 16 of 16

Message box in a reset button

  1. #1
    Forum Contributor
    Join Date
    10-05-2014
    Location
    CALIFORNIA
    MS-Off Ver
    2010
    Posts
    1,721

    Message box in a reset button

    Hello all,
    can you please fix my reset button code.
    In cell J4 I have a message box after I do an entry and then it goes into the next cell.

    After all my entry there is a reset button that I click to reset all my entry. But when I click the button box, the message box appear.
    The Range("J4").Select is added for a good purpose. I want my cursor to return in J4 after I click the button.

    Here is the reset button code I have in the VBA.

    Please Login or Register  to view this content.

  2. #2
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    7,015

    Re: Message box in a reset button

    .
    I don't understand your comments about the MsgBox .... however, I believe this is the macro you are seeking :

    Please Login or Register  to view this content.

  3. #3
    Forum Contributor
    Join Date
    10-05-2014
    Location
    CALIFORNIA
    MS-Off Ver
    2010
    Posts
    1,721

    Re: Message box in a reset button

    Hi
    sorry... I didn't work.

  4. #4
    Forum Contributor
    Join Date
    10-05-2014
    Location
    CALIFORNIA
    MS-Off Ver
    2010
    Posts
    1,721

    Re: Message box in a reset button

    In cell J4 I have a message box after I do an entry and then it goes into the next cell.
    Please Login or Register  to view this content.
    After I do all my entry, there is a "reset button" that it clears all my entry in the cells. But when I click the reset button, it appears the message box.
    Please Login or Register  to view this content.

  5. #5
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    7,015

    Re: Message box in a reset button

    .
    Please Login or Register  to view this content.

  6. #6
    Forum Contributor
    Join Date
    10-05-2014
    Location
    CALIFORNIA
    MS-Off Ver
    2010
    Posts
    1,721

    Re: Message box in a reset button

    Hi
    When I click the reset button it does not appear the message box. Its good but now Every time I do an entry on each cell J4,AI5,C8,C14,C20, the message box appear.

  7. #7
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    7,015

    Re: Message box in a reset button

    .
    Tested and works here :

    Please Login or Register  to view this content.

  8. #8
    Forum Contributor
    Join Date
    10-05-2014
    Location
    CALIFORNIA
    MS-Off Ver
    2010
    Posts
    1,721

    Re: Message box in a reset button

    Yay! It worked. Thank you so much.

  9. #9
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    7,015

    Re: Message box in a reset button

    .
    You are welcome. Glad to help.

  10. #10
    Forum Contributor
    Join Date
    10-05-2014
    Location
    CALIFORNIA
    MS-Off Ver
    2010
    Posts
    1,721

    Re: Message box in a reset button

    Hi
    Do you think you'll be able to remove the gray color on these cells?
    A1,A2,B2,C3

    I have been trying to ask everyone but I can't get no answer.
    But if no, no problem. I pretty almost complete my project except I can't get rid the gray color.


    Thanks.
    Attached Files Attached Files

  11. #11
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    7,015

    Re: Message box in a reset button

    .
    This portion of the Worksheet_SelectionChange event is controlling the coloring of those cells:

    Please Login or Register  to view this content.
    If you delete that portion of the macro, the coloring should disappear.

  12. #12
    Forum Contributor
    Join Date
    10-05-2014
    Location
    CALIFORNIA
    MS-Off Ver
    2010
    Posts
    1,721

    Re: Message box in a reset button

    Hi...
    I don't know what to do. Still does not work.
    I took the selection out from the code then the tab stop working.

    Private Sub Worksheet_Change(ByVal target As Range)

    Thanks.

  13. #13
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    7,015

    Re: Message box in a reset button

    .
    I included too much code in my last post of what to remove.

    Keep this portion :


    Please Login or Register  to view this content.

    REMOVE this part :

    Please Login or Register  to view this content.
    Seems to work well here. Does it function well there ?

  14. #14
    Forum Contributor
    Join Date
    10-05-2014
    Location
    CALIFORNIA
    MS-Off Ver
    2010
    Posts
    1,721

    Re: Message box in a reset button

    Hi
    If I removed this part then my tab order disappear. I will not longer have the order as I want for my tab :o(

  15. #15
    Forum Contributor
    Join Date
    10-05-2014
    Location
    CALIFORNIA
    MS-Off Ver
    2010
    Posts
    1,721

    Re: Message box in a reset button

    Check this out (see attachment) I created another one. This work perfect for me. But you may be able to resolve it.
    The only problem with this is that when I press the tab/enter key if keeps hitting the check box.
    I need to be able to just click the box but be able to tab it order that it only goes in A1,B2.

    How do I skip hitting the check box?
    Attached Files Attached Files

  16. #16
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    7,015

    Re: Message box in a reset button

    .
    This arrangement of your existing code removes E8 & E10 from the tab sequence :

    Please Login or Register  to view this content.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Create running stopwatch/timer with 1 button (start/stop). No reset button.
    By leeroy2612 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 05-26-2021, 12:59 AM
  2. Undo button from reset button
    By RJ1969 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 01-24-2019, 01:19 AM
  3. [SOLVED] Button Reset
    By RJ1969 in forum Excel General
    Replies: 6
    Last Post: 01-01-2019, 09:30 AM
  4. [SOLVED] I need to create a reset button that will reset rows containing a specific value
    By odin78 in forum Excel Programming / VBA / Macros
    Replies: 18
    Last Post: 04-03-2016, 02:11 PM
  5. VBA as a reset button
    By tantcu in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 12-10-2013, 12:39 AM
  6. Reset Button
    By alvstar2001 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-22-2013, 06:03 AM
  7. [SOLVED] Message Boxes in Reset Macro
    By amotto11 in forum Excel Programming / VBA / Macros
    Replies: 24
    Last Post: 05-29-2012, 11:53 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1