| | |
passing array between Excel '03 and VB '08
Please support our VB.NET advertiser: Intel Parallel Studio Home
![]() |
•
•
Join Date: Jan 2008
Posts: 56
Reputation:
Solved Threads: 0
I'm trying to write a program in VB2008 that uses a 2003 Excel spreadsheet as the interface. To help with this I am trying to pass data to and from macros inside the spreadsheet. I call a macro from VB with this line:
where gArr is an array and ArrGather is a macro. Problem is even though I've specified the macro to take gArr as ByRef, the array is always passed byvalue - no updates to the array are reflected afterwards. Any ideas why Visual Basic 2008 can't pass variables by reference to excel 03 macros?
VB.NET Syntax (Toggle Plain Text)
Call gXLApp.Run(gwbTB.Name & "!ArrGather", gArr)
where gArr is an array and ArrGather is a macro. Problem is even though I've specified the macro to take gArr as ByRef, the array is always passed byvalue - no updates to the array are reflected afterwards. Any ideas why Visual Basic 2008 can't pass variables by reference to excel 03 macros?
![]() |
Similar Threads
- Visual basic macro in Excel. (Visual Basic 4 / 5 / 6)
- Query On Passing a datarow array as an argument (VB.NET)
Other Threads in the VB.NET Forum
- Previous Thread: sl.no in crystal report
- Next Thread: how to modify an exe without preparing a setup afresh
| Thread Tools | Search this Thread |
.net .net2008 2008 access add advanced application array basic beginner browser button buttons center click code combo cpu cuesent data database datagrid datagridview date datetimepicker designer dissertation dissertations dissertationtopic employees excel exists fade filter forms generatetags html images input intel internet listview map mobile module monitor msaccess mysql net number objects open pan panel pdf picturebox picturebox2 port position print printing printpreview problem regex reuse right-to-left save search searchvb.net serial settings shutdown socket sqldatbase sqlserver storedprocedure survey temperature textbox timer timespan transparency txttoxmlconverter user usercontol vb vb.net vba vbnet vista visual visualbasic visualbasic.net visualstudio.net web winforms wpf wrapingcode xml year





