fbpx
Search
Close this search box.

All articles in 'VBA Macros' Category

How to use Cells, Ranges & Other Objects in Excel VBA

Published on Aug 31, 2011 in VBA Macros
How to use Cells, Ranges & Other Objects in Excel VBA

In part 3 of our VBA Crash Course, we are going to learn how to speak with various Excel objects like Cells, Ranges etc. and deal with them.

Objects – what are they?

Any thing and everything is an object. Your dog, your bed, your neighbors cat, their car, your bike, your computer, the shiny new Excel workbook you just created, my website, your email account – every thing is an object.

From our “We are nuts” example yesterday, you can already see these objects:

One awesome owner (that is you)
24 store manager objects
24 store objects

Continue »

Understanding Variables, Conditions & Loops in VBA [Part 2 of 5]

Published on Aug 30, 2011 in VBA Macros
Understanding Variables, Conditions & Loops in VBA [Part 2 of 5]

In part 2 of our VBA Crash Course, we are going to learn what Variables, Conditions & Loops are and how to use them in Excel VBA.

What are Variables, Conditions & Loops?

If you are new to computer programming, you might think I am speaking legalese. So, to make it easy to understand, lets assume you run a bunch of stores across the town. To make it colorful, lets call your stores “We are nuts” – a dry fruit and nuts store chain. At the end of every day, you call each of the 24 store managers and ask them how much sales they have made in that day.

Now, you are not the kind of boss who micro-manages & nitpicks. So you don’t really note down sale for every store. Instead, as you call the store manager, you just mentally update the total. So first store says “$2,300” your total is 2300. Second manger says “$4,000”, the total now will be 6300. So on.

The value 6300 here is nothing but a variable.

We will use the “We are nuts” example thru out this lesson & towards the end we will build a sales logging application using Excel VBA.

Continue »

What is VBA & Writing your First VBA Macro in Excel [VBA Crash Course Part 1 of 5]

Published on Aug 29, 2011 in VBA Macros
What is VBA & Writing your First VBA Macro in Excel [VBA Crash Course Part 1 of 5]

This article is part of our VBA Crash Course. Please read the rest of the articles in this series by clicking below links.

  1. What is VBA & Writing your First VBA Macro in Excel
  2. Understanding Variables, Conditions & Loops in VBA
  3. Using Cells, Ranges & Other Objects in your Macros
  4. Putting it all together – Your First VBA Application using Excel
  5. My Top 10 Tips for Mastering VBA & Excel Macros
Continue »

Split Text on New Line using Excel & VBA [Macros]

Published on Aug 23, 2011 in Excel Howtos, VBA Macros
Split Text on New Line using Excel & VBA [Macros]

Hafiz, One of our avid readers, writes in. My problem is when I convert data from text to column using dash “-“, conversion is easy. but when the gap provided in text is with “alt+enter”, I can’t convert the data.

Well, I tried to use text to columns feature (from Data ribbon) and it would not work.

Although you can use formulas to do the splitting, they might become tedious. So the next logical option is to use macros.

In this article, learn how to use VBA to split text on New Line characters

Continue »

MLB Pitching Stats Dashboard in Excel+VBA by our VBA Class Student

Published on Aug 10, 2011 in VBA Macros
MLB Pitching Stats Dashboard in Excel+VBA by our VBA Class Student

Nothing gives a teacher more satisfaction than seeing a student apply the knowledge to do something awesome. So naturally, I jumped with joy when I got this email from Dan, one of my VBA Class students,

Hi Chandoo,
After going thru your VBA Classes, I realized that we can lots of awesome stuff with pivot tables + simple macros. I recently created an Excel Dashboard to depict MLB (Major League Baseball) Pitching Stats. I could not have done this had I not learned VBA. Thank you so much for teaching the class.

I got curious and requested Dan, if I could share the file with you all. Being a lovely person, Dan agreed immediately.

Continue »

Create PowerPoint Presentations Automatically using VBA

Published on Aug 3, 2011 in Charts and Graphs, Excel Howtos, VBA Macros
Create PowerPoint Presentations Automatically using VBA

You’ve been there before. It’s almost 5:00, and you are going crazy trying to finish the presentation due for a monthly performance meeting the next morning. The model is refreshed, and now it just takes a LOT of copying, pasting, and positioning to get the PowerPoint ready. Finally, the slides are finished…, until you read a new message from your boss requesting a minor change. But of course her change means you have to start all over with the copy and pastes…

There is always a better way! In the Oil and Gas industry, I constantly have monthly reports to assess the performance of our operating assets. Excel VBA makes it a cinch to automate the entire process. So when a simple change is requested, the presentation is automatically generated with the click of a button. No more wasting time!

Continue »

Video Tutorial on Interactive Dashboard using Hyperlinks

Published on Jul 25, 2011 in VBA Macros

Few days ago, we published an article on how to create interactive dashboards using hyperlinks. Many of you loved this tutorial. But quite a few of you also said, this tutorial is a bit complex to follow.

So, I made a short video explaining how the UDF and interactive hyperlinks work and how our dashboard is weaved together.

Continue »

Interactive Dashboard in Excel using Hyperlinks

Published on Jul 20, 2011 in Charts and Graphs, Learn Excel, VBA Macros
Interactive Dashboard in Excel using Hyperlinks

Last week we learned how to create dynamic hyperlinks in Excel. Today, I want to show you something even cooler. An interactive dashboard based on hyperlinks, like shown above.

Isn’t it impressive?

Well, to create something like this, you don’t need a degree in advanced cryogenics. You just need a bunch of data, a chart, a one line macro code and some pixie dust (go easy on pixie dust).

Continue »

Automating Repetitive Tasks

Automating Repetitive Tasks

Over at Newton Excel Bach I spotted the Dynamically Defined Dancing Pendulums. Doug had used Strand7 for the animation.

I thought I could do that in Excel and did.

This post demonstrates some of some basic VBA techniques used to simplify repetitive tasks used during the construction of the project.
For a full project description visit Excel Hero.com.

Continue »

VBA Classes Registration Closing in a Few Hours – Join Now!

Published on May 20, 2011 in Charts and Graphs, VBA Macros
VBA Classes Registration Closing in a Few Hours – Join Now!

I have a quick announcement for you.

Registrations for our VBA Class will be closing in a few hours

As you may know, we have opened registrations for our first batch of Online VBA classes on May 9th. This program is aimed at beginners & intermediate level VBA users. The aim of this course is to make you awesome in VBA. We will be closing registrations for this program in few more hours (exactly at 11:59 PM, Pacific time, on 20th May 2011)

Click here to join our VBA Class now.

Continue »

Count-down Timer App in VBA to Remind you about the VBAClasses Closing Time!!!

Published on May 18, 2011 in products, VBA Macros
Count-down Timer App in VBA to Remind you about the VBAClasses Closing Time!!!

Here is a cool count-down timer application made in VBA to remind you about our VBAClasses registration closing time!
Read the rest of this post to learn how this particular app is built.

If you want to learn VBA, then click here to join our class.

Continue »

Introduction to Programming – Demo Lesson from our VBA Class

Published on May 13, 2011 in VBA Macros

We have a challenge in our VBA class. Many of the students who join our VBA program have no formal programming background. They may have written a few simple programs long time ago, but most of them lack basic understanding of programming. Teaching VBA can be difficult if we do not address this problem.

So, we have added a lesson on “Introduction to Programming”. In this lesson, our aim is to introduce programming to non-programers.

Since many of you are considering to join our VBA classes, it is appropriate that we give this introduction to programming lesson as a demo lesson. Please watch it below.

Continue »

VBA Classes are Open now. Please join today!

Published on May 9, 2011 in products, VBA Macros
VBA Classes are Open now. Please join today!

Dear Readers & Friends,

I am very happy to announce that our first batch of VBA Classes is open for your consideration. Please read this short post to understand the benefits of this program and how you can join. Click here to join our class, if you are ready.

What is this VBA Class?

VBA Class is a structured and comprehensive online training program for learning Microsoft Excel VBA (Macros). It is full of real world examples & useful theory.

The aim of VBA Classes is to make a beginner an expert in VBA.

What are the benefits of this class?

Oh so many! Learning VBA one ups your Excel mojo. You will suddenly start saying “Yes” several work opportunities & challenges. Your boss might fall in love with you. You realize the potential to automate large chunks of your work and save time & money.

Continue »

5 things you should know about VBA Classes + a Demo Lesson

Published on May 6, 2011 in products, VBA Macros

Today, I want to quickly share a few things about the upcoming VBA Classes.

I have been running online training programs since Jan, 2010. I have trained more than 900 students till date. Still, whenever I am launching a new program, I could feel that familiar sense of eagerness, tension and tremendous enthusiasm building up. I feel eager because I want to meet you, teach you and learn from you. I feel tensed because I want to do it right. I feel enthusiastic because these training programs give me a lot of new ideas and open-up new possibilities.

Continue »

Online VBA Classes by Chandoo.org – Details & Dates

Published on May 2, 2011 in products, VBA Macros

Few days ago, I have asked you, Do you want to learn Excel VBA online? and many of you said YES. So we are starting the program, on next Monday – 9th of May.

VBA Classes is a 12 week online training program that will explain various Excel VBA concepts to you in an easy to understand format. Just like Excel School, we will keep this fun, exciting, interactive and useful. We will learn from each other as much as we learn from this course. To help you understand how this course works, we made a small video. You can watch it and get other details about the program in this post.

Continue »