VBA ON YOUR OWN: For Loop through table data - Simple Excel VBA

Поделиться
HTML-код
  • Опубликовано: 22 июл 2024
  • Welcome to the 1st episode of VBA On Your Own series!
    In todays video we're going to filter out data using For Loop!
    WATCH NEXT:
    ○ Do While Loop through table: • VBA ON YOUR OWN: Do Wh...
    TIME STAMPS:
    0:00 Intro
    0:17 Exercise: Loop through table data
    1:11 Variables declaration
    2:38 Constants
    3:03 With brackets
    4:44 For Loop
    6:13 Check the code
    7:40 We are on the road to 1000 subscribers!
    MY EQUIPMENT:
    ○ Microphone - amzn.to/3JidXEt
    ○ Keyboard - amzn.to/3sAMckx
    ○ Mouse - amzn.to/3euvwmn
    ○ Monitor - amzn.to/3qoJITq
    SITE & SOCIALS:
    ○ Website: simpleexcelvba.com/
    ○ Facebook: / simpleexcelvba
    ○ Pinterest: / simpleexcelvba
    ○ Buy me a coffee: www.buymeacoffee.com/SimpleEx...
    CONTACT:
    tomasz@simpleexcelvba.com
    Don't forget to leave like and subscribe to my channel, it means a lot to me :)
    DISCLAIMER: Links included in this description might be affiliate links. If you purchase a product or service with the links that I provide I may receive a small commission. There is no additional charge to you! Thank you for supporting my channel so I can continue to create and provide more content for You!
  • НаукаНаука

Комментарии • 9

  • @gerardvaneggermond2067
    @gerardvaneggermond2067 Год назад

    What I forgot is that the number of rows being searched is 20.

    • @SimpleExcelVBA
      @SimpleExcelVBA  Год назад

      This is the recorded part with macro recorder, but have You try anything? Any loop? :)

    • @gerardvaneggermond2067
      @gerardvaneggermond2067 Год назад

      @@SimpleExcelVBA No, because I don't know how to do it.

    • @SimpleExcelVBA
      @SimpleExcelVBA  Год назад

      ​@@gerardvaneggermond2067 Did You watch this video? I prepared this and others of my videos specifically to help in such cases like yours :) Please reach me after You try something and then we can solve the issues.

    • @gerardvaneggermond2067
      @gerardvaneggermond2067 Год назад

      @@SimpleExcelVBA What video do you want me to watch

    • @gerardvaneggermond2067
      @gerardvaneggermond2067 Год назад

      What video do you want me to watch, that she's seen this one, I don't know if this can help me, or how I can do this.

  • @gerardvaneggermond2067
    @gerardvaneggermond2067 Год назад

    Hello sir, maybe you can help me I made code in Vba but it is long now I would like to make it smaller and maybe "loop" and "for loop" can help with that.
    Here part of the code:
    Application.ScreenUpdating = False
    If Sheets("Menu").Range("E2") = 1 Then
    Sheets("toplay1").Select
    Range("A1").Select
    ActiveCell.Formula2R1C1 = _
    "=FILTER('S1'!R[1]C[1]:R[20]C[1],'S1'!R[1]C[1]:R[20]C[1]" "")"
    Range("B1").Select
    ActiveCell.Formula2R1C1 = _
    "=FILTER('S1'!R[1]C[5]:R[20]C[5],'S1'!R[1]C[5]:R[20]C[5]" "")"
    The Range continues until "J1" you also notice that at "c[ ] each time 4 are added, that is because the search area moves 4 columns each time, if you can help me with this I will be able to continue with the rest I think, can you help me PLEASE

    • @SimpleExcelVBA
      @SimpleExcelVBA  11 месяцев назад

      Unfortunately the situation is not clear to me. If You want my help please describe that as for the 3rd person without any context and visibility of the range, like I am now in this situation :)