+ Reply to Thread
Results 1 to 7 of 7

Default cell in cell after re-written and deleting

  1. #1
    Registered User
    Join Date
    09-12-2013
    Location
    Toronto
    MS-Off Ver
    Excel 2007
    Posts
    8

    Unhappy Default cell in cell after re-written and deleting

    So basically here is what i want to do in my simplistic language

    If cell A9 is blank then add text 'Enter'.
    - so i want ppl to see the word 'Enter' they enter their text. When they delete the text 'Enter' reappears.

    However if they save the file with their other data - when opening up the file i want something like
    If cell A9 does not = 'Enter' then add text 'Enter'

    Please help me!
    and i do not know VBA so please explain to me like i am a child.

  2. #2
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Default cell in cell after re-written and deleting

    Hi thedude1222

    You can use a Workbook Open Event to populate Cell A9 with the word "Enter".
    Please Login or Register  to view this content.
    You can use a Worksheet Change Event for this
    If cell A9 is blank then add text 'Enter'.
    - so i want ppl to see the word 'Enter' they enter their text. When they delete the text 'Enter' reappears.
    Please Login or Register  to view this content.
    To insert the Code:
    Go to VBA ===> Alt + F11
    In the Left Panel double click on Workbook
    Copy/Paste the Workbook Open Event Code into the Right Panel
    Now, Double Click on the appropriate Worksheet that you've defined in the Workbook Open Code
    Copy/Paste the Worksheet Change Event Code into the Right Panel
    Go back to Excel ===> Alt + F11
    Save the Workbook as a Macro Enabled Workbook.
    John

    If you have issues with Code I've provided, I appreciate your feedback.

    In the event Code provided resolves your issue, please mark your Thread as SOLVED.

    If you're satisfied by any members response to your issue please use the star icon at the lower left of their post.

  3. #3
    Registered User
    Join Date
    09-12-2013
    Location
    Toronto
    MS-Off Ver
    Excel 2007
    Posts
    8

    Re: Default cell in cell after re-written and deleting

    it's not working.. how can i attach the file for you to review...

  4. #4
    Registered User
    Join Date
    09-12-2013
    Location
    Toronto
    MS-Off Ver
    Excel 2007
    Posts
    8

    Re: Default cell in cell after re-written and deleting

    each time i open the file it lists (General) instead of workbook and (Declarations) instead of change.
    also when i try and run macro it doesnt even show it existing.

  5. #5
    Forum Expert Fotis1991's Avatar
    Join Date
    10-11-2011
    Location
    Athens(The homeland of the Democracy!). Greece
    MS-Off Ver
    Excel 1997!&2003 & 2007&2010
    Posts
    13,744

    Re: Default cell in cell after re-written and deleting

    To attach a small sample workbook.

    Click on GO ADVANCED and use the paperclip icon to open the upload window.

    View Pic
    Regards

    Fotis.

    -This is my Greek whisper to Europe.

    --Remember, saying thanks only takes a second or two. Click the little star * below, to give some Rep if you think an answer deserves it.

    Advanced Excel Techniques: http://excelxor.com/

    --KISS(Keep it simple Stupid)

    --Bring them back.

    ---See about Acropolis of Athens.

    --Visit Greece.

  6. #6
    Registered User
    Join Date
    09-12-2013
    Location
    Toronto
    MS-Off Ver
    Excel 2007
    Posts
    8

    Re: Default cell in cell after re-written and deleting

    Project aaa.xlsm

    Thanks for your help,

    Id also like to have a time stamp for anytime a new Contract # (A21) is added to show up in L21.

  7. #7
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Default cell in cell after re-written and deleting

    Hi thedude1222

    When I open your newly posted Workbook, "Enter Contract #" is in Cell A9. When manually I enter a Contract # in Cell A9 and Tab out of Cell A9, the Contract details are displayed. When I Clear Cell A9, "Enter Contract #" is in Cell A9 and all Contract details disappear. Does this NOT happen for you?

    Regarding this
    when i try and run macro it doesn't even show it existing
    These are Event macros...you won't see them. They are triggered when an Event happens...you don't "Run" them...the "Event" runs them.

+ 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. [SOLVED] How to address copy destination cell in VBA if cell adress is written as a text elswhere
    By flyman in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-08-2013, 05:29 PM
  2. Replies: 20
    Last Post: 04-16-2012, 10:39 AM
  3. Replies: 3
    Last Post: 05-23-2010, 12:49 PM
  4. RE: advance data to next cell when over written?
    By Vacation's Over in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 10-19-2005, 05:05 PM
  5. how can I check if there is text written in a cell?
    By hendersson in forum Excel General
    Replies: 4
    Last Post: 10-12-2005, 09:38 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