Results 1 to 3 of 3

Thread: How do I set a value in MS Excel?

  1. #1

    Thread Starter
    New Member
    Join Date
    May 2006
    Posts
    1

    How do I set a value in MS Excel?

    How do I set a value in a MS Excel cell from inside my VB Macro?
    Paul

  2. #2
    Super Moderator si_the_geek's Avatar
    Join Date
    Jul 2002
    Location
    Bristol, UK
    Posts
    41,974

    Re: How do I set a value in MS Excel?

    Moved from FAQ forum

  3. #3
    Frenzied Member DKenny's Avatar
    Join Date
    Sep 2005
    Location
    on the good ship oblivion..
    Posts
    1,171

    Re: How do I set a value in MS Excel?

    Welcome to the Forums

    The answer to your question depends on how you are referring to the cell in question. Can you elaborate a little more on How you are determining which cell you need to change?

    Also if you could post the code you have so far, that would help as well.

    The most basic way is to directly refer to the cell as a range
    VB Code:
    1. Workbooks("BookName").Worksheets("SheetName").Range("A1").Value = "Your Value"
    Last edited by DKenny; May 9th, 2006 at 03:51 PM.
    Declan

    Don't forget to mark your Thread as resolved.
    Take a moment to rate posts that you think are helpful

Posting Permissions

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



Click Here to Expand Forum to Full Width