+ Reply to Thread
Results 1 to 4 of 4

Excel Formula in VBA code

  1. #1
    Forum Contributor
    Join Date
    09-08-2011
    Location
    Leicester, England
    MS-Off Ver
    Excel 2007
    Posts
    157

    Excel Formula in VBA code

    I'm currently getting my VB userform to look at a certain cells contents then just display based on whatever that box is. But If i move those boxes etc it crashes out on the userform and I have to go change location of where to lookup etc.

    Is their a way I can to get it to read in the 3 values I set then do the calculation fromVB rather than do the calculation on the excel form then display thats output?

    Thanks in Advance

  2. #2
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Excel Formula in VBA code

    Can you explain what you mean by moving boxes?
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

  3. #3
    Forum Contributor
    Join Date
    09-08-2011
    Location
    Leicester, England
    MS-Off Ver
    Excel 2007
    Posts
    157

    Re: Excel Formula in VBA code

    As in if I move the content to a different cell location, e.g. may be reading from a2, then I move and it would read from g55 for example

  4. #4
    Forum Contributor
    Join Date
    09-08-2011
    Location
    Leicester, England
    MS-Off Ver
    Excel 2007
    Posts
    157

    Re: Excel Formula in VBA code

    attached an example of what I mean, I just want to do the working out between two dates for the particular drop down, I know the calculation, just messing up atm, because in the userform i change the dates, drop-down option then it changes the excel contents then excel changes the contents based on what ive just worked out to 15 for example then displays it in a box which i display on the userform

    I just basically want it to work it all out in the vba code based on my cell contents
    Attached Files Attached Files

+ 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