Results 1 to 5 of 5
  1. #1
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Reading & Writing Cell Values (2003)

    Welcome to Woody's Lounge!

    Your question is rather broad. This forum contains lots and lots of examples of manipulating cell values through VBA, but without knowing what you require, it's hard to point to specific posts. You can browse around, or you can ask more specific questions - whichever you prefer.

  2. #2
    Uranium Lounger
    Join Date
    Jan 2001
    Location
    South Carolina, USA
    Posts
    7,295
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Reading & Writing Cell Values (2003)

    Since your question is VERY vague, it is tough to give you a good example. The following code takes a numeric value from cell C5 on the sheet named "Sheet1" adds one to it (good business logic there), and stores the result in cell D5 on the sheet named "Sheet2".

    <pre>Public Sub DoSomeBusinessLogic()
    Dim dInputValue As Double
    Dim dOutputValue As Double
    dInputValue = Worksheets("Sheet1").Range("C5").Value
    dOutputValue = dInputValue + 1
    Worksheets("Sheet2").Range("D6").Value = dOutputValue
    End Sub
    </pre>

    Legare Coleman

  3. #3
    New Lounger
    Join Date
    May 2005
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Reading & Writing Cell Values (2003)

    I have edited this post to include an attached example. I know this question is vague, but the example attached will help explain it. I have a spreadsheet, that a user would enter values in certain ranges of cells. I need to then take those values apply some business logic to them via VBA code, do some simple calculations in the code, and write the results to another sheet in a specific cells. My VBA skills are very rusty, especially with Excel and I need to get this done by sometime tomorrow (wednesday may 11th). Can anyone send me an example, or point me to one that does something very similar that I can tweak and re-use?

    Thanks!

  4. #4
    New Lounger
    Join Date
    May 2005
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Reading & Writing Cell Values (2003)

    Thanks Legare. That seems simple enough [img]/forums/images/smilies/smile.gif[/img] I had just edited my posting to include an attached example of what I was trying to do. Thanks again.

  5. #5
    Uranium Lounger
    Join Date
    Jan 2001
    Location
    South Carolina, USA
    Posts
    7,295
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Reading & Writing Cell Values (2003)

    Does that give you enough to get started? Come back with any specific questions.
    Legare Coleman

Posting Permissions

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