borderAndreaVB free resources for Visual Basic developersborder

borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2007 Andrea Tincaniborder

AndreaVB | Forum | News | Downloads | Register | Help | Member List | Statistics | Search | PM | Profile

Print This Topic
Previous Topic (file names)Next Topic (Data Control & Bookmarks (DAO)) New Topic New Poll Post Reply
AndreaVB Forum : VB General : Macro's in excel.. Help needed
Poster Message
Niels
Level: Trainee

Registered: 17-04-2006

icon Macro's in excel.. Help needed  Archived to Disk

Hi

I hope someone can help me with the following problem - and that I can describe it so you can understand it:

When using the matrix reference style (R1C1 reference style) in Excel - is it then posible to use input data in this reference ?

For exampel - In a certain cell-equation I want to "point" to cell RxC5 but need to change the values of x so I dont want the numbers in the code/formulas..
So I put the value of x in cell R1C1. Now I need excel to "read" this value.. In my mind this would look something like this:
R(R1C1)C5

This obviously does not work so I thought I could use some sort of Macro/program to do this.

I am not a visual expert so if the solution for my problem is very complicated let me know - and I'll do the whole thing in Matlab
But if there is a fairly simple solution (or if someone knows how to do this with simple excel equations) I would be a very happy person if you could help me

Best regards
Niels Kau Andersen

24-05-2002 at 01:19 PM
View Profile Send Email to User Show All Posts | Quote Reply
yronium
Level: Moderator


Registered: 14-04-2002
Posts: 907
icon Re: Macro's in excel.. Help needed  Archived to Disk

well, I think there's no need to use a macro, as the Excel's Paste function window (it appears by clicking on the f(x) button in the Standard toolbar, or in the Insert/Function menu) includes the ROW.REF() function. I'm not sure of the exact name of this function, because I'm translating the name from my italian version of Excel. However you can find it in the Search and Reference cathegory.

It provides the number of the row of a specified reference, regardless on the matrix reference style (R1C1 or A1). You can include this function into your equations and formulas.

Anyway in VBA is avaliable the Range() function, that points at a specified address or cell. Watch the online help to get more infos.

Hope it helps.
Ciao.

____________________________
Real Programmer can count up to 1024 on his fingers

28-05-2002 at 11:26 AM
View Profile Send Email to User Show All Posts | Quote Reply
AndreaVB Forum : VB General : Macro's in excel.. Help needed
Previous Topic (file names)Next Topic (Data Control & Bookmarks (DAO)) New Topic New Poll Post Reply
Surf To:


Not Logged In? Username: Password: Lost your password?
Partners: Download Actual Software | Free Software Download
borderAndreaVB free resources for Visual Basic developersborder

borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2007 Andrea Tincaniborder