|
| |||||||||
| Tags: arrays, excel, macros, microsoft excel, ms office, visual basic |
![]() |
| | Thread Tools | Search this Thread |
|
#1
| ||||
| ||||
| Sample of Visual Basic macros for working with arrays in Excel
Hello friends, I have done some basic coding in Visual Basic Application in Excel. I am working with the macros that are used in an arrays. I have tried a lot of coding for that but I am getting an error everytime. I think that I am going wrong somewhere, so thought to ask you guys for the help. Can someone over there can provide me the sample of Visual Basic macros for working with arrays in Excel.?? Any other information related to the topic would be grateful.!! ![]()
__________________ ~*~Silent~Kid~*~ "To The World You May Be Just One Person, But To One Person You May Be The World" |
|
#2
| ||||
| ||||
| Re: Sample of Visual Basic macros for working with arrays in Excel
I think that you should first know about the macros properly to understand the coding of it in VB. A macro can automate repetitive tasks. Two different methods are used for creating Excel macros :
|
|
#3
| ||||
| ||||
| Re: Sample of Visual Basic macros for working with arrays in Excel
Visual Basic for Applications (VBA) is a programming environment that supports and automates most desktop applications from Microsoft. Excel often refuses to execute the VBA program (it also called macros or macros). When opening a workbook containing the code. For filling an array and copying it into a spreadsheet, follow the steps :
|
|
#4
| ||||
| ||||
| Re: Sample of Visual Basic macros for working with arrays in Excel
If you want to retrieve values from the spreadsheet and fill the array, follow the steps mentioned below :
|
|
#5
| |||
| |||
| Re: Sample of Visual Basic macros for working with arrays in Excel
I am providing the code that you have to insert into the example provided by the 'chroma', Code: Sub From_sheet_make_array ()
Dim myarray As Variant
myarray = Range ( "a1: a10"). Value
'Looping structure to look at array.
For i = 1 To UBound (myarray)
MsgBox myarray (i, 1)
Next
End Sub |
|
#6
| ||||
| ||||
| Re: Sample of Visual Basic macros for working with arrays in Excel
For passing and receiving an array in excel, follow the steps given below :
__________________ QTechnology Ultra-Quiet ATX PSU 460W I MSI K8N Neo4-F I AMD Opteron 144 CABNE0545 2.66Ghz I 2 x 512MB RAM I 380GB Maxtor SATAI Raid0 Hard Drive I 40GB Maxtor IDE Hard Drive I Nvidia GeForce 7900GTX I Win XP Home Service Pack 2 I Soundblaster Xtreme Fidelity Fatal1ty I Mercury Home Theater HT-4500 |
![]() |
|
| Thread Tools | Search this Thread |
| |
Similar Threads for: "Sample of Visual Basic macros for working with arrays in Excel" | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Looking for Excel Web Query for Java Applet working sample | Omswaroop | MS Office Support | 3 | 2 Weeks Ago 08:12 PM |
| Excel not working properly to open macros | Kungfu Pandey | Windows Software | 1 | 06-01-2012 10:03 PM |
| Arrays in Visual Basic 6.0 | Palnila | Software Development | 3 | 26-12-2010 09:17 AM |
| Working with excel macros on a mac system | Sheridan^OS | Windows Software | 5 | 13-12-2010 10:20 PM |
| How to use the Arrays in Visual Basic? | The Recruiter | Software Development | 4 | 21-01-2010 08:13 PM |