+ Reply to Thread
Results 1 to 8 of 8

VBA Code does recognise value in a cell if value is provided by formula.

  1. #1
    Registered User
    Join Date
    06-17-2018
    Location
    Coomealla, Australia
    MS-Off Ver
    Office 365
    Posts
    10

    VBA Code does recognise value in a cell if value is provided by formula.

    Hi All,
    its been along time since I visited this forum. I need some assistance please.

    I have a form that inputs data into a worksheet and it also allows me to change the data in any record (line of data) l select. This is done using a combo box on the form selecting a unique number that I have given each record. The column where the unique number is stored comes from another worksheet in the same workbook which is a obtained by a formula.

    When I use the combo box to select the specific unique number I require they all show up and I can select the unique number that I want and all data associated with that number is visible and can be changed.

    When I press the submit button on the form I get the Run-time error '91' : object variable or with block not set

    If I was to manually type the unique number into the column where they are stored and use the form it works perfectly. So I believe the code is not recognizing the value that the formula is inputting as a valid piece of data. I think!

    thank you.

    Here is the code. I hope I am doing this correctly.

    Please Login or Register  to view this content.
    Last edited by bretthullah; 06-18-2019 at 02:59 AM.

  2. #2
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,445

    Re: VBA Code does recognise value in a cell if value is provided by formula.

    Code tags added by OP
    Last edited by Pepe Le Mokko; 06-18-2019 at 03:07 AM.

  3. #3
    Registered User
    Join Date
    06-17-2018
    Location
    Coomealla, Australia
    MS-Off Ver
    Office 365
    Posts
    10

    Re: VBA Code does recognise value in a cell if value is provided by formula.

    Thank you. I have made the change
    cheers

  4. #4
    Forum Expert nilem's Avatar
    Join Date
    10-22-2011
    Location
    Ufa, Russia
    MS-Off Ver
    2013
    Posts
    3,377

    Re: VBA Code does recognise value in a cell if value is provided by formula.

    Hi bretthullah,
    try something like this instead of using Find
    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    06-17-2018
    Location
    Coomealla, Australia
    MS-Off Ver
    Office 365
    Posts
    10

    Re: VBA Code does recognise value in a cell if value is provided by formula.

    Thanks nilem. I will give it a try.

  6. #6
    Registered User
    Join Date
    06-17-2018
    Location
    Coomealla, Australia
    MS-Off Ver
    Office 365
    Posts
    10

    Re: VBA Code does recognise value in a cell if value is provided by formula.

    Hi nilem,
    I have tried using the code you provided. It partially works.

    The form will only input the data for txtNetWeight.value , anything after ie txtRate.Value and so on remains blank

    Please Login or Register  to view this content.

  7. #7
    Registered User
    Join Date
    06-17-2018
    Location
    Coomealla, Australia
    MS-Off Ver
    Office 365
    Posts
    10

    Re: VBA Code does recognise value in a cell if value is provided by formula.

    All sorted nilem. The problem was my typing. It works great Thank you.
    Cheers

    Below is the working code

    Please Login or Register  to view this content.

  8. #8
    Registered User
    Join Date
    06-17-2018
    Location
    Coomealla, Australia
    MS-Off Ver
    Office 365
    Posts
    10

    Re: VBA Code does recognise value in a cell if value is provided by formula.

    my problem has been "SOLVED"

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. VBA Code does recognise value in a cell if value is provided by formula.
    By bretthullah in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-18-2019, 02:49 AM
  2. Replies: 5
    Last Post: 09-14-2015, 03:29 AM
  3. [SOLVED] Formula in one cell that picks up another based on dates provided in the same sheet
    By s.tara91 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 08-16-2013, 12:58 AM
  4. Formula to recognise one word from multiple words in the same cell
    By JLucy in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 06-27-2013, 11:48 AM
  5. Replies: 3
    Last Post: 01-11-2012, 08:17 AM
  6. Locking a cell that contains a formula that has provided a result
    By redders in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-16-2010, 05:14 AM
  7. [SOLVED] How do I write a formula to color code based on dates provided or.
    By jaime in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 02-18-2005, 10:06 AM

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