Is it possible to.........

Is it possible to return a cell to zero after it displays a minus number
result in a cell. ?

The minus result is the result of code being run and it can result in more
than one cell in a range eg A1:A10

I do not want a formula to be used.

Any pointers on this will be most appreciated.
Pat


0
5/2/2005 8:31:29 PM
excel.misc 78881 articles. 5 followers. Follow

4 Replies
284 Views

Similar Articles

[PageSpeed] 48

I for one do not understand.

What exactly do you mean by '... after it displays a minus number result in
a cell...' and '... minus result is the result of code being run and it can
result in more  than one cell in a range eg A1:A10...'?


-- 

HTH

RP
(remove nothere from the email address if mailing direct)


"Pat" <glass_patrick@hotmail.com> wrote in message
news:uqBipU1TFHA.3056@TK2MSFTNGP14.phx.gbl...
> Is it possible to return a cell to zero after it displays a minus number
> result in a cell. ?
>
> The minus result is the result of code being run and it can result in more
> than one cell in a range eg A1:A10
>
> I do not want a formula to be used.
>
> Any pointers on this will be most appreciated.
> Pat
>
>


0
bob.phillips1 (6510)
5/2/2005 8:40:50 PM
Hi Bob,

Ok, say for example:
A1 = -6
A4 = -21
A10 = -8

The above are the result of a calculation preformed with use of code. Once
the code completes I need some other way of returning A1, A4 & A10 to 0

I could custom filter column A to display any cells with a negative value
then just manually enter 0.
However I prefer to use another way, if that is possible.

Pat


"Bob Phillips" <bob.phillips@notheretiscali.co.uk> wrote in message
news:u$vK8c1TFHA.2128@TK2MSFTNGP15.phx.gbl...
> I for one do not understand.
>
> What exactly do you mean by '... after it displays a minus number result
in
> a cell...' and '... minus result is the result of code being run and it
can
> result in more  than one cell in a range eg A1:A10...'?
>
>
> -- 
>
> HTH
>
> RP
> (remove nothere from the email address if mailing direct)
>
>
> "Pat" <glass_patrick@hotmail.com> wrote in message
> news:uqBipU1TFHA.3056@TK2MSFTNGP14.phx.gbl...
> > Is it possible to return a cell to zero after it displays a minus number
> > result in a cell. ?
> >
> > The minus result is the result of code being run and it can result in
more
> > than one cell in a range eg A1:A10
> >
> > I do not want a formula to be used.
> >
> > Any pointers on this will be most appreciated.
> > Pat
> >
> >
>
>


0
5/2/2005 9:08:47 PM
One way would be to write a macro to find all the negative entries and 
replace them with 0.  Another way is for you to select the range that 
contains your numbers, negative ones as well as positive ones.  Then do 
Edit - Replace.  Put "-*" without the quotes for the Find, and put "0" 
without the quotes for the Replace With:.  Post back if this doesn't work 
for you.   HTH  Otto
"Pat" <glass_patrick@hotmail.com> wrote in message 
news:OSOTjs1TFHA.3084@TK2MSFTNGP10.phx.gbl...
> Hi Bob,
>
> Ok, say for example:
> A1 = -6
> A4 = -21
> A10 = -8
>
> The above are the result of a calculation preformed with use of code. Once
> the code completes I need some other way of returning A1, A4 & A10 to 0
>
> I could custom filter column A to display any cells with a negative value
> then just manually enter 0.
> However I prefer to use another way, if that is possible.
>
> Pat
>
>
> "Bob Phillips" <bob.phillips@notheretiscali.co.uk> wrote in message
> news:u$vK8c1TFHA.2128@TK2MSFTNGP15.phx.gbl...
>> I for one do not understand.
>>
>> What exactly do you mean by '... after it displays a minus number result
> in
>> a cell...' and '... minus result is the result of code being run and it
> can
>> result in more  than one cell in a range eg A1:A10...'?
>>
>>
>> -- 
>>
>> HTH
>>
>> RP
>> (remove nothere from the email address if mailing direct)
>>
>>
>> "Pat" <glass_patrick@hotmail.com> wrote in message
>> news:uqBipU1TFHA.3056@TK2MSFTNGP14.phx.gbl...
>> > Is it possible to return a cell to zero after it displays a minus 
>> > number
>> > result in a cell. ?
>> >
>> > The minus result is the result of code being run and it can result in
> more
>> > than one cell in a range eg A1:A10
>> >
>> > I do not want a formula to be used.
>> >
>> > Any pointers on this will be most appreciated.
>> > Pat
>> >
>> >
>>
>>
>
> 


0
ottokmnop (389)
5/2/2005 10:26:10 PM
Hi Pat,

Could you just run this macro at the end of your code?

Sub ClearNegatives()
Dim iLastRow As Long
Dim i As Long
    iLastRow = Cells(Rows.Count,"A").End(xlUp).Row
    For i = 1 To iLastRow
        If IsNumeric(Cells(i,"A").Value)  Then
            If Cells(i,"A").Value < 0
                Cells(i,"A").Value = 0
            End If
        End If
    Next i
End Sub

-- 

HTH

RP
(remove nothere from the email address if mailing direct)


"Pat" <glass_patrick@hotmail.com> wrote in message
news:OSOTjs1TFHA.3084@TK2MSFTNGP10.phx.gbl...
> Hi Bob,
>
> Ok, say for example:
> A1 = -6
> A4 = -21
> A10 = -8
>
> The above are the result of a calculation preformed with use of code. Once
> the code completes I need some other way of returning A1, A4 & A10 to 0
>
> I could custom filter column A to display any cells with a negative value
> then just manually enter 0.
> However I prefer to use another way, if that is possible.
>
> Pat
>
>
> "Bob Phillips" <bob.phillips@notheretiscali.co.uk> wrote in message
> news:u$vK8c1TFHA.2128@TK2MSFTNGP15.phx.gbl...
> > I for one do not understand.
> >
> > What exactly do you mean by '... after it displays a minus number result
> in
> > a cell...' and '... minus result is the result of code being run and it
> can
> > result in more  than one cell in a range eg A1:A10...'?
> >
> >
> > -- 
> >
> > HTH
> >
> > RP
> > (remove nothere from the email address if mailing direct)
> >
> >
> > "Pat" <glass_patrick@hotmail.com> wrote in message
> > news:uqBipU1TFHA.3056@TK2MSFTNGP14.phx.gbl...
> > > Is it possible to return a cell to zero after it displays a minus
number
> > > result in a cell. ?
> > >
> > > The minus result is the result of code being run and it can result in
> more
> > > than one cell in a range eg A1:A10
> > >
> > > I do not want a formula to be used.
> > >
> > > Any pointers on this will be most appreciated.
> > > Pat
> > >
> > >
> >
> >
>
>


0
bob.phillips1 (6510)
5/2/2005 11:22:21 PM
Reply:

Similar Artilces:

is it possible to read a previous node by XMLReader?
I know XMLReader can only move forward. In my program I may need to go back to read a previous node from XML file again and I don't like to use DOM, do we have any tricky way to do it? Thanks. Linda Chen "Linda Chen" <linda.chen@faa.gov> writes: > I know XMLReader can only move forward. In my program I > may need to go back to read a previous node from XML file > again and I don't like to use DOM, do we have any tricky > way to do it? My trick was to use a Stack variable where to put the stuff, I used it to put the name of the previous element.....

Is it possible to add background sound to an email in Outlook 2007?
Is it possible to add background sound to an email in Outlook 2007? -- Message posted via OfficeKB.com http://www.officekb.com/Uwe/Forums.aspx/ms-outlook/201005/1 Outlook can't play active content so while you could embed it (using an HTML editor), it won't play. -- Diane Poremsky [MVP - Outlook] Outlook Tips: http://www.outlook-tips.net/ Outlook & Exchange Solutions Center: http://www.slipstick.com/ Outlook Tips by email: mailto:dailytips-subscribe-request@lists.outlooktips.net EMO - a weekly newsletter about Outlook and Exchange: mailto:EMO-NEWSLETTER-S...

Is this possible in excel?
I have an excel sheet that I update and want others to view it only(view permissions only). My Question is: Can myself and other person edit the sheet at the same time? Can I assign certain certain rows, columns only that someone can edit(insert, update data)? Can I make certain fields(columns/rows) mandatory while editing. For eg, If I have a sheet with columns Name, City, St, Address, Zip Can I make data in Zip column mandatory? (it has to be populated)? Thanks in Advance Your frst question, yes you can share the workbook. As far as the zip codes are concerned,...

Are text fields >255 characters possible in Project?
I am using Project 2007. I have explanatory fields I would like to enter into my Project Plan. Many of those are longer than 255 characters. Is there a way to have a field for text larger than 255 char? No. You will need to use the NOTES field. Double click on the task, pull the Notes tab and type there. As an FYI, the Notes field will not show 100% of its contents if you insert the Notes column. What it will show is the smaller of: 1. The first 255 characters 2. Up to the first carriage return. Although 100% of the data is still there, it will not show it as a column....

Is it possible with Access VB to check if any users are logged onto another Access DB?
Hi All Is it possible with Access VB to determine if any users are logged onto other Access DBs? I have a "mother" DB that replicates itself into a number of "child" DBs with a subset of its data. For obvious reasons I can only do this when no-one is using the "child" DBs. Is it possible to write some VB to call out to other DBs and see if anyone is logged on? Cheers for any ideas, suggestions or links, Chrisso hi Chrisso, Chrisso wrote: > Is it possible to write some VB to call out to other DBs and see if > anyone is logged on? http://allenbrowne.com/...

Is variable chart scale possible?
I would like to know if it is possible for the axis scales on a chart t be variable, without using auto-scaling. In other words, for each axis, I want the Minumum, Maximum, and Majo Unit to be the values of three particular cells in the worksheet. I would be ideal if I could simply put the cell addresses in the field for the min, max and major unit instead of just values, but this doe not seem to be possible. Is there any way around this? Thanks ----------------------------------------------- ~~ Message posted from http://www.ExcelTip.com ~~View and post usenet messages directly from htt...

BitBlt / CBitmap / CDC
hi - just as topic. thanks, philipp hi, look into layered windows. (win2k, xp) - sami "Philipp Huber" <philipp.huber@innval.com> wrote in message news:bovrcr$hvj$03$1@news.t-online.com... > hi - just as topic. > > thanks, philipp > > ...

Is it possible to change the blue colour of an activated Auto Filter button?
When Auto Filtering is on and one of the filters is active, the button's colour is changed to blue. Often, I find it difficult to distinct this blue colour with the black colour of an inactive filter. Can the colour of this blue Auto Filter button be changed? -- Message posted via http://www.officekb.com AFAIK, no one has found a way to change the autofilter arrow colour. If you can use programming, there's a sample file that uses a User Defined Function and conditional formatting to colour the heading cells: http://www.contextures.com/excelfiles.html under the heading '...

If Function Possibilities
Is there a way to set up in a cell A1, something like... If the formula used in cell B1 is "here I would type the actual formula in," then display the words "works," else display "mistake" ? -- rheller ------------------------------------------------------------------------ rheller's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=24081 View this thread: http://www.excelforum.com/showthread.php?threadid=377045 That's a pretty cryptic post. Do you mean: In A1: =IF(B1=n,"Works","Mistake") where 'n...

Charting possibility
Hi, Is there a way to chart a series of data along with markers for specific events.. something similar to what http://finance.google.com have. Essentially how can this data be charted in the most informative way using excel? Month Value Event Jan 80 Feb 75 Mar 25 Pilot study implemented Apr 30 May 56 Next version released June 67 July 82 Thanks, Debraj See Jon's stuff at http://peltiertech.com/Excel/Charts/ComboCharts.html#AddLine best wishes -- Bernard V Liengme www.stfx.ca/people/bliengme remove caps from email "debraj&quo...

Possible Information Store corruption?
I recieve emails sent to a distribution group which I am not a part of. This looks to be a sign of corruption yet when I run eseutil /d and eseutil /p and isinteg I receive no errors. Should I call MS support on This? "Greg" <Greg@discussions.microsoft.com> wrote: >I recieve emails sent to a distribution group which I am not a part of. This >looks to be a sign of corruption yet when I run eseutil /d and eseutil /p and >isinteg I receive no errors. Should I call MS support on This? If there was a problem it'd probably be in the directory not the information s...

Possible Message loop
We have an Exchange 2003 Sp2 environment, we are seeing our inbound queues get back up from time to time. We are seeing a high number of Event ID: 3030 in our application log. How does one track down a possible message loop? Does Event ID: 3030 indicate a possible message loop? Sabo, Eric <sabo_e@cup.edu> wrote: >We have an Exchange 2003 Sp2 environment, we are seeing our inbound queues >get back up from time to time. We are seeing a high number of Event ID: >3030 in our application log. How does one track down a possible message >loop? Does Ev...

Is it possible to have If statements in a query?
Hello, I have a subform and in this suform I have a combobox field called "Category". In this combobox I have a select query that pulls the Category and TeamName. On the master form I have a floating combobox called Team. When I choose a team in this field I would like the subform combobox to be narrowed down a little as such if possible... If the Team field on the master form is Accounting I would like the Category combobox to be limitted to "Accounting" and "Other" team names. If the Team field on the master form is ESTABLISHMENT I need the Cate...

Repeat Button Possible?
Hello, I was wondering if this is possible: If a user has three loans by the same company(but different loan numbers, amounts etc..) and fills in all the information in record one, because most of the information will be the same for the next two records(next two loans) is there a way to repeat the information from the first record to automatically fill in record two and three by clicking a button or something? My reason for asking is because one of the users said it take a lot of time to entered repeated information and asked if there was a way to carry it to the next record. Thanks...

Changing 100's of users Exchange custom attributes
Under Exchange Advanced > Custom Attributes we need to change ExtensionAttribute1 on 100's of users o some thing else, is there an easy way to do this? On Fri, 15 Dec 2006 11:48:58 -0000, "Gonzo" <no@no.com> wrote: >Under Exchange Advanced > Custom Attributes we need to change >ExtensionAttribute1 on 100's of users o some thing else, is there an easy >way to do this? > Find and download ADMODIFY.NET and use it. There is a "Custom" tab where you enter the name of the CA you want to edit and the value you want in it. If you're tal...

Is it possible to have two computers share mailboxes on a networked disk?
I have a home computer and a laptop; both with licensed copies of Outlook XP. What I would like to be able to do is have one location for my e-mail which I can acess from either my home machine or my laptop; which I take with me when I go to school. Currently I have my mail residing on my laptop inside of a share called mailbox that only I can see. I have three pop servers that I get e-mail along with one Hotmail account and one IMAP account. I would like to be able to read mail from my home machine when I am at home; with the laptop being nothing more than a disk server. When set...

Possible DNS issues!
Hello, I am having problems recieving mail. If I send a mail from my hotmail account to my work account the mail arrives and I hit reply and the mail goes back fine. If I just send a mail from my work account to my hotmail which isn't a reply, it doesn't turn up! I have telneted into the Outgoing SMTP domain on port 25 and it connects fine. The mail is leaving the exchange server definatly. I think it may be a DNS issue, the DNS settings on my SBS 2003 Server are 1. Exchange Server 2. ISP DNS server 3. Router. Have I set this up incorectly? Do I need the IP address of my out...

Attachements in Body of Mail
Hello All Work have recently upgraded our laptops and I know have Outlook 2003. In my previous version (cant recall which one sorry) I could insert a file attachement (pdf, doc or xls) within the body of the text, now I can only insert them as an attachement away from the text. In my emails I like to say to users, for example, the reuslts can be found here :- (FILE GOES HERE) Is this not possible in Outlook 2003 (I am sending mails in HTML format too). Many thanks for any answers ;o) Carl. CHange your message format to rich-text instead of HTML or plain text. = But note that onl...

Is this possible?? Help with charting...
Using Excel 2k3... Ok, I have a basic set of data, detailing cash values by month, for a period of several years. Here's what I'm working toward, but haven't been able to get it to work. I'd like to be able to group a series of values (for example, June of one year through May of the next) on the chart as a SINGLE bar. As another option, I'd like all bars of a single calendar year to be the same color, even though they're different data elements... Thoughts? Thanks! Jack for the first question, can you just sum the data and plot it that way? for the secon...

In charts, is it possible to change data references to relevant?
Ive created a basic bar chart, but the speadsheet in which the data is held is constantly being updated. This is ruining my graph as the data references are absolute. Is there a way of changing the source data references to relevant? ive tried "f4" when in the graph "Source data", "values" option, but this does not work. Ive tried deleting all of the $ from the data, but they apear again when the dialogue box is closed. Charts use absolute references. But you can also use a reference to a dynamic name: http://peltiertech.com/Excel/Charts/Dynamics.html ...

Page Break Preview-Remove Page Number Possible?
When I go Page Break Preview, I notice that the page number in the background appears. Can I remove this numberand the word Page totally? Thanks! Tim AFAIK, no. However, if you have access to a Mac with Office 2004, you can use Page Layout view, which allows you to see exactly what will appear on the page, while allowing you to enter data and formulas, edit/format cells, insert headers and footers, adjust and set column and row widths and heights in inches/cm, etc. In article <1201801c4426d$ca124540$a301280a@phx.gbl>, "Tim" <anonymous@discussions.microsoft.com>...

Possible to insert an Adobe pdf file to Publisher application?
I create a monthly newsletter for a non-profit organization using Publisher. They have ads they want me to have inserted that are pdf files, and I can not figure out how to insert them. All I get is an Adobe symbol, not the actual file. Is this even possible? How?? I just ran into the same issue. If you have Acrobat, yes. (I used to have Acrobat and could.) If not, I've used SnagIt to create a .png file of the ..pdf file. I've gotten real nice results that way. You can try a regular screenshot and crop that to suit. (Even if you tell people you want ads as a .jpgs, .png, or...

1. Is it possible to do this excel?
Hi friends, i have a small query if you got little time. i have many numbers in an excel worksheet and i want to round them up only for decimal places and that too like this way. 219.39---219.35 219.32---219.30 219.34---219.30 219.37---219.35 I mean decimal places must end in .05, .10, .15, .20, .25, .30, so on. what is the function for this result. thanks in advance. Try this =FLOOR(A1,0.05) Mike "san" wrote: > Hi friends, i have a small query if you got little time. i have many numbers > in an excel worksheet and i want to round them up only for decimal places ...

Possible to link Excel cells to text box in Word using Word's text formatting?
Hi everyone. Here is one of those "is this possible" type situations, which if possible, would make my Augusts less stressful each year. Each August I'm in charge of putting together our annual statistics and producing maps of the state to show activity in each county. Initially my maps were Word documents with individual text boxes for each #. I still have that version saved, but recently I've converted it to a pdf document to make changing the numbers a lot easier (although not being able to add lines of text is a hindrance sometimes). What I'd love to be able to do i...

Advanced Find: Nested queries possible?
Hi, I've been experimenting in SQL with using nested queries to match on child Subject records that are related to a specific Subject higher up the subject hierarchy. For example: SELECT CreatedByDsc, CreatedByName, CreatedByYomiName, ModifiedByDsc, ModifiedByName, ModifiedByYomiName, OrganizationIdDsc, OrganizationIdName, ParentSubjectDsc, ParentSubjectName, SubjectId, Title, OrganizationId, DeletionStateCode, Description, ParentSubject, FeatureMask, CreatedBy, CreatedOn, ModifiedBy, ModifiedOn, VersionNumber, ImportSequenceNumber...