+ Reply to Thread
Results 1 to 2 of 2

VBA Order of Operations and 400 Error

Hybrid View

Ascension VBA Order of Operations and... 10-25-2010, 09:50 AM
davesexcel Re: VBA Order of Operations... 10-25-2010, 08:48 PM
  1. #1
    Registered User
    Join Date
    09-28-2010
    Location
    Boston, MA
    MS-Off Ver
    Excel 2007
    Posts
    31

    VBA Order of Operations and 400 Error

    Hey gurus,

    So I'm trying to construct the macro below and my error is coming from, I believe, the handling of the multiplication, division and possibly the pulling in of the information for the offset function. I'm looking for some input on the macro in terms of design and any clues as to how to make it work.

    *The worksheet is protected and cannot be posted online.*

    Macro Logic:
    Until the conditions are satisfied, iterate a multiplication of a variable user input number against a variable secondary number, the primary number is in a known location, the secondary location is unknown and changes (hence the necessary offset tied to a variable range).

    Thanks!


    MiniCount = 0
                            While MiniCount < Variable1 + 1
                                Sheet4.Range("Name1").Offset(0, Variable2 + MiniCount).Value = _
                                Sheet4.Range("Name1").Offset(0, Variable2 + MiniCount).Value + _
                                Variable 3 * _  (Sheet2.Range("Name2").Offset(Sheet2.Range("Name3").Value, 0) / 12)
                                MiniCount = MiniCount + 1
                            Wend

  2. #2
    Forum Moderator davesexcel's Avatar
    Join Date
    02-19-2006
    Location
    Regina
    MS-Off Ver
    MS 365
    Posts
    13,523

    Re: VBA Order of Operations and 400 Error

    Quote Originally Posted by Ascension View Post
    *The worksheet is protected and cannot be posted online.*
    Then post an example of the workbook with the code you are using....

+ 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