+ Reply to Thread
Results 1 to 13 of 13

VBA Macros Error

  1. #1
    Valued Forum Contributor
    Join Date
    01-11-2012
    Location
    Riyadh, K.S.A.
    MS-Off Ver
    Windows 11 with Excel 2013 & 2016
    Posts
    905

    VBA Macros Error

    Hello,

    I am having a problem with the VBAMacros after changing the places of columns. After these changes the script is saying "Object variable or With block variable not set. Can you help me to setup this issue.


    Please Login or Register  to view this content.

    Copy of sheet is attached for your easy reference.
    Last edited by hecgroups; 03-14-2012 at 04:12 PM.

  2. #2
    Valued Forum Contributor
    Join Date
    08-29-2011
    Location
    Mississauga, CANADA
    MS-Off Ver
    Excel 2010
    Posts
    503

    Re: VBA Macros Error

    Here you Go
    Attached Files Attached Files
    Regards,
    Khaled Elshaer
    www.BIMcentre.com

    Remember To Do the Following....
    1. Thank those who have helped you by clicking the Star below their post.
    2. Mark your post SOLVED if it has been answered satisfactorily:
    • Select Thread Tools (on top of your 1st post)
    • Select Mark this thread as Solved

  3. #3
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: VBA Macros Error

    hi hecgroups, try this, I hope I did follow the logic:

    Please Login or Register  to view this content.

  4. #4
    Valued Forum Contributor
    Join Date
    01-11-2012
    Location
    Riyadh, K.S.A.
    MS-Off Ver
    Windows 11 with Excel 2013 & 2016
    Posts
    905

    Re: VBA Macros Error

    Thanks watersev your script works but one more thing if you see my attached file you will find the member calculation which is not working now i am sure because of the changes. Can you help me to fix that also.

    Summary of census

  5. #5
    Valued Forum Contributor
    Join Date
    08-29-2011
    Location
    Mississauga, CANADA
    MS-Off Ver
    Excel 2010
    Posts
    503

    Re: VBA Macros Error

    hecgroups : Did you try the file I attached?

  6. #6
    Valued Forum Contributor
    Join Date
    01-11-2012
    Location
    Riyadh, K.S.A.
    MS-Off Ver
    Windows 11 with Excel 2013 & 2016
    Posts
    905

    Re: VBA Macros Error

    Yes i have try but no luck but i have replaced your code with Mr. watersev's code it works and it works fine for me. Thanks for your valuable time and help for me.

  7. #7
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: VBA Macros Error

    as far as I can see the question goes to formulas in "Summary of Census" data table. As I'm using Excel 2003 the CountIfs function of Excel 2007 is unavailable for me to check if corrections are right. Besides my wife has occupied the notebook with Excel 2007 with no chances to get there today at least. Though give it a try your end for cell U5 and if OK extend it down and to the right:

    Please Login or Register  to view this content.

  8. #8
    Valued Forum Contributor
    Join Date
    01-11-2012
    Location
    Riyadh, K.S.A.
    MS-Off Ver
    Windows 11 with Excel 2013 & 2016
    Posts
    905

    Re: VBA Macros Error

    I have fixed it thanks for your help and cooperation. Topic closed and reputation added.

  9. #9
    Valued Forum Contributor
    Join Date
    01-11-2012
    Location
    Riyadh, K.S.A.
    MS-Off Ver
    Windows 11 with Excel 2013 & 2016
    Posts
    905

    Re: VBA Macros Error

    watersev your script is displaying an error saying "Object variable or With block variable not set" when i check with my original file.

    Please note that the list of members can be anysize might be 5,000 or 9,000 or mightbe 20,000 member list also.

    Can you help me to resolve this issue please.

  10. #10
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: VBA Macros Error

    can I have a file giving that error?

  11. #11
    Valued Forum Contributor
    Join Date
    01-11-2012
    Location
    Riyadh, K.S.A.
    MS-Off Ver
    Windows 11 with Excel 2013 & 2016
    Posts
    905

    Re: VBA Macros Error

    It is working fine it is my mistake i have copied old file for testing.

  12. #12
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: VBA Macros Error

    ok...............

  13. #13
    Valued Forum Contributor
    Join Date
    01-11-2012
    Location
    Riyadh, K.S.A.
    MS-Off Ver
    Windows 11 with Excel 2013 & 2016
    Posts
    905

    Re: VBA Macros Error

    I have given the file to my boss he said he will check it thoroughly and give update. Very soon i will give you feedback. Being the discussion might be we have to change some little changes.

+ 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