How do I execute a macro based on the value of a cell in Excel?

For example, if cell A1=1, I want to run Macro1 once.  If cell A1=2, I want 
to run Macro2 once.  If cell A1=3, do nothing.

I am familiar with Excel If/Then statements, so to my thinking, it would 
look something like:

IF(A1=1,Run Macro1,IF(A1=2,Run Macro2,""))

I just don't know what the command is to "Run" the macro.
0
brettopp (2)
10/22/2005 10:17:02 PM
excel.misc 78881 articles. 5 followers. Follow

10 Replies
804 Views

Similar Articles

[PageSpeed] 56

others will reply i am sure with code.However you need to decide wether the 
macro runs automatically of a worksheet change event so every time cell a1 is 
changed(or any cell for that matter ) the macro would run.Alternatively you 
could have a button to run the macro or just from the menu tools>macro>run 
macro
-- 
paul
remove nospam for email addy!



"brettopp" wrote:

> For example, if cell A1=1, I want to run Macro1 once.  If cell A1=2, I want 
> to run Macro2 once.  If cell A1=3, do nothing.
> 
> I am familiar with Excel If/Then statements, so to my thinking, it would 
> look something like:
> 
> IF(A1=1,Run Macro1,IF(A1=2,Run Macro2,""))
> 
> I just don't know what the command is to "Run" the macro.
0
10/22/2005 10:35:25 PM
Hi Brettop,

Try:
'===============>>
Private Sub Worksheet_Change(ByVal Target As Range)

    If Not Intersect(Target, Range("A1")) Is Nothing Then
        Select Case Range("A1").Value
        Case 1
            macro1
        Case 2
            macro2
        End Select
    End If

End Sub
'<<===============

This is worksheet event code and should be pasted into the worksheets's code 
module (not a standard module and not the workbook's ThisWorkbook module):

*******************************************
Right-click the worksheet's tab
Select 'View Code' from the menu and paste the code.
Alt-F11 to return to Excel.
*******************************************


---
Regards,
Norman



"brettopp" <brettopp@discussions.microsoft.com> wrote in message 
news:2C91D0BA-4957-4C69-95A4-06599E7AFCCF@microsoft.com...
> For example, if cell A1=1, I want to run Macro1 once.  If cell A1=2, I 
> want
> to run Macro2 once.  If cell A1=3, do nothing.
>
> I am familiar with Excel If/Then statements, so to my thinking, it would
> look something like:
>
> IF(A1=1,Run Macro1,IF(A1=2,Run Macro2,""))
>
> I just don't know what the command is to "Run" the macro. 


0
normanjones (1047)
10/22/2005 10:39:31 PM
You need a worksheet change event macro.  See:

http://www.mvps.org/dmcritchie/excel/event.htm
-- 
Gary''s Student


"brettopp" wrote:

> For example, if cell A1=1, I want to run Macro1 once.  If cell A1=2, I want 
> to run Macro2 once.  If cell A1=3, do nothing.
> 
> I am familiar with Excel If/Then statements, so to my thinking, it would 
> look something like:
> 
> IF(A1=1,Run Macro1,IF(A1=2,Run Macro2,""))
> 
> I just don't know what the command is to "Run" the macro.
0
GarysStudent (1572)
10/22/2005 10:43:02 PM
Thank you, Norman.  This worked perfectly.  It was exactly what I needed!

Brett


"Norman Jones" wrote:

> Hi Brettop,
> 
> Try:
> '===============>>
> Private Sub Worksheet_Change(ByVal Target As Range)
> 
>     If Not Intersect(Target, Range("A1")) Is Nothing Then
>         Select Case Range("A1").Value
>         Case 1
>             macro1
>         Case 2
>             macro2
>         End Select
>     End If
> 
> End Sub
> '<<===============
> 
> This is worksheet event code and should be pasted into the worksheets's code 
> module (not a standard module and not the workbook's ThisWorkbook module):
> 
> *******************************************
> Right-click the worksheet's tab
> Select 'View Code' from the menu and paste the code.
> Alt-F11 to return to Excel.
> *******************************************
> 
> 
> ---
> Regards,
> Norman
> 
> 
> 
> "brettopp" <brettopp@discussions.microsoft.com> wrote in message 
> news:2C91D0BA-4957-4C69-95A4-06599E7AFCCF@microsoft.com...
> > For example, if cell A1=1, I want to run Macro1 once.  If cell A1=2, I 
> > want
> > to run Macro2 once.  If cell A1=3, do nothing.
> >
> > I am familiar with Excel If/Then statements, so to my thinking, it would
> > look something like:
> >
> > IF(A1=1,Run Macro1,IF(A1=2,Run Macro2,""))
> >
> > I just don't know what the command is to "Run" the macro. 
> 
> 
> 
0
brettopp (2)
10/22/2005 11:05:02 PM
brettopp Wrote:
> Thank you, Norman.  This worked perfectly.  It was exactly what 
> needed!
> 
> Brett
> 
> 
> "Norman Jones" wrote:
> 
> > Hi Brettop,
> >
> > Try:
> > '===============>>
> > Private Sub Worksheet_Change(ByVal Target As Range)
> >
> >     If Not Intersect(Target, Range("A1")) Is Nothing Then
> >         Select Case Range("A1").Value
> >         Case 1
> >             macro1
> >         Case 2
> >             macro2
> >         End Select
> >     End If
> >
> > End Sub
> > '<<===============
> >
> > This is worksheet event code and should be pasted into th
> worksheets's code
> > module (not a standard module and not the workbook's ThisWorkboo
> module):
> >
> > *******************************************
> > Right-click the worksheet's tab
> > Select 'View Code' from the menu and paste the code.
> > Alt-F11 to return to Excel.
> > *******************************************
> >
> >
> > ---
> > Regards,
> > Norman
> >
> >
> >
> > "brettopp" <brettopp@discussions.microsoft.com> wrote in message
> > news:2C91D0BA-4957-4C69-95A4-06599E7AFCCF@microsoft.com...
> > > For example, if cell A1=1, I want to run Macro1 once.  If cel
> A1=2, I
> > > want
> > > to run Macro2 once.  If cell A1=3, do nothing.
> > >
> > > I am familiar with Excel If/Then statements, so to my thinking, i
> would
> > > look something like:
> > >
> > > IF(A1=1,Run Macro1,IF(A1=2,Run Macro2,""))
> > >
> > > I just don't know what the command is to "Run" the macro.
> >
> >
> >


I have a spreadsheet that I use an image to run a macro. If I were t
use the above script to run my macros, how do I do this. Where doe
this script go?
My choices for input would "A" - "B" or "C".

Than

--
Ltat42
-----------------------------------------------------------------------
Ltat42a's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=2473
View this thread: http://www.excelforum.com/showthread.php?threadid=47850

0
10/23/2005 1:00:34 AM
Hi Ltat42a,

> I have a spreadsheet that I use an image to run a macro. If I were to
> use the above script to run my macros, how do I do this. Where does
> this script go?
> My choices for input would "A" - "B" or "C".

Paste the following code into a standard module - not a worksheet module or 
the ThisWorkbook module:

'===========>>
Sub aTester()
        Select Case Range("A1").Value ' <<===== CHANGE
        Case "A"
            Macro1        '<<===== CHANGE
        Case "B"
            Macro2        '<<===== CHANGE
         Case "C"
            Macro3        '<<===== CHANGE
        End Select
End Sub
'===========>>

Assign this macro to the image.

---
Regards,
Norman 


0
normanjones (1047)
10/23/2005 2:36:57 AM
Norman Jones Wrote: 
> Hi Ltat42a,
> 
> > I have a spreadsheet that I use an image to run a macro. If I were
> to
> > use the above script to run my macros, how do I do this. Where does
> > this script go?
> > My choices for input would "A" - "B" or "C".
> 
> Paste the following code into a standard module - not a worksheet
> module or
> the ThisWorkbook module:
> 
> '===========>>
> Sub aTester()
> Select Case Range("A1").Value ' <<===== CHANGE
> Case "A"
> Macro1        '<<===== CHANGE
> Case "B"
> Macro2        '<<===== CHANGE
> Case "C"
> Macro3        '<<===== CHANGE
> End Select
> End Sub
> '===========>>
> 
> Assign this macro to the image.
> 
> ---
> Regards,
> Norman


Oooppps. I should have explained better. I want to get rid of the
images I use to run the macros. When a user inserts an "A" into a
particular cell, it will run the "A" macro that I created, when someone
enters "B", it runs the "B" macro...etc...etc...


Sorry...


-- 
Ltat42a
------------------------------------------------------------------------
Ltat42a's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=24735
View this thread: http://www.excelforum.com/showthread.php?threadid=478509

0
10/23/2005 6:56:36 PM
Hi Ltat42a,

> Oooppps. I should have explained better. I want to get rid of the
> images I use to run the macros. When a user inserts an "A" into a
> particular cell, it will run the "A" macro that I created, when someone
> enters "B", it runs the "B" macro...etc...etc...
>

In that case, try:
'===============>>
Private Sub Worksheet_Change(ByVal Target As Range)

    If Not Intersect(Target, Range("A1")) Is Nothing Then
        Select Case Range("A1").Value    '<<=== CHANGE
        Case "A"
            Macro1
        Case "B"
            Macro2
        Case "C"
            Macro3
        End Select
    End If

End Sub
'<<===============

This is worksheet event code and should be pasted into the worksheets's code 
module (not a standard module and not the workbook's ThisWorkbook module):

*******************************************
Right-click the worksheet's tab
Select 'View Code' from the menu and paste the code.
Alt-F11 to return to Excel.
*******************************************


Change A1 to the cell of interest.

---
Regards,
Norman


"Ltat42a" <Ltat42a.1xdcqe_1130094303.1578@excelforum-nospam.com> wrote in 
message news:Ltat42a.1xdcqe_1130094303.1578@excelforum-nospam.com...
>
> Norman Jones Wrote:
>> Hi Ltat42a,
>>
>> > I have a spreadsheet that I use an image to run a macro. If I were
>> to
>> > use the above script to run my macros, how do I do this. Where does
>> > this script go?
>> > My choices for input would "A" - "B" or "C".
>>
>> Paste the following code into a standard module - not a worksheet
>> module or
>> the ThisWorkbook module:
>>
>> '===========>>
>> Sub aTester()
>> Select Case Range("A1").Value ' <<===== CHANGE
>> Case "A"
>> Macro1        '<<===== CHANGE
>> Case "B"
>> Macro2        '<<===== CHANGE
>> Case "C"
>> Macro3        '<<===== CHANGE
>> End Select
>> End Sub
>> '===========>>
>>
>> Assign this macro to the image.
>>
>> ---
>> Regards,
>> Norman
>
>
> Oooppps. I should have explained better. I want to get rid of the
> images I use to run the macros. When a user inserts an "A" into a
> particular cell, it will run the "A" macro that I created, when someone
> enters "B", it runs the "B" macro...etc...etc...
>
>
> Sorry...
>
>
> -- 
> Ltat42a
> ------------------------------------------------------------------------
> Ltat42a's Profile: 
> http://www.excelforum.com/member.php?action=getinfo&userid=24735
> View this thread: http://www.excelforum.com/showthread.php?threadid=478509
> 


0
normanjones (1047)
10/23/2005 7:47:59 PM
Hi Ltat42a,

To avoid posible confusion

> Change A1 to the cell of interest.

was intended to refer to both of the lines:

>    If Not Intersect(Target, Range("A1")) Is Nothing Then
>        Select Case Range("A1").Value    '<<=== CHANGE

---
Regards,
Norman



"Norman Jones" <normanjones@whereforartthou.com> wrote in message 
news:uf2YvqA2FHA.3256@TK2MSFTNGP09.phx.gbl...
> Hi Ltat42a,
>
>> Oooppps. I should have explained better. I want to get rid of the
>> images I use to run the macros. When a user inserts an "A" into a
>> particular cell, it will run the "A" macro that I created, when someone
>> enters "B", it runs the "B" macro...etc...etc...
>>
>
> In that case, try:
> '===============>>
> Private Sub Worksheet_Change(ByVal Target As Range)
>
>    If Not Intersect(Target, Range("A1")) Is Nothing Then
>        Select Case Range("A1").Value    '<<=== CHANGE
>        Case "A"
>            Macro1
>        Case "B"
>            Macro2
>        Case "C"
>            Macro3
>        End Select
>    End If
>
> End Sub
> '<<===============
>
> This is worksheet event code and should be pasted into the worksheets's 
> code module (not a standard module and not the workbook's ThisWorkbook 
> module):
>
> *******************************************
> Right-click the worksheet's tab
> Select 'View Code' from the menu and paste the code.
> Alt-F11 to return to Excel.
> *******************************************
>
>
> Change A1 to the cell of interest.
>
> ---
> Regards,
> Norman


0
normanjones (1047)
10/23/2005 7:57:20 PM
To all who posted - this works much much better than clicking on a
image to execute a macro. Works great!

Thank you!!!


J

--
Ltat42
-----------------------------------------------------------------------
Ltat42a's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=2473
View this thread: http://www.excelforum.com/showthread.php?threadid=47850

0
10/23/2005 9:37:05 PM
Reply:

Similar Artilces:

Enable Macros
When I try to compile a macro I get the following message: "The macros in this project are disabled. Please refer to the online help or documentation of the host application to determine how to enable macros." Can someone tell me how to enable my macros. I have already gone to tools/macros/security. You must shut down and restart Outl9ook after you change the macro security level. -- Sue Mosher, Outlook MVP Author of Microsoft Outlook Programming - Jumpstart for Administrators, Power Users, and Developers http://www.outlookcode.com/jumpstart.aspx "ell...

Advanced Find Export to Excel
We have an Advanced Find that was created that has more than 10,000 records being returned. When we try to export the find into an excel spreadsheet, only 10,000 of the records appear even though we chose to export the results on all pages. Is this a limitation of CRM 3.0? If I do a count on the records in sql, there should be 17,161. Any information regarding this would be much appreciated. Thanks!! Hi JC, this is a standard limit. You can change this by editing the registry Keys. Take a look at http://blogs.msdn.com/crm/archive/2006/11/07/crm-registry-settings.aspx There you&...

Macro sur les retrait excel
Bonjour =E0 tous, J=92ai un petit probl=E8me sur excel. J=92ai en effet un fichier avec des donn=E9es dans des cellules avec des retraits. Je voudrais tout simplement utiliser une macro afin de r=E9cup=E9rer dans une colonne B les valeurs de ces retraits des cellules d'une colonne A. Je sais que le champ utilis=E9 pour le retrait est =AB indentlevel =BB. J=92ai trouv=E9 l=92aide suivante sur le site de microsoft , mais je ne sai= s pas l=92utiliser . http://msdn.microsoft.com/fr-fr/library/microsoft.office.tools.excel.namedr= ange.indentlevel(VS.80).aspx --------------------------------...

excel conditional formatting default
have a need to use multiple conditional formats (three is the max in excel) but the arguements total five. 1,2,3,4,L. The problem is the conditional formating is set on 1,2,3; but when 4 & L are used it defaults to condition 2. If it defaulted to condition used for 3 - all would be okay, but why condition 2? I have removed condition 3 and if I set the arguement to 3 no conditional formating is applied. If I set the arguement to 4 or L then the formating for 2 is applied. For 3,4 & L I want the same formating applied. Any ideas -- jhkarr make the third condition "great...

Microsoft Query and Excel
I create an Excel spreadsheet getting data from a SQL 2000 Server. Is it possible for me to send to our consultant to check the tables and fields selected ? He concerns about the Data Source problem. This is because our servers are of different name OR just the name of DSN is concerned. Thanks I am using Excel 97. Thanks >-----Original Message----- >I create an Excel spreadsheet getting data from a SQL 2000 >Server. > >Is it possible for me to send to our consultant to check >the tables and fields selected ? He concerns about the >Data Source problem. ...

Macro SOP
Hi All, I recorded a macro in SOP using GP 9 and trying to edit it with microsoft word, How can I achieve to have it insert multiple item rows in a single SOP Number? Please help Thanks, Daniel ------=_NextPart_0001_841F15F6 Content-Type: text/plain Content-Transfer-Encoding: 7bit Hi Daniel You will need to record entering more than one line to see how the code behaves. As a macro must have the correct number of lines to match the data, you might have to write some conditional code on the Word document using the IF field so you can make a section appear or disappear based on the lines...

excel help error
I have an end user who when he opens excel and then goes to help and for example types in the word "left" and then on the pane it says "see also" when he clicks on that link he gets an INternet Explorer Script error. Any thoughts ...

Paste Value Macro
Here's a macro that works fine for me. It converts a formula in the cell where the cursor is to a value, or formulas in selected cells to values: Sub ConvertToValue() ' ' Keyboard Shortcut: Ctrl+Shift+D ' Selection.Copy Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _ :=False, Transpose:=False Application.CutCopyMode = False End Sub What I want is a macro that, after I copy a selection to the clipboard, will allow me to PasteSpecial>ValuesOnly to the new location. I tried: Selection.PasteSpecial Paste:=xlPasteV...

forecast a financial value at year end
Cell J3 displays the total values listed in all columns on the sheet. When another value is added to any column, J3 reflects this. Now, to manually predict what J3 will say at year end (Dec 31st) ie an estimate, I can simply divide J3 by the number of days passed (since Jan 1st) and multiply by 365. This will be close enough for my purposes. How can I put this into a formula? Thanks -- Traa Dy Liooar Jock =J3/(TODAY()-"01/01/2009")*365 "Jock" wrote: > Cell J3 displays the total values listed in all columns on the sheet. When > another value...

Program stops executing
I have an instance such that any VB program will not work on a certain PC. It used to, but now the VBNET2005 generated executable will now not execute. I have tried creating a simple project with just a form on it with Hello World in a textbox and even that will not execute in runtime. There is no question of the framework not being installed because it comes standard in the Windows XP SP2 and I have SP3 installed on the PC. I have uninstalled and reinstalled the DotNet framework and this has NOT resolved the issue. Can anyone please shed some light on this matter for me a...

How do I display shading of cells on the Web in Excel?
I would like to distinguish adjacent cells from each other using patterns or something other than color. Color works well for the display on the web page, but when the document is printed on black and white printers the color is lost. one way is to use conditional formating and borders such as formula is =(mod(row(),2)=1)*(mod(column(),2)=1) border all around for format may do what you want "Shading cells for the web" wrote: > I would like to distinguish adjacent cells from each other using patterns or > something other than color. Color works well for the display on th...

delete row if 2 cells are empty
Hello I get a daily report and I have to delete the entire row if cell AA and Cell AB are empty. staring from row 4 till the end. I have been doing this manually but is there a VBA code that would make this faster. thanks in advance Unless aa a/o bb populated with a space bar this should do it. Sub delrowsifaaempty() lr = Cells.find(What:="*", After:=[A1], _ SearchDirection:=xlPrevious).Row For i = lr To 4 Step -1 If Cells(i, "aa") = "" And Cells(i, "ab") = "" Then Rows(i).Delete Next i End Sub -- Don Guillett ...

Editing Excel sheet on the web?
When posting an excel file on the web, users are able to open and edit fields directly in Internet Explorer. 1. Can users edit the sheet even if they do not have Excel installed on their machine? Is there anyway to do this? Thanks. "MikeJ" <mico12@yahoo.com> wrote in news:OlKzHry5DHA.2540 @TK2MSFTNGP11.phx.gbl: > 1. Can users edit the sheet even if they do not have Excel installed on > their machine? Is there anyway to do this? A few ways -- they can download the Excel Viewer from Microsoft, or you can use a commercial product for converting an excel file to a web...

DoEvents and Execution
I'm using AC2003. I have FormA which has two subform controls on it which do not have a SourceObject assigned to them. I do that in the form_open event, see below. What I'm trying to do is to open a simple OneMomentPlease form that has several colored labels used to indicate progress. As I understand it, a DoEvents statement should force all statements prior to it to execute before any following statements to execute. However, it's not working that way. When FormA is opened it runs through all statements. Each sourceobject contains a fairly complex chart and ta...

Change Text Case to Upper in a cell range A2:A92
I have a workbook of Contacts. In column A there are Names. I wish to convert those to UPPER case. I've seen a few VB codes that change the case to UPPER if I change something in the cell, GREAT if I want to go through the entire Column and change something. But is there another way? "Barry" wrote: > I have a workbook of Contacts. In column A there are Names. I wish to > convert those to UPPER case. I've seen a few VB codes that change the case > to UPPER if I change something in the cell, GREAT if I want to go through > the entire Column and change s...

In excel how do i put zero as the first Number in a cell
how could i add zeros as the first number in a cell without a decimal Hi Two ways: Start your entry with an ', to read '083, or Format the cells where you want to insert this as text, and then enter the number "help" wrote: > how could i add zeros as the first number in a cell without a decimal > Either format the cell for TEXT (Right-click > FormatCells > NumberTab > Text > ok), or if you only have a few, just type a leading apostrophe before the leading zero.........it won't show up and will change that cell to TEXT format.......... Vaya con ...

Using Macros to remove a name from a list
I own a small business with roughly 45 employees (mostly teenagers). There's lots of turnover. I've got a spreadsheet that I use to track tips according to the role and shift that our staff works. My manager has the ability to select the staff member who earned the tip from an in-cell drop down list (using DV). Here's my question. I want to make it really easy for my managers to add or delete staff members from the drop down list. I've created a separate worksheet with two sections: "add staff member" and "delete staff member". When they want to...

Sum value between dates problem driving me mad!
Good Evening All, I am really struggling here, have tried, nested IF's including AND's but am a bit stumped. I am fairly familiar with Arrays, but cannot seem to combine all. I have a data table (as detailed below). (Hopefully, this should be 'pastable' into Excel - it works for me) I simply wish to calculate the expected totals per month. Any help & assistance with this would be most welcome. Cheers, Mathew Note, earliest Start is 01/04/03 Start Finish Day Rate Apr-2003 May-2003 Jun-2003 Jul-2003 Aug-2003 01/04/2003 23.00 01/04/2003 09/07/2003 23.00 ...

Excel Converson
I received a template by email. The template is in Excel 2007. My Excel is 2003. Everytime I enter data in a cell the convverson process takes place. How do you stop the converson process? RFB wrote: > I received a template by email. The template is in Excel 2007. My Excel is > 2003. Everytime I enter data in a cell the convverson process takes place. > How do you stop the converson process? Does the conversion still leave you with a usable template? If not, you have two choices: Ask the provider to send you an Excel 2003 template. Upgrade to Excel 2007. ...

Execute As
Greetings. I have 2 Databases with 2 different sets of users, and thus 2 different sets of permissions. Certain actions on Database A fires a trigger that executes a stored procedure on database B. If the user in Database A doesn't have permission on Database B, then the procedure fails, and the User gets an error. I have been experimenting with the EXECUTE AS function, but it doesn't seem to work as I had expected. Can anyone give me some tips or point me in the direction of some holiday reading material? Thanks in advance. Matthew Vandermolen Solutions Architecht Worktec...

Value Metadata
Hi How can I check (using VBA) if a cell has some metadata associated (as described here: http://msdn.microsoft.com/en-us/library/dd953161.aspx). I ask because I have an xlsx file with data that when opened in Excel 2007 shows values only. But when I save the same file in xls format and open it in Excel 2003 it displays value in the cell but in formula box Excel shows _xlfn.COMPOUNDVALUE(20) for instance. Thanks IgorM Curious! "2.2.4 Metadata Metadata is additional data associated with a particular cell or its content. Metadata is recorded in BIFF8 for future ex...

Macro for inserting a files selected from a directory (on a networ
I'm looking for a macro that I could add to .dotm so that I can insert selected files into my main document: From the document > click on a toolbar icon > open the correct specific folder to display the list of files in that folder > Select a file to insert it into my main document. The reason for going this way is to let people change the word files but keep them out of playing with Quick Parts/Autoext in the template itself as files might change and the list of files int eh folder might be added to. I had one I found on this community which worked on my home P...

How bring a color on cell from one sheet to another #2
I have a summary sheet and I can do the numbers, but how can I bring the color on cell? Lets say, I have on sheet3 a cell with number one and color green; on summary sheet I have a corresponding cell and I want not only th number 1 to show up, but also the color green. Other numbers are 2 for yellow and 3 for red. Can i ONLY WRITE THE NUMBER AND GET THE COLOR AUTOMATICALLY ON SHEET3?? ...

Mem Usage increase while while executing dialog box
Dear All, Hope I have posted to the correct topic area. Need some help here. 1. I have created a simple dialog box using Visual Studio C++ 6.0, the dialog box contains an multiline read-only Edit Box, a Start Button and a Stop Button. 2. When the Start Button is clicked, the program will execute and the Edit Box will just print out the following text - "Line XX", where XX is the number 3. Problem is that when the program is executed and using Windows Task Manager to monitor the process, there is a high usage of Memory (ranges from 3636K to as high as 40000K). 4. Question ...

Dynamic cell references in cube functions
What is the syntax to make for instance the cubevalue function pick up parameter values from the spreadsheet so my report becomes dynamic? I have the following statement: =CUBEVALUE("datasource";"[Measures].[Volume]";"[Time].[YM].[YM].[2007].[200710]") I want to make a dynamic report so that the year [2007] and the month [200710] changes according to dates I put into the spreadsheet (for instance today()) so the report automatically updates the query to current time periode. Thanks in advance! I don't know cubevalue and it isn't in Excel help on ...