PC Review


Reply
Thread Tools Rate Thread

creatin new sheet macro

 
 
=?Utf-8?B?Q2FsbGU=?=
Guest
Posts: n/a
 
      18th Oct 2006
Hi!
Is it possible to have a macro that creat a new sheet and puts it first in
the workbook like this:

I have one sheet named: kvartal1
The macro creats a sheet named kvartal2. If I run it again it creats
kvartal3... and so on.
 
Reply With Quote
 
 
 
 
WhytheQ
Guest
Posts: n/a
 
      18th Oct 2006
This might work for you:

'+++++++++++++++++++++++++
Dim mySheet As Worksheet
Set mySheet = Sheets.Add(Sheets(1))
mySheet.Name = "Kvartal" & Sheets.Count
'+++++++++++++++++++++++++

Rgds
J

On Oct 18, 1:36 pm, Calle <C...@discussions.microsoft.com> wrote:
> Hi!
> Is it possible to have a macro that creat a new sheet and puts it first in
> the workbook like this:
>
> I have one sheet named: kvartal1
> The macro creats a sheet named kvartal2. If I run it again it creats
> kvartal3... and so on.


 
Reply With Quote
 
=?Utf-8?B?Q2FsbGU=?=
Guest
Posts: n/a
 
      18th Oct 2006
hi!
it get named "kvartal 10" since I also have many other sheets. Any other
suggestion

Regards Calle
 
Reply With Quote
 
Tom Ogilvy
Guest
Posts: n/a
 
      19th Oct 2006
Dim mySheet As Worksheet
Set mySheet = Sheets.Add(Sheets(1))
mySheet.Name = "Kvartal" & Sheets.Count - 9

--
Regards,
Tom Ogilvy


"Calle" <(E-Mail Removed)> wrote in message
news:8334BF93-3854-4662-83A9-(E-Mail Removed)...
> hi!
> it get named "kvartal 10" since I also have many other sheets. Any other
> suggestion
>
> Regards Calle



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Creatin a Macro =?Utf-8?B?Q2hlc3RlcjE=?= Microsoft Access Macros 0 8th Jun 2007 01:49 PM
Stop Excel creatin Duplicate contacts =?Utf-8?B?QWxhcm1ibG9rZQ==?= Microsoft Excel Discussion 0 7th Apr 2006 08:08 PM
creatin borders on a Word document =?Utf-8?B?T2xsYWthbA==?= Microsoft Word Document Management 4 31st Mar 2005 07:15 PM
Re: international day of freeware ? a day to thank someone for creatin BEN.RITCHEY@family-news.org Freeware 19 17th Feb 2005 12:04 AM
how do i sort my contacts folders alphabetically when i'm creatin. =?Utf-8?B?Z2lkZHl1cA==?= Microsoft Access 1 8th Feb 2005 01:24 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 05:47 AM.