macro to continue running if error

Hi,

I have the following macro that is working fine. It is looking at a
specified worksheet array and executing the macro "Filter" on each
worksheets. However, in case one of the worksheet is not existing, I
would like the macro to pass the non existing worksheet and continue
running on the next available worksheet. I tried adding the following
statement: "On Error Resume Next" at the beginning but it is passing
everything.

Any help would be appreciated.
Thanks

Sub UpdateAll()
    For Each sh In Worksheets(Array("1", "2", "3", "4", "5", "6", "7",
"10", "11", "12", "21", "22", _
    "23", "24", "25", "26", "27", "28", "29", "30", "31", "41", "42",
"43", "44", "45", "46", _
    "47", "48", "49", "50", "51", "52", "53", "54", "55", "61"))
    sh.Select
    Call Filter
    Next sh
End Sub
0
Norvascom
2/28/2010 8:10:41 PM
excel.programming 6508 articles. 2 followers. Follow

6 Replies
950 Views

Similar Articles

[PageSpeed] 18

I'd try...

Option Explicit
Sub UpdateAll()
    Dim iCtr As Long
    Dim myArr As Variant
    Dim TestWks As Worksheet
    
    myArr = Array("1", "2", "3", "4", "5", "6", "7", _
                    "10", "11", "12", "21", "22", _
                    "23", "24", "25", "26", "27", _
                    "28", "29", "30", "31", "41", "42", _
                    "43", "44", "45", "46", _
                    "47", "48", "49", "50", "51", "52", _
                    "53", "54", "55", "61")
    
    For iCtr = LBound(myArr) To UBound(myArr)
        Set TestWks = Nothing
        On Error Resume Next
        Set TestWks = Worksheets(myArr(iCtr))
        On Error GoTo 0
        
        If TestWks Is Nothing Then
            'not found!
        Else
            TestWks.Select
            Call macFilter
        End If
    Next iCtr
    
End Sub

I wouldn't use Filter as the name of a procedure.  If you search VBA's help,
you'll see that it's used by excel.

Norvascom wrote:
> 
> Hi,
> 
> I have the following macro that is working fine. It is looking at a
> specified worksheet array and executing the macro "Filter" on each
> worksheets. However, in case one of the worksheet is not existing, I
> would like the macro to pass the non existing worksheet and continue
> running on the next available worksheet. I tried adding the following
> statement: "On Error Resume Next" at the beginning but it is passing
> everything.
> 
> Any help would be appreciated.
> Thanks
> 
> Sub UpdateAll()
>     For Each sh In Worksheets(Array("1", "2", "3", "4", "5", "6", "7",
> "10", "11", "12", "21", "22", _
>     "23", "24", "25", "26", "27", "28", "29", "30", "31", "41", "42",
> "43", "44", "45", "46", _
>     "47", "48", "49", "50", "51", "52", "53", "54", "55", "61"))
>     sh.Select
>     Call Filter
>     Next sh
> End Sub

-- 

Dave Peterson
0
Dave
2/28/2010 9:04:15 PM
Hi,

Not very elegant but it works. Look out for the line wrap on the string of 
sheet names


Public sh As Worksheet
Sub UpdateAll()
S = 
"1,2,3,4,5,6,7,10,11,12,21,22,23,24,25,26,27,28,29,30,31,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,61"
V = Split(S, ",")
For Each sh In ActiveWorkbook.Worksheets
    If Not IsError(Application.Match(sh.Name, V, 0)) Then
     Call filter
    End If
Next
End Sub

Sub filter()
MsgBox "Filter " & sh.Name
End Sub
-- 
Mike

When competing hypotheses are otherwise equal, adopt the hypothesis that 
introduces the fewest assumptions while still sufficiently answering the 
question.


"Norvascom" wrote:

> Hi,
> 
> I have the following macro that is working fine. It is looking at a
> specified worksheet array and executing the macro "Filter" on each
> worksheets. However, in case one of the worksheet is not existing, I
> would like the macro to pass the non existing worksheet and continue
> running on the next available worksheet. I tried adding the following
> statement: "On Error Resume Next" at the beginning but it is passing
> everything.
> 
> Any help would be appreciated.
> Thanks
> 
> Sub UpdateAll()
>     For Each sh In Worksheets(Array("1", "2", "3", "4", "5", "6", "7",
> "10", "11", "12", "21", "22", _
>     "23", "24", "25", "26", "27", "28", "29", "30", "31", "41", "42",
> "43", "44", "45", "46", _
>     "47", "48", "49", "50", "51", "52", "53", "54", "55", "61"))
>     sh.Select
>     Call Filter
>     Next sh
> End Sub
> .
> 
0
Utf
2/28/2010 9:42:01 PM
I am assuming that the numbers are the actual sheet names and not the sheet 
index number. If my assumption is correct then try the code below and there 
will be no error.

Using Select Case, even though there is only one case, multiple names can be 
used separated by a comma and in effect they become Or operators.

The reason for the error in your code is that if the sheet does not exist, 
you cannot use it in the array in the For Each statement.

Sub UpdateAll()
Dim sh As Worksheet
    For Each sh In Worksheets

      Select Case sh.Name
      
        Case "1", "2", "3", "4", "5", _
          "6", "7", "10", "11", "12", _
          "21", "22", "23", "24", "25", _
          "26", "27", "28", "29", "30", _
          "31", "41", "42", "43", "44", _
          "45", "46", "47", "48", "49", _
          "50", "51", "52", "53", "54", _
          "55", "61"
        
      End Select
      
      sh.Select
      
      Call Filter
      
    Next sh
End Sub

-- 
Regards,

OssieMac


0
Utf
2/28/2010 9:46:01 PM
My apologies. An error in the code I posted. It will work better if the 
Select and Call are included within the Case instead of outside of it. Also 
noted Dave's comment re Filter

Sub UpdateAll()
Dim sh As Worksheet
    For Each sh In Worksheets

      Select Case sh.Name
      
        Case "1", "2", "3", "4", "5", _
          "6", "7", "10", "11", "12", _
          "21", "22", "23", "24", "25", _
          "26", "27", "28", "29", "30", _
          "31", "41", "42", "43", "44", _
          "45", "46", "47", "48", "49", _
          "50", "51", "52", "53", "54", _
          "55", "61"
      
          sh.Select
      
          Call macFilter
          
      End Select
      
      
    Next sh
End Sub

-- 
Regards,

OssieMac


"OssieMac" wrote:

> I am assuming that the numbers are the actual sheet names and not the sheet 
> index number. If my assumption is correct then try the code below and there 
> will be no error.
> 
> Using Select Case, even though there is only one case, multiple names can be 
> used separated by a comma and in effect they become Or operators.
> 
> The reason for the error in your code is that if the sheet does not exist, 
> you cannot use it in the array in the For Each statement.
> 
> Sub UpdateAll()
> Dim sh As Worksheet
>     For Each sh In Worksheets
> 
>       Select Case sh.Name
>       
>         Case "1", "2", "3", "4", "5", _
>           "6", "7", "10", "11", "12", _
>           "21", "22", "23", "24", "25", _
>           "26", "27", "28", "29", "30", _
>           "31", "41", "42", "43", "44", _
>           "45", "46", "47", "48", "49", _
>           "50", "51", "52", "53", "54", _
>           "55", "61"
>         
>       End Select
>       
>       sh.Select
>       
>       Call Filter
>       
>     Next sh
> End Sub
> 
> -- 
> Regards,
> 
> OssieMac
> 
> 
0
Utf
2/28/2010 10:01:01 PM
On Feb 28, 5:01=A0pm, OssieMac <Ossie...@discussions.microsoft.com>
wrote:
> My apologies. An error in the code I posted. It will work better if the
> Select and Call are included within the Case instead of outside of it. Al=
so
> noted Dave's comment re Filter
>
> Sub UpdateAll()
> Dim sh As Worksheet
> =A0 =A0 For Each sh In Worksheets
>
> =A0 =A0 =A0 Select Case sh.Name
>
> =A0 =A0 =A0 =A0 Case "1", "2", "3", "4", "5", _
> =A0 =A0 =A0 =A0 =A0 "6", "7", "10", "11", "12", _
> =A0 =A0 =A0 =A0 =A0 "21", "22", "23", "24", "25", _
> =A0 =A0 =A0 =A0 =A0 "26", "27", "28", "29", "30", _
> =A0 =A0 =A0 =A0 =A0 "31", "41", "42", "43", "44", _
> =A0 =A0 =A0 =A0 =A0 "45", "46", "47", "48", "49", _
> =A0 =A0 =A0 =A0 =A0 "50", "51", "52", "53", "54", _
> =A0 =A0 =A0 =A0 =A0 "55", "61"
>
> =A0 =A0 =A0 =A0 =A0 sh.Select
>
> =A0 =A0 =A0 =A0 =A0 Call macFilter
>
> =A0 =A0 =A0 End Select
>
> =A0 =A0 Next sh
> End Sub
>
> --
> Regards,
>
> OssieMac
>
>
>
> "OssieMac" wrote:
> > I am assuming that the numbers are the actual sheet names and not the s=
heet
> > index number. If my assumption is correct then try the code below and t=
here
> > will be no error.
>
> > Using Select Case, even though there is only one case, multiple names c=
an be
> > used separated by a comma and in effect they become Or operators.
>
> > The reason for the error in your code is that if the sheet does not exi=
st,
> > you cannot use it in the array in the For Each statement.
>
> > Sub UpdateAll()
> > Dim sh As Worksheet
> > =A0 =A0 For Each sh In Worksheets
>
> > =A0 =A0 =A0 Select Case sh.Name
>
> > =A0 =A0 =A0 =A0 Case "1", "2", "3", "4", "5", _
> > =A0 =A0 =A0 =A0 =A0 "6", "7", "10", "11", "12", _
> > =A0 =A0 =A0 =A0 =A0 "21", "22", "23", "24", "25", _
> > =A0 =A0 =A0 =A0 =A0 "26", "27", "28", "29", "30", _
> > =A0 =A0 =A0 =A0 =A0 "31", "41", "42", "43", "44", _
> > =A0 =A0 =A0 =A0 =A0 "45", "46", "47", "48", "49", _
> > =A0 =A0 =A0 =A0 =A0 "50", "51", "52", "53", "54", _
> > =A0 =A0 =A0 =A0 =A0 "55", "61"
>
> > =A0 =A0 =A0 End Select
>
> > =A0 =A0 =A0 sh.Select
>
> > =A0 =A0 =A0 Call Filter
>
> > =A0 =A0 Next sh
> > End Sub
>
> > --
> > Regards,
>
> > OssieMac- Hide quoted text -
>
> - Show quoted text -


Thanks OssieMac
0
Norvascom
3/1/2010 1:42:45 AM
Hi.  You would have to add a little more logic to this, but here's an 
additional general idea:

     Select Case Val(sh.Name)

     Case 1 To 7, 10 To 12, 21 To 31 'etc
         'Do Something
     Case Else
         'Do Nothing
     End Select

= = = = = = =
HTH  :>)
Dana DeLouis

On 2/28/2010 8:42 PM, Norvascom wrote:
> On Feb 28, 5:01 pm, OssieMac<Ossie...@discussions.microsoft.com>
> wrote:
>> My apologies. An error in the code I posted. It will work better if the
>> Select and Call are included within the Case instead of outside of it. Also
>> noted Dave's comment re Filter
>>
>> Sub UpdateAll()
>> Dim sh As Worksheet
>>      For Each sh In Worksheets
>>
>>        Select Case sh.Name
>>
>>          Case "1", "2", "3", "4", "5", _
>>            "6", "7", "10", "11", "12", _
>>            "21", "22", "23", "24", "25", _
>>            "26", "27", "28", "29", "30", _
>>            "31", "41", "42", "43", "44", _
>>            "45", "46", "47", "48", "49", _
>>            "50", "51", "52", "53", "54", _
>>            "55", "61"
>>
>>            sh.Select
>>
>>            Call macFilter
>>
>>        End Select
>>
>>      Next sh
>> End Sub
>>
>> --
>> Regards,
>>
>> OssieMac
>>
>>
>>
>> "OssieMac" wrote:
>>> I am assuming that the numbers are the actual sheet names and not the sheet
>>> index number. If my assumption is correct then try the code below and there
>>> will be no error.
>>
>>> Using Select Case, even though there is only one case, multiple names can be
>>> used separated by a comma and in effect they become Or operators.
>>
>>> The reason for the error in your code is that if the sheet does not exist,
>>> you cannot use it in the array in the For Each statement.
>>
>>> Sub UpdateAll()
>>> Dim sh As Worksheet
>>>      For Each sh In Worksheets
>>
>>>        Select Case sh.Name
>>
>>>          Case "1", "2", "3", "4", "5", _
>>>            "6", "7", "10", "11", "12", _
>>>            "21", "22", "23", "24", "25", _
>>>            "26", "27", "28", "29", "30", _
>>>            "31", "41", "42", "43", "44", _
>>>            "45", "46", "47", "48", "49", _
>>>            "50", "51", "52", "53", "54", _
>>>            "55", "61"
>>
>>>        End Select
>>
>>>        sh.Select
>>
>>>        Call Filter
>>
>>>      Next sh
>>> End Sub
>>
>>> --
>>> Regards,
>>
>>> OssieMac- Hide quoted text -
>>
>> - Show quoted text -
>
>
> Thanks OssieMac



0
Dana
3/1/2010 2:16:15 AM
Reply:

Similar Artilces:

Outlook 2007 send/receive error
Using Win XP-Pro. Was using Outlook Express for email. Installed Outlook 2007 this morning and imported addresses and files from Express. Everything seemed to work fine until I attempted to send/receive. Got error message (0x8007000E) "out of memory or system resources". Cleaned off all extraneous files and significantly reduced folder storage amounts. Have run all diagnostics that I can find with no problems identified. Have checked my internet connections and everythng worked fine. Problem seems to be with Outlook. Would appreciate any suggestions for correction of problem. ...

KDC Error #2
Hi I am confuss and unable to figure out which SPN is duplicated. Please help. The message generated by LDP as follows: CN=SERVER, OU=Domain Controllers, DC=ems,DC=local 1> name: SERVER 1> canonicalName: ems.local/DomainController/SERVER >>Dn: CN=KavernTan,OU=SBSUsers,OU=Users,OU=MyBusiness, DC=ems,DC=local 4> objectClass:top;person,organizationPerson;user; 1>cn:kavern Tan 1>distinguishedName:CN=Kavern Tan,OU=SBSUsers,OU=Users,OU=MyBusiness, Dc=ems,Dc=local 1>name:Kavern Tan 1>canonicalNamw: ems.local/MyBusiness/Users/SBSU...

Macro warning with no macros
I have a workbook that when I try to open it I get the warning tellin me it contains macros and asking whether I want to Enable or Disabl them. I put no macros, no VB scripts, nothing at all in the workboo other than standard Excel formulas and some charts. I developed it i Excel 2002, SP-2, but have moved it back and forth between tw computers, the other which has Excel 97. Regardless of whether Enable or Disable or change the security settings so as not to get th warning, once the workbook is open even if I go t Tools-Macro-Macros... it lists no macros. How can I find out what's cau...

Macro
Can anybody tell me how to kick off a macro automatically as file is opened? Regards ...

Compile Error: Can't Find Project or Library
I have a spreadsheet containing 7 userforms and 9 modules. The spreadsheet has been developed on the same computer for a number of years and remained stable. However, I now want to make some amendments to one of the userforms. Whenever I make any changes to the UserForm_Initialize statement (even entering a blank space), I get the compile error 'can't find project or library'. Does anyone know why this happens and, more importantly, how to stop it. ...

XmlSchemaSet Compile error ?
Here under 4 schemas i'm working with ( it may be long: sorry...) The context is the following : Resident.xsd imports Person.xsd and includes Common.xsd ( anonimous schema: no TargetNamespace ) Person.xsd includes Common-Naming.xsd ( anonimous schemas ) Common-Naming.xsd includes common.xsd ( both are anonimous schemas ) Compilation of Resident.xsd raise the following exception: "System.Xml.Schema.XmlSchemaException: The attribute 'oid' already exists...." That is wrong : the schemas are valid and well done ( Xml-Spy ). The problem seems to be that Common.xsd app...

Macro
Version: 2008 Operating System: Mac OS X 10.4 (Tiger) Processor: intel Hi, I'm thinking of buying Mac: Office 2008, but before I do I want to check that I will be able to download Scritpsmart collection of templates without any glitches: <http://www.bbc.co.uk/writersroom/scriptsmart/faq.shtml> Does anyone know if I can do this? Regards, SP. In article <ee98ff5.-1@webcrossing.caR9absDaxw>, StregaItalia@officeformac.com wrote: > Version: 2008 > Operating System: Mac OS X 10.4 (Tiger) > Processor: intel > > Hi, > > I'm thinking of buying Mac: Of...

Attached Toolbars Macros
Excel 2003 I have a custom tool bar, this tool bar has several items, each item is pointing to a VBA code. This tool bar is attached to the worksheet. I've copied this spreadsheet to several computers. After I copied the spreadsheet I decided to rename the spreadsheet, after I renamed the spreadsheet the Toolbar Item's macros were still pointing to the old name, I reasigned each tool bar item to the current spreadsheet, saved the spreadsheet and everything was working on my computer, but when I re-copied the new spreadsheet to other computers and I clicked on the Toolbar Item...

How to Stop Worksheet_Change event from running during code execution
I'm sorry If I've asked this before but I can't find an answer to it. I have the following 2 events in a worksheet module.... Private Sub Worksheet_Change(ByVal Target As Excel.Range) Private Sub Worksheet_SelectionChange(ByVal Target As Range) I run some codes, either in UserForms or general procedures that make changes to this worksheet. Q. Is there a way to by-pass those two events somehow? As an example I have a uf that comes up if a cell is selected in that sheet. So I need those worksheet_Change events to work at that point. But then, the uf does some stuff like inputing ...

Run macro automatically.
How do I make a macro run automatically when a worksheet it is attached to is loaded? right click on the sheet tab>view code>left window worksheet>right window activate -- Don Guillett SalesAid Software donaldb@281.com "Excel macro" <Excel macro@discussions.microsoft.com> wrote in message news:DD7AF1E3-9263-4523-AC49-A43ABA1AB9D0@microsoft.com... > How do I make a macro run automatically when a worksheet it is attached to is > loaded? I am unable to find "activate " when I right click on worksheet. ( i assume that you are referring to the windo...

Help with macro/and or formula?
Perhaps this is a silly question, but i just can't figure out how t format this worksheet. The problem is that a lot of the cells hav numbers in them with negative signs in the back instead of in the fron (ie. 23-) and i was wondering if anyone knew of a macro/formula i coul use to quickly fix this problem for all the cells. I would b extremely grateful. Thanks -- brefed1 ----------------------------------------------------------------------- brefed15's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=3557 View this thread: http://www.excelforum.com/showthre...

Protected sheets and running macros
i have a sheet with a macro ran by a normal button at the top. Howeve when i protect the worksheet where ever i click on the sheet the macr executes. Can any one offer any advice on how to stop this? Thanks Robert -- Message posted from http://www.ExcelForum.com hi, i am not able to reproduce the problem, hence i may not be able t provide a panacea for that issue. here is what i suggest. i have a sheet that has a macro that is run when a control toolbo button (that is, not a form button) is clicked. this sheet is protected based on the user logged in. what i have don is to protect t...

Error when moving mailbox
I received this error when I am move some mailboxes, not all. I checked all the permissions are good. Can someone help please? <item adsPath="LDAP://xxx/CN=xxx,OU=xxx,OU=Users and Groups,DC=xxx,DC=ad" class="user"> <progress code="21" milliseconds="23937">Moving messages.</progress> - <summary isWarning="false" errorCode="0xc1050301"> An unexpected, unknown error has occurred. MAPI or an unspecified service provider. ID no: 80040301-0000-00000000 On Thu, 9 Feb 2006 16:16:30 -0800, Speedyturtle <S...

Macro to remove rows?
Hi, I receive thousands of rows of data from an extract that comes from a database. The data extract automatically generates page headers that need to be removed, and I would love to automate this process. The headers do have a pattern to them, but I'm not clever enough to figure out a good way to use that to write a macro. The first row of the header starts with hyphens ------------------------------- Then there's a variable number of rows of header data to delete followed by another row of hyphens ------------------------------- Then 2 additional rows that must be deleted. The nu...

Macro Freezes Reading Pane
I have a macro that Sends/Receives Tasks from Project Server into Outlook Tasks. Everything is working fine, except one weird thing that happens. I have the Timer set on the macro and it starts as soon as Outlook starts. The macro gets the tasks from ProjectServer every hour. As soon as the macro starts running the Reading pane freezes in the Inbox. If i stop the macro then Reading pane is back to normal. Can anyone please tell me if there is something I can do in VBA to fix this annoying issue. Thanks a lot ...

Company Bulk Import fails with insufficient privileges error.
Environment: CRM 3.0 Rollup 3 IE 8.0 Windows XP Performing Import as System Administrator with full access to all objects. When I attempt to import companies using the Bulk Import Wizard I am able to go all the way through the mapping and start the import. It immediately fails with the following message: "You do not have enough privileges to access the Microsoft CRM objet or perform the requested operation. For more information, contact your system administrator". Issue - I am the system administrator! I only have one role assigned to me - system Administrator, not runni...

money runs very slowly
I have Money 2002 Deluxe and professional and it runs slower and slower all the time. Is there any way to get the software to run at the speed it used to? See http://www.bollar.org/msmoney/#Q4 -- Glyn Simpson, Microsoft MVP - Money Check http://support.microsoft.com/default.aspx?scid=fh;EN-GB;mny for UK tips and fixes for MS Money. To send Microsoft your wishes or suggestions, use http://register.microsoft.com/mswish/suggestion.asp or email mnyukwsh@microsoft.com especially if it's a UK specific wish. I do not respond to any unsolicited email regarding Money "Joe" <joe...

Calling on a macro within a macro!
Hey All!! Quick Question - How do you call up a macro within a current macro? I have one big macro and I need it to jump to several other macros when it runs! Does it matter where the other macros are stored or is it better to have them all in one module? Help appreciated Thnx! Hi Mellowe, '=============>> Public Sub Main() 'Your code Call One 'your code End Sub '<<============= '=============>> Public Sub One() MsgBox "Hi from One" End Sub '<<============= > Does it matter where the other macros are stored or ...

shortcut keys to macros
Hi, Is it at all possible to assign shortcut keys to macros in Outlook? Thx, Hans ...

Run a program through Outlook . . .
Dears, How to run a program from outlook? As example , i need to run Firefox in outlook. Thanks & Regards,, ...

Business Management Error Move CRM 4.0 Database to Different Machi
Hi, I have backed up a CRM 4.0 _MSCRM and MSCRM_Config database from one machine and restored both on another machine ( Which had been useing a test database). After restoring both databases on the new host I used the Deployment Manger to import the restored database. After completing the import when I attempt to open CRM I get an error message saying " Business Management Error The user ID associated the current record is not valid" From the server where I'm logged an as Administrator On client PC I get the following. Server Error in '/...

help Unable to record Macro !!!!!!!
I want to record a macro in excel.But as soon as I click record Macro it says "unable to record" macro. Got no help in excel help.I do this same thing in word and it's working. Please help It's urgent for me !!!1 Have a look here http://groups.google.com/groups?as_epq=unable%20to%20record&as_ugroup=microsoft.public.excel.* -- Don Guillett SalesAid Software donaldb@281.com "ash" <anonymous@discussions.microsoft.com> wrote in message news:3e0b01c42ae5$45333e00$a401280a@phx.gbl... > I want to record a macro in excel.But as soon as I click > record...

Macro that password protects a sheet
I am attempting to create a macro that can open a protected sheet, change something, and then protect it again. I continue to have an issue with the macro not entering the password. Is this possible to do/fix? Thanks, Ryan ..open password="mypassword" -- Don Guillett SalesAid Software donaldb@281.com "Ryan" <Ryan@discussions.microsoft.com> wrote in message news:D4780ED8-CA1D-4284-97BC-3576160D998E@microsoft.com... > I am attempting to create a macro that can open a protected sheet, change > something, and then protect it again. I continue to have an iss...

New symptom and one error message
I recently experienced the inability of Outlook (2002 SP) to download email messages from my server. I can see messages via web mail. Send receive tries to download and stops at the *0% mark. In addition, I can no longer delete individual messages. When I do this I get the following error message-"The message interface has eturned an unknown error. If the problem persists, restart Outlook." I restarted outlook, reinstalled outlook, reformated my hard drive and reinstalled operting system and Office 2002 XP. It worked on first try, but then reverted to problem described above....

How do I get the text from running off a page (have it skip to th.
I need to be able to have text skip from one cell down to the next row without it running off a page (hard return) Amy Not sure what you need here. If you want text to stop at a certain point in a cell then drop down to next cell below, just hit ENTER key whenever you choose. If you want the text on more than one line in a cell, you can hit ALT + ENTER to create a CR in the cell. Or just type it all in one cell then choose Wrap Text and widen the column. Gord Dibben Excel MVP On Fri, 15 Apr 2005 14:48:03 -0700, "Amy Maestas" <Amy Maestas@discussions.microsoft.com> wro...