+ Reply to Thread
Results 1 to 5 of 5

Change text of cell if cell is greater than nothink withen range

  1. #1
    Valued Forum Contributor
    Join Date
    05-14-2009
    Location
    gold coast
    MS-Off Ver
    Excel 2007
    Posts
    843

    Change text of cell if cell is greater than nothink withen range

    Hello.

    I would like to change the name of all cells withen xrange with a text value greater than nothink.

    Please Login or Register  to view this content.
    Thankyou

    i know i can do it all at once like
    range("E4:F60203").Value = ""
    Though would like to know how its done one cell at a time
    Last edited by D_Rennie; 07-16-2009 at 10:36 AM.

  2. #2
    Forum Expert Palmetto's Avatar
    Join Date
    04-04-2007
    Location
    South Eastern, USA
    MS-Off Ver
    XP, 2007, 2010
    Posts
    3,978

    Re: Change text of cell if cell is greater than nothink withen range

    Do you mean if the cell is a blank you want the value to be "Test"?

    Please Login or Register  to view this content.
    If that's not correct, please be more clear in your explanation.

  3. #3
    Forum Guru romperstomper's Avatar
    Join Date
    11-04-2008
    Location
    A1
    MS-Off Ver
    Most
    Posts
    12,302

    Re: Change text of cell if cell is greater than nothink withen range

    Top tip: under Tools-Opions in the VBE, make sure the 'Require variable declaration' option is checked on the Editor tab. It would have caught your misspelling of OneCell as onecel (with only one L). You still need to change .Text to .Value when writing to the cell.
    Remember what the dormouse said
    Feed your head

  4. #4
    Valued Forum Contributor
    Join Date
    05-14-2009
    Location
    gold coast
    MS-Off Ver
    Excel 2007
    Posts
    843

    Re: Change text of cell if cell is greater than nothink withen range

    Cheers guys.
    RomperStomper even with the 'Require variable declaration' option is checked it didnt seam to pick up on the spelling. Would be great if there was a spellcheck. Is there somthink else that i need to enable for this

    As you can tell im not much of a pro-grammer

  5. #5
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Change text of cell if cell is greater than nothink withen range

    Add Option Explicit to the very top of each module.

    The VBE does this automatically when you tick the box and create a new module, but does not insert one retroactively in existing modules. The checkbox should more accurately be called "Add Option Explicit to new modules"
    Entia non sunt multiplicanda sine necessitate

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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