2014年3月17日星期一

Excel VBA for select/paste data and create new Worksheet

Due to the large amount of data (~40,000 points in a 40 seconds measurement) obtained from experiment each time. It is essential to develop programs for selecting useful data for further analysis like plotting and calculation.

Excel VBA is used to achieve the requirements. Two programs were written, one is to copy different ranges of data in origin Worksheet and paste them to new Worksheets. The other program copies other ranges of data and paste them to the second columns of newly created Worksheets.

Excel VBA codes are shown below:

Figure 1 copy, create new sheet and paste


Figure 2 copy and paste to existing sheets


Source codes (.bas files) for two modules, click here to download.