converting formula values into just numbers?

I need to manipulate with a macro, as absolute numbers, the numerical values
returned from a formula. Instead of say.....1,3,5,8, etc. the macro sees the
corresponding formula when referred to these cells and can't work with it.
How can I return just straight numbers from the formula calculations?

Thanks


0
dnunley (3)
1/3/2004 11:06:56 PM
excel 39879 articles. 2 followers. Follow

1 Replies
507 Views

Similar Articles

[PageSpeed] 1

One way:

    Dim myValue As Double
    myValue = Range("A1").Value


In article <OPPdt4k0DHA.2396@TK2MSFTNGP09.phx.gbl>,
 "DNunley" <dnunley@earthlink.net> wrote:

> I need to manipulate with a macro, as absolute numbers, the numerical values
> returned from a formula. Instead of say.....1,3,5,8, etc. the macro sees the
> corresponding formula when referred to these cells and can't work with it.
> How can I return just straight numbers from the formula calculations?
> 
> Thanks
> 
>
0
jemcgimpsey (6723)
1/3/2004 11:23:14 PM
Reply:

Similar Artilces:

help create a formula using the IF command with AND
I need to create a formula for below: IF A2 is greater than A1 AND A4>A3 then A4 should be multiplied by .04, if not then A4 should be multiplied by .03. Can someone turn that into a formula for me? I'm sorry I should clarify the "if not", if A2 is not greater than A1. =if(and(a2>a1,a4>a3),a4*.04,a4*.03) or =a4*(if(and(a2>a1,a4>a3),.04,.03)) or =a4*(.03+.01*(and(a2>a1,a4>a3))) They'll all evaluate the same, so you can use the one that is easiest to understand. joe54345@gmail.com wrote: > > I need to create a formula for below: > >...

Formula Modification
Folks: (IF(ISERROR(MATCH(B1,A:A,0)),"No Match","Match") Column A Column B Column C 25 50 No Match 30 30 Match 26 28 No Match 55 60 I am using the above formula to compare two columns (A and B) for overlapping (common) data then put the result ("Match" OR "No Match") in a third column. So far this formula has work...

Return range of cell values based on current date
I have a spreadsheet containing daily sales data for the month. I want today's sales data to display on a different worksheet to save the hassle of someone scanning through an entire month of data. Is this possible and what function do I use to achieve this? Thanks, Wing WHY NOT ADD A WORKBOOK? Providing a workbook will not only get you your answer quicker but will better illustrate your problem, usually when we can see your data (-it can be dummy data but must be of the same type-) and your structure it is far easier for us to give you a tailored, workable answer to ...

problem reading value from another Form
In frmMain I added a public property which returns a label contained in frmMain: public Label LblCD { get { return lblCurDir; } } I open the 2nd form, frm2, by clicking on a button on frmMain, and in frm2 I have this code: frmMain fMain; private string GetLblText() { return fMain.LblCD.Text; } the error I get when I try to invoke this proc on frm2 is: "Object reference not set to an instance of an object." I was thinking of trying frmMain fMain = new frmMain(); but I then I would not be able to read the current text contained in...

How do I change a symbol to a numeric value ie: N to 5
I'm trying to change symbols to numberic values & not finding any answers. Tools>Autocorrect for an unwieldy method. VLOOKUP table method. VBA event code method. Gord Dibben MS Excel MVP On Wed, 26 Apr 2006 08:57:01 -0700, 7vYkCtVN <7vYkCtVN@discussions.microsoft.com> wrote: >I'm trying to change symbols to numberic values & not finding any answers. ...

How to round values to the nearest 1000?
How to round values to the nearest 1000? Like: 12,549,235 > 12,549,000 Like: 12,549,735 > 12,550,000 According to Help I should use =ROUND(P9,3-LEN(INT(P9))) but the result is not what I want. Bart Excell 2003 Hi! Try this: =ROUND(A1/1000,0)*1000 Biff "AA Arens" <bartvandongen@gmail.com> wrote in message news:1152850880.524553.173510@75g2000cwc.googlegroups.com... > How to round values to the nearest 1000? > > Like: 12,549,235 > 12,549,000 > Like: 12,549,735 > 12,550,000 > > According to Help I should use =ROUND(P9,3-LEN(INT(P9))) but the...

If select ALL then show me all values?
Hi, i have a table suptblLevel with the following values: autLevelID txtLevel 1 ALL 2 OPS 3 CON 4 LEAD Then i have a form frmEmailScheduleToClientMenu where i have an unbound combo box looking up above. I select one of the values above and then have a cmdPreview button opening qryTrainingDateForClientsWithCriteria showing the results. I basically want, if i click ALL, to select OPS, CON and LEAD (Its not an actual value in my query - How do i do that?) the field in the query would be n...

How do I convert the format? (Please see msg for details)
I have once sheet with more than 500 blocks of data in this format: --------------------------------------|-----------------|-------------- comapny1 --------------------------------------|-----------------|-------------- Website: web1 --------------------------------------|-----------------|-------------- Location: loca1 --------------------------------------|-----------------|-------------- How can I convert them to a arranged format like this: --------------------------------------|-----------------|-------------- COMPANY | WEBSITE | LOCATION ------...

pls tell me how to convert UTF-8 to ASCII? thanks :)
Try: int WideCharToMultiByte( UINT CodePage, // code page DWORD dwFlags, // performance and mapping flags LPCWSTR lpWideCharStr, // wide-character string int cchWideChar, // number of chars in string. LPSTR lpMultiByteStr, // buffer for new string int cbMultiByte, // size of buffer LPCSTR lpDefaultChar, // default for unmappable chars LPBOOL lpUsedDefaultChar // set when default char used ); For CodePage use CP_UTF8. joe On Wed, 28 Jul 2004 09:53:45 GMT, Andy Tang <Andy_Tang2k@hotmail.nospam.com> wrote: ...

Return value based on 2 items
please help am not very good at explaining things but this is my sample list 05 p5 Q5 Customer Description Cost Tom Plow 1-6 $50.00 Tom Plow 6.1-12 $100.00 Tom Plow 12 .1-18 $150.00 Tom Plow 18.1-24 $200.00 Tom Salt $25.00 Tom Shovel 1-6 $25.00 Tom ...

Formulas with percentages
maybe someone can help me with this..if someone increases an amount by %25 then they get a point, if they increase it by %50 they get 2 points, by %75, 3 points, and %100, 4 points.... can you figure that one out for me please? how would i a formula that would read this? -- Message posted via OfficeKB.com http://www.officekb.com/Uwe/Forums.aspx/ms-excel/200508/1 Hi, Lets say the original amount is in A2 and the increased amount is in A3 , then use =ROUND((((A3-A2)*100)/A2)/25,0) Regards Govind. Trisha V via OfficeKB.com wrote: > maybe someone can help me with this..if someone ...

Find the 10% value
Hi, I have a monthly report that contains data for a varying amount (each month) of users across several column. For each column I need to use conditional formatting to highlight the worst 10% for each measure. Currently I'm doing this manually by sorting the column ascending, then if there are 15000 users, look at the value corrensponding to line 1500, enter this in a cell which I then reference in my conditional format. What the best way to do this by formula? -- Rich http://www.rhodes-lindos.co.uk On Thu, 4 Mar 2010 20:41:46 -0000, "Rich" <REP...

Flag row if cell values = something specific
Let's say A1 = top and B1 = Bottom in C1, I want to say that if A1 = top and B1 = bottom then the cell background color of C1 should be red. How can I do this? And I need to do this in a macro. I can't use conditional formating from the menu. I have a recorded macro that does all my formatting and I need to add this. "Some Dude" <sdatt@myplace.com> wrote in message news:e9kw7DrfGHA.4864@TK2MSFTNGP05.phx.gbl... > Let's say A1 = top > and B1 = Bottom > > in C1, I want to say that if A1 = top and B1 = bottom then the cell > background color of...

How do I stop chart from plotting null values as zeros in excel 20
Blank (null) values plot as zeros in my charts. In excel 2003 I used tools-options-active chart-plot empty cells as but I can't figure out how to do this in excel 2007. On the Chart Tools > Design tab, click on Select Data, then click the Hidden and Empty Cells button on the dialog (bottom left corner). Note that this only works for true blank cells, not for formulas which return "". This is not a blank, but a short piece of text, which Excel evaluates as zero. - Jon ------- Jon Peltier, Microsoft Excel MVP Tutorials and Custom Solutions Peltier Technical Services, In...

Account aging formula using workdays M-F
I need a formula that calculates the working days (A) from start to todays date and (B) from start to completion. I also don't want a value displayed until at least one date is entered so it doesn't corrupt my avg formula. I'm currently using =IF(AND(D3="",C3=""),"",IF(D3="",TODAY()-C3,D3-C3)) in column C and it returns the values listed below. I want it to return only working days. A B C 4/15/10 4/23/10 8 4/20/10 3 Thanks For an inclusive count (counts both the starting date and...

assign permanent colors to bars/values in a pivot chart
I have a column in my source data called "TIER" so the values are 1, 2, 3 etc. when I convert to a pivot chart I want those values/bars to be automatically & permanently assigned a specific color. Eg. Tier 1 = Green, Tier 2 = Yellow etc. Can you help? The colours in a chart are taken from default settings for the data series in the defined order. You can change these default settings in Tools/Options/Color(tab). You see the 56 standard colours and under the thin line the colours for Chart fills and Chart lines. The first series is the left colour, etc up to 8 colou...

How to convert DATE to FILETIME ?
typedef double DATE;//wtypes.h How can I convert the DATE object to FILETIME object with C++? Thanks. >How can I convert the DATE object to FILETIME object with C++? VariantTimeToSystemTime and then SystemTimeToFileTime. Dave ...

Adding Subtracting Time Formula-Horse Racing
I would like to create a spreadsheet that will add and subtract time. I'm using this for horseracing. An example would be to subtract 45� from 1:12�. I'd be subtracting 45 and two fifths seconds from 1 minute 12 and three fifths seconds. I know one way is to enter 72.6 minus 45.4, but I'd like the spreadsheet to do all the converting if possible. Can this be done without using a macro? Thanks for any suggestions. SMD If you have minutes in A and seconds (with fractions) in B, you can use =(B2+(A2*60)-(B3+(A3*60))) to get the difference in seconds. "SMDIYDLI" &l...

Get value from another table
I have 2 database tbl_inv and tbl_coursePayment The form Course payment use tbl_coursePayment. The form has a field named Invoice No which obtain the value from tbl_inv.no + 1 as a New Course Payment Invoice no. The process is 1. get invoice no from tbl_inv.no 2. put the tbl_inv.no + 1 as new coursePayment invoice no 3. write back the new invoice no to tbl_inv.no when the form save I m newbie in VBA, would somebody give me some example code for my reference. Thank you. -- Message posted via AccessMonster.com http://www.accessmonster.com/Uwe/Forums.aspx/access-formscoding/200802/1...

Insert rows with Formulas
Hi all, I have a spreadsheet that starting at row 18 contains the following information A18=M$2 B18= Datavalidation indirect ($M$2) C18=IF(B18="No More Options",VLOOKUP($B18,INDIRECT(CONCATENATE($M$2,"_info")),1,FALSE),IF(B19<2,VLOOKUP($B18,INDIRECT(CONCATENATE($M$2,"_info")),1,FALSE),CONCATENATE(B19," x ",VLOOKUP($B18,INDIRECT(CONCATENATE($M$2,"_info")),1,FALSE))) E18=IF(ISERROR(VLOOKUP($B18,INDIRECT(CONCATENATE($M$2,"_info")),2,FALSE)),"",VLOOKUP($B18,INDIRECT(CONCATENATE($M$2,"_info")),2,FALSE)*B19) G18=C...

Number grids
Hello, I use EXCEL 2003. I'm trying to apportion some costs to optimise returns. I have managed to work out how to do it for 2 or 3 variables and use a grid form which I can see how returns are effected depending on what % of resource are allocated. For 2 variables e.g. Column A 100, 0, 99, 1, 98, 2 etc. Column B 0, 100, 1, 99, 2, 98 etc. and For 3 variables Column A 100, 0, 0, 99, 99, 0, 1, 0, 1, 98, 98, 98, 0, 2 etc. Column B 0, 100, 0, 1, 0, 99, 99, 1, 0, 2, 0, 1, 98, 98, etc. Column C 0, 0, 100, 0, 1, 1, 0, 99, 9...

Converting custom cell properties to text
Hi, I have a column of cells with telephone numbers in it and I wish to convert - or copy and paste these cells - into text format. For example, I have a telephone number as 083270000 and the cell properties (Format > Cells > Category) is listed as "Custom" and the "Type" is listed as "000000000". When I conduct a copy and paste, I lose the preceding zero before the eight. But I need this to remain and I need all the cells in "Text" format! Any ideas on how to do this? Regards Hnelg Format the column as text-go into Format>cells>cu...

Need help with a formula #2
I need to subtract 2 different sets of dates to get a total amount of days. Eg: (a-b)+(c-d) = e I then need to take the total (e) and multiply by 3 different integers if the total (e) is greater than >6 days,>10 days and >31days. This helps me keep track how long my company trucks are out of a Rail/Ship Yard. I can't seem to get the dates to subtract and get an integer(regular number). and I'm dead lost on the greater than stuff. Of course the boss drops this on me on my first day. Any help or comments will come highly appreciated. Thank you One way =A1*VLOOKUP(A1,{0,0;...

Format number
I need to do calculations on a column of numbers I have imported(copy & paste). The calculations do not work and I have discovered that the numbers have a leading blank space. I have tried to format as number but does not work. If I edit each cell and remove the leading blank space all is well. This is too time consuming. How can I format or edit more effeciently? Try using Edit>Replace Select the range of cells that hold the numbers Goto the menu Edit>Replace Find what: enter a space by hitting the space bar Replace with: nothing, leave this blank Replace All ...

define a cell with the value of anothe cell
I'm very new to excel and i think i just don't understand a basic function but i couldn't find it under the help menu. how can you define a cell using a letter and then a value of another cell? here is an example W15=5 D5=10 my guess was =D(W15) which i would like to equal 10, but i get a name error Hi Todd Try =INDIRECT("D"&W15) -- Regards Roger Govier Todd Duncombe <Todd Duncombe@discussions.microsoft.com> wrote: > I'm very new to excel and i think i just don't understand a basic > function but i couldn't find it under the help me...