Re: $$Excel-Macros$$ Formula within VB code

2011-05-16 Thread rf1234 rf1234
'HOW TO RUN EXCEL FORMULA USING VBA'
Option Explicit

Sub Function_BY_VBA()
   In sheet2 Range c2 Formula will be placed
  Sheets("SHEET1").Range("C2").Select
   ''' ActiveCell.FormulaR1C1 ="YOUR EXCEL FORMULA"
ActiveCell.FormulaR1C1 = "=IF(RC[-2]>=60,""A grade"",""B grade"")"
  End Sub





*Please change the sheet name and formula accordingly.*







On Tue, May 17, 2011 at 7:48 AM, Bob  wrote:

> I need this formula within the VB code on "Over Flow Report", Column
> "D". =IF(C3="","",B3*C3). I'm trying to understand how it works. Is
> this correct? Do I need to add anything?, Should it go in the
> worksheet_change or worksheet_select_change?
> Worksheets("Over Flow Report").Range("D3").Formula =
> "=if(C3=,,B3*C3)"
> Worksheets("Over Flow Report").Range("D3",
> Range("D65536").End(xlUp).Offset(1, 1)).FillDown
> [a:a].SpecialCells(xlBlanks).EntireRow.Delete
> Thanks in Advance!
>
> --
>
> --
> Some important links for excel users:
> 1. Follow us on TWITTER for tips tricks and links :
> http://twitter.com/exceldailytip
> 2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
> 3. Excel tutorials at http://www.excel-macros.blogspot.com
> 4. Learn VBA Macros at http://www.quickvba.blogspot.com
> 5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
>
> To post to this group, send email to excel-macros@googlegroups.com
>
> <><><><><><><><><><><><><><><><><><><><><><>
> Like our page on facebook , Just follow below link
> http://www.facebook.com/discussexcel
>



-- 
Regards,
Prashant Tripathi
Engineer-SW
Mobile: 0017202597567
Please consider the environment before printing.

Immer zielen auf die vollkommene Harmonie des
 Denkens & Wort & deed.Always zielen darauf ab,
 reinigen Sie Ihre Meinung und alles wird gut.
 
Always aim at complete harmony of thought &
 word & deed.Always aim at purifying your
thoughts & everything will be well.

-- 
--
Some important links for excel users:
1. Follow us on TWITTER for tips tricks and links : 
http://twitter.com/exceldailytip
2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
3. Excel tutorials at http://www.excel-macros.blogspot.com
4. Learn VBA Macros at http://www.quickvba.blogspot.com
5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 
To post to this group, send email to excel-macros@googlegroups.com

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link
http://www.facebook.com/discussexcel


$$Excel-Macros$$ Formula within VB code

2011-05-16 Thread Bob
I need this formula within the VB code on "Over Flow Report", Column
"D". =IF(C3="","",B3*C3). I'm trying to understand how it works. Is
this correct? Do I need to add anything?, Should it go in the
worksheet_change or worksheet_select_change?
Worksheets("Over Flow Report").Range("D3").Formula =
"=if(C3=,,B3*C3)"
Worksheets("Over Flow Report").Range("D3",
Range("D65536").End(xlUp).Offset(1, 1)).FillDown
[a:a].SpecialCells(xlBlanks).EntireRow.Delete
Thanks in Advance!

-- 
--
Some important links for excel users:
1. Follow us on TWITTER for tips tricks and links : 
http://twitter.com/exceldailytip
2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
3. Excel tutorials at http://www.excel-macros.blogspot.com
4. Learn VBA Macros at http://www.quickvba.blogspot.com
5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 
To post to this group, send email to excel-macros@googlegroups.com

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link
http://www.facebook.com/discussexcel


Re: $$Excel-Macros$$ Formula required

2011-05-16 Thread rajan verma
Try this Formula in Custom Validation..

=COUNTIF($A$1:A1,A1)=1

On Mon, May 16, 2011 at 11:07 PM, vikram  wrote:

>  Hi,
>
>
>


> Please help regarding formula for validation:
>
>
>
> If we enter any numeric value in particular column it does not allow a
> duplicate entry and shows error message.
>
>
>
> For example;if we enter 1 to 5 numeric value in particular column and try
> to enter 1 again or any value between already entered value it shows error
> message and does allow user to enter any value.
>
>
>
> Regards,
>
>
>
> Vikram
>
>
>
>
>
>
>
>
>
>
>
> Download: www.eType.com
>
>
>
> --
>
> --
> Some important links for excel users:
> 1. Follow us on TWITTER for tips tricks and links :
> http://twitter.com/exceldailytip
> 2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
> 3. Excel tutorials at http://www.excel-macros.blogspot.com
> 4. Learn VBA Macros at http://www.quickvba.blogspot.com
> 5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
>
> To post to this group, send email to excel-macros@googlegroups.com
>
> <><><><><><><><><><><><><><><><><><><><><><>
> Like our page on facebook , Just follow below link
> http://www.facebook.com/discussexcel
>



-- 
Regards
Rajan verma
+91 9158998701

-- 
--
Some important links for excel users:
1. Follow us on TWITTER for tips tricks and links : 
http://twitter.com/exceldailytip
2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
3. Excel tutorials at http://www.excel-macros.blogspot.com
4. Learn VBA Macros at http://www.quickvba.blogspot.com
5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 
To post to this group, send email to excel-macros@googlegroups.com

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link
http://www.facebook.com/discussexcel


Re: $$Excel-Macros$$ Formula required

2011-05-16 Thread Mahesh parab
Hi Vikarm

check this link
http://www.exceltip.com/st/Preventing_Duplicates_When_Entering_Data/886.html

Thanks
Mahesh

On Mon, May 16, 2011 at 11:07 PM, vikram  wrote:

>  Hi,
>
>
>
> Please help regarding formula for validation:
>
>
>
> If we enter any numeric value in particular column it does not allow a
> duplicate entry and shows error message.
>
>
>
> For example;if we enter 1 to 5 numeric value in particular column and try
> to enter 1 again or any value between already entered value it shows error
> message and does allow user to enter any value.
>
>
>
> Regards,
>
>
>
> Vikram
>
>
>
>
>
>
>
>
>
>
>
> Download: www.eType.com 
>
>
>
> --
>
> --
> Some important links for excel users:
> 1. Follow us on TWITTER for tips tricks and links :
> http://twitter.com/exceldailytip
> 2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
> 3. Excel tutorials at http://www.excel-macros.blogspot.com
> 4. Learn VBA Macros at http://www.quickvba.blogspot.com
> 5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
>
> To post to this group, send email to excel-macros@googlegroups.com
>
> <><><><><><><><><><><><><><><><><><><><><><>
> Like our page on facebook , Just follow below link
> http://www.facebook.com/discussexcel
>

-- 
--
Some important links for excel users:
1. Follow us on TWITTER for tips tricks and links : 
http://twitter.com/exceldailytip
2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
3. Excel tutorials at http://www.excel-macros.blogspot.com
4. Learn VBA Macros at http://www.quickvba.blogspot.com
5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 
To post to this group, send email to excel-macros@googlegroups.com

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link
http://www.facebook.com/discussexcel


Re: $$Excel-Macros$$ Formula required

2011-05-16 Thread ashish koul
try this link

http://www.ozgrid.com/Excel/prevent-duplicates.htm

http://www.mrexcel.com/articles/prevent-excel-duplicates.php

On Mon, May 16, 2011 at 11:07 PM, vikram  wrote:

>  Hi,
>
>
>
> Please help regarding formula for validation:
>
>
>
> If we enter any numeric value in particular column it does not allow a
> duplicate entry and shows error message.
>
>
>
> For example;if we enter 1 to 5 numeric value in particular column and try
> to enter 1 again or any value between already entered value it shows error
> message and does allow user to enter any value.
>
>
>
> Regards,
>
>
>
> Vikram
>
>
>
>
>
>
>
>
>
>
>
> Download: www.eType.com 
>
>
>
> --
>
> --
> Some important links for excel users:
> 1. Follow us on TWITTER for tips tricks and links :
> http://twitter.com/exceldailytip
> 2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
> 3. Excel tutorials at http://www.excel-macros.blogspot.com
> 4. Learn VBA Macros at http://www.quickvba.blogspot.com
> 5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
>
> To post to this group, send email to excel-macros@googlegroups.com
>
> <><><><><><><><><><><><><><><><><><><><><><>
> Like our page on facebook , Just follow below link
> http://www.facebook.com/discussexcel
>



-- 
*Regards*
* *
*Ashish Koul*
*akoul*.*blogspot*.com 
*akoul*.wordpress.com 
My Linkedin Profile 


P Before printing, think about the environment.

-- 
--
Some important links for excel users:
1. Follow us on TWITTER for tips tricks and links : 
http://twitter.com/exceldailytip
2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
3. Excel tutorials at http://www.excel-macros.blogspot.com
4. Learn VBA Macros at http://www.quickvba.blogspot.com
5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 
To post to this group, send email to excel-macros@googlegroups.com

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link
http://www.facebook.com/discussexcel


Re: $$Excel-Macros$$ MinMaxAverage : Using Sumproduct

2011-05-16 Thread ashish koul
try this

On Mon, May 16, 2011 at 12:12 PM, Chandra Shekar <
chandrashekarb@gmail.com> wrote:

> Hi,
>
> I want Min Max and Average by using Sumproduct. My problem is I want a
> formula which should be based on Date and Title as shown on Column D, E & F
> and based on Column C I need Average, Min & Max Values. If I confusing pls
> let me know.
>
> Thanks
>
> Chandra Shekar B
>
> --
>
> --
> Some important links for excel users:
> 1. Follow us on TWITTER for tips tricks and links :
> http://twitter.com/exceldailytip
> 2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
> 3. Excel tutorials at http://www.excel-macros.blogspot.com
> 4. Learn VBA Macros at http://www.quickvba.blogspot.com
> 5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
>
> To post to this group, send email to excel-macros@googlegroups.com
>
> <><><><><><><><><><><><><><><><><><><><><><>
> Like our page on facebook , Just follow below link
> http://www.facebook.com/discussexcel
>



-- 
*Regards*
* *
*Ashish Koul*
*akoul*.*blogspot*.com 
*akoul*.wordpress.com 
My Linkedin Profile 


P Before printing, think about the environment.

-- 
--
Some important links for excel users:
1. Follow us on TWITTER for tips tricks and links : 
http://twitter.com/exceldailytip
2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
3. Excel tutorials at http://www.excel-macros.blogspot.com
4. Learn VBA Macros at http://www.quickvba.blogspot.com
5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 
To post to this group, send email to excel-macros@googlegroups.com

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link
http://www.facebook.com/discussexcel


MinMaxAverage_Sumproduct(2).xls
Description: MS-Excel spreadsheet


Re: $$Excel-Macros$$ insert new row if column is missing date....

2011-05-16 Thread STDEV(i)
Sub InsertDatetUntilToday()
  ' coded by: siti Vi / Jakarta, May 16, 2011
  '---
   Dim SeleDate As Date, DiffDate As Long, n As Long
   Do While ActiveCell > 0
  If IsDate(ActiveCell) And ActiveCell < Date Then
 If Not IsEmpty(ActiveCell(2, 1)) Then
SeleDate = ActiveCell.Value
DiffDate = Date - SeleDate
ActiveCell(2, 1).Resize(DiffDate, 1).EntireRow.Insert
For n = 1 To DiffDate
   ActiveCell(n + 1, 1) = SeleDate + n
Next n
 End If
  End If
  ActiveCell(n + 1, 1).Activate
   Loop
   Me.Cells(1).Activate
End Sub




On Sun, May 15, 2011 at 4:32 PM, Stuart  wrote:

> Hi all
>
> I hope someone can help with this.
>
> My data is in columns A to F with the short date being in column B.
>
> The data is sorted in date order and the first date that appears in
> column B is 23/12/2002 and the next row contains the date 14/01/2002.
> What I need is for a macro to look at the first date in the cell that
> I have selected and then look at the next date and fill in the missing
> dates until it reaches today.  The data can go down in an unlimited
> amount of rows.
>
> So basically the macro would insert a new row with the date is column
> B as 24/12/2002, 25/12/2002, 26/12/2002 and so on and so forth.
>
> I hope this makes sense to someone
>
> Best regards
>
> Stuart
>
>

-- 
--
Some important links for excel users:
1. Follow us on TWITTER for tips tricks and links : 
http://twitter.com/exceldailytip
2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
3. Excel tutorials at http://www.excel-macros.blogspot.com
4. Learn VBA Macros at http://www.quickvba.blogspot.com
5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 
To post to this group, send email to excel-macros@googlegroups.com

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link
http://www.facebook.com/discussexcel


ctv_Insert Row and Date.xls
Description: MS-Excel spreadsheet


Re: $$Excel-Macros$$ A macro to parse a wordlist in Excel

2011-05-16 Thread Ivaylo
Hi again,

If I input this list to be processed by the macro:

abnormal termination
abnormal
abort
about
absolute
absolute address
absolute code
accent
access
access address
access mode
access control
access time
address

The case with "address" will be handled as follows:

address - absolute address|access address

Here both phrases contain the word "address", therefore the two must
be put next to "address"

What I mean is the cases where we have a phrase of 2, 3 or more words
where some of the words of the phrases is not present in the list.

If we have the following list:

abnormal termination
abnormal
abort
about
absolute
absolute address
absolute code
accent
access
access address
access mode
access control
access time

It doesn't contain the word "address" on its own. In this case, the
phrases "absolute address" and "access address" must be processes as
follows:

absolute address - absolute|address

1. The phrase must be split - i.e. the character "|" must be put in
the places of the spaces.
2. The macro must check if easch word of the split phrase exists in
the list on its own - i.e. if "absolute" exists in the list, then the
whole phrase "absolute address" must be put in the column next to it:


absolute address - absolute|address
absolute - absolute address

3. Then the macro must check the next word in the split phrase (in
this case "address"). In the list above, it doesn't exist. All these
cases must be listed in Sheet2. The word "address" in column A, and
the phrase from which it comes - in column B.

address - absolute address

4. The macro continues to process the list in Sheet1 and if it comes
accross a similar record (e.g. "access address"), it splits the phrase
(access address - access|address), copies the phrase next to its
constituent words that exist in the list (access - access address),
and copies the phrase in Sheet2 when its constituent word doesn't
exist in the list (address - absolute address|access address => in
Sheet2 "address - absolute address" already exists, it was created
when the phrase "absolute address" is created, therefore "access
address" is just added next to "absolute address" separated by "|").

Thank you very much for helping me with this task!




On May 14, 8:10 am, ashish koul  wrote:
> what in case of address
>
> which one it should pic
>
> absolute address access address
>
>
>
>
>
> On Fri, May 13, 2011 at 8:42 PM, Ivaylo  wrote:
> > Hi Ashish,
>
> > Thank you very much for your efforts!
>
> > Your macro is just what I needed.
>
> > However, it seems that it doesn't handle the exceptions:
>
> > ===
>
> > How to handle exceptions:
>
> > If the consituent word doesn't have its own headword in the list,
> > then
> > the missing word must be copied in Sheet 2, column A and the phrase
> > from which it comes from in column B - i.e. Sheet 2 must be list all
> > the words which are part of a multiword phrases but don't have their
> > own headwords.
>
> > This is the case with "abnormal termination". The word "abnormal"
> > exists as a headword, and the phrase "abnormal termination" is copied
> > in column B next to abnormal. However, the word "termination" doesn't
> > exist in column A (as a headword), then "termination" must be copied
> > to column A in Sheet 2 and the phrase "abnormal termination" to
> > column
> > B in Sheet 2 (next to "termination").
> > ===
>
> > Is it possible for you to add this functionality?
>
> > On May 13, 4:26 pm, ashish koul  wrote:
> > > try this code
>
> > > Sub tests()
> > > Dim i As Long
>
> > > Dim z As String
>
> > > For i = 1 To Sheets(1).Range("a65356").End(xlUp).Row
>
> > > If InStr(1, Application.WorksheetFunction.Trim(Cells(i, 1)), " ") > 0
> > Then
>
> > > Cells(i, 2) =
>
> > Application.WorksheetFunction.Substitute(Application.WorksheetFunction.Trim­­(Cells(i,
> > > 1)), " ", "|")
>
> > > End If
>
> > > Next i
>
> > > For i = 1 To Sheets(1).Range("a65356").End(xlUp).Row
>
> > > z = ""
> > > If InStr(1, Application.WorksheetFunction.Trim(Cells(i, 1)), " ") = 0
> > Then
>
> > > For swa = 1 To Sheets(1).Range("a65356").End(xlUp).Row
>
> > > If swa <> i Then
>
> > > If InStr(1, Application.WorksheetFunction.Trim(Cells(swa, 1)),
> > > Application.WorksheetFunction.Trim(Cells(i, 1))) > 0 Then
>
> > > z = z & Application.WorksheetFunction.Trim(Cells(swa, 1)) & "|"
>
> > > End If
>
> > > End If
>
> > > Next swa
>
> > > If Right(z, 1) = "|" Then
> > > Cells(i, 2) = Left(z, Len(z) - 1)
> > > Else
>
> > > Cells(i, 2) = z
> > > End If
>
> > > End If
>
> > > Next i
>
> > > End Sub
>
> > > On Wed, May 11, 2011 at 6:03 PM, Ivaylo  wrote:
> > > > Hi to all VBA gurus,
>
> > > > I need help with an Excel macro which can do the following:
>
> > > > I have a long list of dictionary headwords in column A (sorted
> > > > alphabetically), something like this:
>
> > > > abnormal termination
> > > > abnormal
> > > > abort
> > > > about
> > > > absolute
> > > > absolute a

Re: $$Excel-Macros$$ Copy & paste data for dynamic data_need Excel Macro Solution

2011-05-16 Thread sagaraher
How to upload a excel file??..kindly help

On May 13, 7:29 pm, ashish koul  wrote:
> can you attach the sample sheet
>
>
>
>
>
> On Thu, May 12, 2011 at 3:47 PM, sagaraher  wrote:
> > I have got following data in excel. I need to copy 1st number in given
> > row for e.g. 122532 should be copied against 100 for 4 times & similar
> > way 321654 should be get copied against 200 for 3 time like way.
> > ( Problem is that I'm not sure how many times 100 or 200 nos. comes )
>
> > kindly suggest me macro to run the same for very large data
>
> > 122532
> > 100
> > 100
> > 100
> > 100
>
> > 321654
> > 200
> > 200
> > 200
>
> > 654987
> > 300
> > 300
> > 300
> > 300
> > 300
> > 300
>
> > 987654
> > 100
> > 100
>
> > 789654
> > 300
> > 300
> > 300
> > 300
> > 300
> > 300
> > 300
> > 300
>
> > --
>
> > ---­---
> > Some important links for excel users:
> > 1. Follow us on TWITTER for tips tricks and links :
> >http://twitter.com/exceldailytip
> > 2. Join our LinkedIN group @http://www.linkedin.com/groups?gid=1871310
> > 3. Excel tutorials athttp://www.excel-macros.blogspot.com
> > 4. Learn VBA Macros athttp://www.quickvba.blogspot.com
> > 5. Excel Tips and Tricks athttp://exceldailytip.blogspot.com
>
> > To post to this group, send email to excel-macros@googlegroups.com
>
> > <><><><><><><><><><><><><><><><><><><><><><>
> > Like our page on facebook , Just follow below link
> >http://www.facebook.com/discussexcel
>
> --
> *Regards*
> * *
> *Ashish Koul*
> *akoul*.*blogspot*.com 
> *akoul*.wordpress.com 
> My Linkedin Profile 
>
> P Before printing, think about the environment.- Hide quoted text -
>
> - Show quoted text -

-- 
--
Some important links for excel users:
1. Follow us on TWITTER for tips tricks and links : 
http://twitter.com/exceldailytip
2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
3. Excel tutorials at http://www.excel-macros.blogspot.com
4. Learn VBA Macros at http://www.quickvba.blogspot.com
5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 
To post to this group, send email to excel-macros@googlegroups.com

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link
http://www.facebook.com/discussexcel


$$Excel-Macros$$ MinMaxAverage : Using Sumproduct

2011-05-16 Thread Chandra Shekar
Hi,

I want Min Max and Average by using Sumproduct. My problem is I want a
formula which should be based on Date and Title as shown on Column D, E & F
and based on Column C I need Average, Min & Max Values. If I confusing pls
let me know.

Thanks

Chandra Shekar B

-- 
--
Some important links for excel users:
1. Follow us on TWITTER for tips tricks and links : 
http://twitter.com/exceldailytip
2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
3. Excel tutorials at http://www.excel-macros.blogspot.com
4. Learn VBA Macros at http://www.quickvba.blogspot.com
5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 
To post to this group, send email to excel-macros@googlegroups.com

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link
http://www.facebook.com/discussexcel


MinMaxAverage_Sumproduct.xls
Description: MS-Excel spreadsheet


$$Excel-Macros$$ Help Needed - Copy & paste data for dynamic data_need Excel Macro Solution

2011-05-16 Thread sagar aher
I have got following data in excel. I need to copy 1st number in given
row for e.g. 122532 should be copied against 100 for 4 times & similar
way 321654 should be get copied against 200 for 3 time like way.
( Problem is that I'm not sure how many times 100 or 200 nos. comes )
kindly suggest me macro to run the same for very large data
plz find file where input & result is shown..kindly suggest me macro
solution

thanks...

-- 
Cheers

Sagar Aher :)

-- 
--
Some important links for excel users:
1. Follow us on TWITTER for tips tricks and links : 
http://twitter.com/exceldailytip
2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
3. Excel tutorials at http://www.excel-macros.blogspot.com
4. Learn VBA Macros at http://www.quickvba.blogspot.com
5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 
To post to this group, send email to excel-macros@googlegroups.com

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link
http://www.facebook.com/discussexcel


Sample data.xlsx
Description: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet


Re: $$Excel-Macros$$ help me

2011-05-16 Thread memonkavi
Dear sir

thanks 1nz again wat i requst that result i got from ur formula.,i
want to reverse for example i multiple 440.04 by 12 then i got the
result on excel itz (5280.48) bt i wnt the answer as 5284 how can i
get it?
regards kavi

On May 15, 9:32 pm, Rajesh Naharwal  wrote:
> Hi Dear,
>
> Use this formula,
>
> =roundup(5284/12,1)
>
> *Rajesh Naharwal
>
> On 15 May 2011 19:27, memonkavi  wrote:
>
>
>
>
>
>
>
>
>
> > Dear Sir
>
> > This is my problem
>
> > one cartoon 12  boxes
> > I have 440 cartoon 4 boxes
> >        cartoon  440x12=5280
> >        boxes                    4
>
> >                               5284/12=440.33   this is excel result
>
> >                I need result-440.4
>
> >                pls help me
> >                how can i?
> >                regards
> >                kavi
>
> > --
>
> > --- 
> > ---
> > Some important links for excel users:
> > 1. Follow us on TWITTER for tips tricks and links :
> >http://twitter.com/exceldailytip
> > 2. Join our LinkedIN group @http://www.linkedin.com/groups?gid=1871310
> > 3. Excel tutorials athttp://www.excel-macros.blogspot.com
> > 4. Learn VBA Macros athttp://www.quickvba.blogspot.com
> > 5. Excel Tips and Tricks athttp://exceldailytip.blogspot.com
>
> > To post to this group, send email to excel-macros@googlegroups.com
>
> > <><><><><><><><><><><><><><><><><><><><><><>
> > Like our page on facebook , Just follow below link
> >http://www.facebook.com/discussexcel

-- 
--
Some important links for excel users:
1. Follow us on TWITTER for tips tricks and links : 
http://twitter.com/exceldailytip
2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
3. Excel tutorials at http://www.excel-macros.blogspot.com
4. Learn VBA Macros at http://www.quickvba.blogspot.com
5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 
To post to this group, send email to excel-macros@googlegroups.com

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link
http://www.facebook.com/discussexcel


$$Excel-Macros$$ Re: VB Help needed.

2011-05-16 Thread Stuart Redmann
On 12 Mai, Born to Win wrote:
> Hi Experts,
>
> in attached excel file you can see contact no. along with  many services
> activated on a single no. & you can find it in separate entry i am trying to
> write a VB program so that i would have unique no. & services  (column wise)
> in new sheet in one column after a single click. please help me out
>
> Thanks,
> prabhat

The following does the same as the code in the first answer, only much
faster.

Sub PrintServiceColumnWise2()

  ' Select the contents of the sheet "Base" into an array for
  ' further processing (moving through an array is less expensive
  ' than working with the cells of the worksheet directly).
  Dim SourceSheet As Excel.Worksheet
  Set SourceSheet = Worksheets("Base")
  Dim SourceCell As Excel.Range
  Set SourceCell = SourceSheet.Range( _
  SourceSheet.Cells(2, 1), _
 
SourceSheet.Cells.SpecialCells(xlCellTypeLastCell))
  Dim SourceArray As Variant
  SourceArray = SourceCell.Value

  ReDim TargetArray(UBound(SourceArray, 1), 10) As Variant

  ' Go through the first column in the source sheet until we find
  ' an empty cell.
  Dim TargetRow As Long
  TargetRow = -1
  Dim TargetColumn As Long
  TargetColumn = 0
  Dim SourceRow As Long
  For SourceRow = LBound(SourceArray) To UBound(SourceArray, 1)

' How we have to proceed depends on whether we have seen the
' current MISDN in the last source row.
Dim LastMISDN As String
If LastMISDN <> SourceArray(SourceRow, 1) Then

  ' If we see the MISDN for the first time, we copy the
  ' MISDN into the first column and copy the service into
  ' first service column.
  TargetRow = TargetRow + 1
  TargetArray(TargetRow, 0) = SourceArray(SourceRow, 1)
  TargetArray(TargetRow, 1) = SourceArray(SourceRow, 4)
  TargetColumn = 1
  LastMISDN = SourceArray(SourceRow, 1)

Else
  ' If we have seen the MISDN in the last iteration, we have to
  ' put the current service in the next column
  ' instead of the next row.
  TargetColumn = TargetColumn + 1
  TargetArray(TargetRow, TargetColumn) = SourceArray(SourceRow, 4)
End If

' Remember the MISDN that we have seen in this iteration and
' advance the source cell to the next row.
SourceRow = SourceRow + 1

  Next

  Worksheets("Desire format").Range(Cells(4, 1), _
Cells(4 + UBound(TargetArray),
11)).Value = TargetArray

End Sub

Regards,
Stuart

-- 
--
Some important links for excel users:
1. Follow us on TWITTER for tips tricks and links : 
http://twitter.com/exceldailytip
2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
3. Excel tutorials at http://www.excel-macros.blogspot.com
4. Learn VBA Macros at http://www.quickvba.blogspot.com
5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 
To post to this group, send email to excel-macros@googlegroups.com

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link
http://www.facebook.com/discussexcel


Re: $$Excel-Macros$$ help me

2011-05-16 Thread memonkavi
thanks oflot Rajesh Nahawal!
kavi


On May 15, 9:32 pm, Rajesh Naharwal  wrote:
> Hi Dear,
>
> Use this formula,
>
> =roundup(5284/12,1)
>
> *Rajesh Naharwal
>
> On 15 May 2011 19:27, memonkavi  wrote:
>
>
>
>
>
>
>
>
>
> > Dear Sir
>
> > This is my problem
>
> > one cartoon 12  boxes
> > I have 440 cartoon 4 boxes
> >        cartoon  440x12=5280
> >        boxes                    4
>
> >                               5284/12=440.33   this is excel result
>
> >                I need result-440.4
>
> >                pls help me
> >                how can i?
> >                regards
> >                kavi
>
> > --
>
> > --- 
> > ---
> > Some important links for excel users:
> > 1. Follow us on TWITTER for tips tricks and links :
> >http://twitter.com/exceldailytip
> > 2. Join our LinkedIN group @http://www.linkedin.com/groups?gid=1871310
> > 3. Excel tutorials athttp://www.excel-macros.blogspot.com
> > 4. Learn VBA Macros athttp://www.quickvba.blogspot.com
> > 5. Excel Tips and Tricks athttp://exceldailytip.blogspot.com
>
> > To post to this group, send email to excel-macros@googlegroups.com
>
> > <><><><><><><><><><><><><><><><><><><><><><>
> > Like our page on facebook , Just follow below link
> >http://www.facebook.com/discussexcel

-- 
--
Some important links for excel users:
1. Follow us on TWITTER for tips tricks and links : 
http://twitter.com/exceldailytip
2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
3. Excel tutorials at http://www.excel-macros.blogspot.com
4. Learn VBA Macros at http://www.quickvba.blogspot.com
5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 
To post to this group, send email to excel-macros@googlegroups.com

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link
http://www.facebook.com/discussexcel


Re: $$Excel-Macros$$ help me

2011-05-16 Thread memonkavi
thanks  alot  rajan verma!!
kavi

On May 15, 9:10 pm, rajan verma  wrote:
> Use minus Sign before your formula...
>
>
>
>
>
>
>
>
>
> On Sun, May 15, 2011 at 7:27 PM, memonkavi  wrote:
>
> > Dear Sir
>
> > This is my problem
>
> > one cartoon 12  boxes
> > I have 440 cartoon 4 boxes
> >        cartoon  440x12=5280
> >        boxes                    4
>
> >                               5284/12=440.33   this is excel result
>
> >                I need result-440.4
>
> >                pls help me
> >                how can i?
> >                regards
> >                kavi
>
> > --
>
> > --- 
> > ---
> > Some important links for excel users:
> > 1. Follow us on TWITTER for tips tricks and links :
> >http://twitter.com/exceldailytip
> > 2. Join our LinkedIN group @http://www.linkedin.com/groups?gid=1871310
> > 3. Excel tutorials athttp://www.excel-macros.blogspot.com
> > 4. Learn VBA Macros athttp://www.quickvba.blogspot.com
> > 5. Excel Tips and Tricks athttp://exceldailytip.blogspot.com
>
> > To post to this group, send email to excel-macros@googlegroups.com
>
> > <><><><><><><><><><><><><><><><><><><><><><>
> > Like our page on facebook , Just follow below link
> >http://www.facebook.com/discussexcel
>
> --
> Regards
> Rajan verma
> +91 9158998701

-- 
--
Some important links for excel users:
1. Follow us on TWITTER for tips tricks and links : 
http://twitter.com/exceldailytip
2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310
3. Excel tutorials at http://www.excel-macros.blogspot.com
4. Learn VBA Macros at http://www.quickvba.blogspot.com
5. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 
To post to this group, send email to excel-macros@googlegroups.com

<><><><><><><><><><><><><><><><><><><><><><>
Like our page on facebook , Just follow below link
http://www.facebook.com/discussexcel