Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

Excel VBA

Options
  • 20-03-2013 12:00pm
    #1
    Closed Accounts Posts: 561 ✭✭✭


    Hey,

    I would really like to improve my VBA skills- basically I want to learn how to build macros etc. Is there any good courses that people have been to. I can find some online but they are 1000euro...would be good to know if anyone has done any of these? Also is there any really good online sites to learn off- again looking for people who have used them?

    Cheers :)


Comments

  • Registered Users Posts: 44 TheNewMe


    Check out this site by Chip Pearson. I have used it a lot and have found it to be very helpful.

    http://www.cpearson.com/Excel/MainPage.aspx

    Also google is your friend and knows all the answers - all you need to do is ask the right question :)


  • Registered Users Posts: 400 ✭✭marcus2000


    I found the best way to learn VBA was to record macros, and then edit them to make them more reusable. Soon you learn the code and it all starts to come naturally.... Im probably a 'vba programmer'...i use that term lightly....., but I've never done a course myself......Also the website stackoverflow is good for questions/answers......


  • Closed Accounts Posts: 561 ✭✭✭keano2012


    brilliant thanks for the quick replies guys- il'll try and take a look later on :)

    i'm ok at excel- i know the basic formulas and whatever- will this hinder me in building macros? and will it make it tougher for me to learn online?


  • Registered Users Posts: 378 ✭✭frankmul


    I always found mrexcel.com good for excel and vba. Good forums


  • Closed Accounts Posts: 561 ✭✭✭keano2012


    sorry just one question on building macros. is the below a template that is used for all macros? I am completely new to all this so really havent a clue!

    Private Sub Workbook_Open()
    ThisWorkbook.Names.Add Name:="Flip", RefersTo:=0, Visible:=False
    End Sub

    Private Sub Workbook_BeforeClose(Cancel As Boolean)
    ThisWorkbook.Names.Add Name:="Flip", RefersTo:="A", Visible:=False
    End Sub


  • Advertisement
  • Registered Users Posts: 400 ✭✭marcus2000


    Not really sure what you mean.

    it looks to me that its a macro that creates a new Workbook when you open a workbook, and then again when you close it.
    (and its called "Flip")

    Basically , code will start something like this.

    Sub Test()

    Cells(1, 1) = "Hello"
    MsgBox ("I have just written hello in the first cell (row 1, column 1) in the worksheet")

    End Sub

    (saying that, you should just hit record macro....do something like select a few cells. delete some text...add some text). Hit stop record, then go into your visiable basic editor (Alt+F11) and take a look at the code)


  • Closed Accounts Posts: 561 ✭✭✭keano2012


    marcus2000 wrote: »
    Not really sure what you mean.

    it looks to me that its a macro that creates a new Workbook when you open a workbook, and then again when you close it.
    (and its called "Flip")

    Basically , code will start something like this.

    Sub Test()

    Cells(1, 1) = "Hello"
    MsgBox ("I have just written hello in the first cell (row 1, column 1) in the worksheet")

    End Sub

    (saying that, you should just hit record macro....do something like select a few cells. delete some text...add some text). Hit stop record, then go into your visiable basic editor (Alt+F11) and take a look at the code)

    perfect thanks. That is just something i picked from the website. I just thought each code within a macro all had a same format and all i would have to do is change what i want each macro to do.


Advertisement