Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 20
Default Saving a copy without incrementing number

hi
can someone help me - I have an invoice template which when opens increments
the invoice number in cell H16 by 1 each time.
Problem im having is that when i save as (to save a copy) when i reopen the
copy to veiw it - it carries on adding 1 to the invoice number.
Basically i only want the template to carry the incrementing number - not
the copy that i save from the template.
Could someone explain what it is i have to put in to stop it, and would this
be put into the workbook or a module - or in the same code as the
incrementing number?
Help would be appriciated Thankyou
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,819
Default Saving a copy without incrementing number

What is actually in Cell H16, a formula? Maybe try "copy, paste special,
value"

Pammi J wrote:

hi
can someone help me - I have an invoice template which when opens increments
the invoice number in cell H16 by 1 each time.
Problem im having is that when i save as (to save a copy) when i reopen the
copy to veiw it - it carries on adding 1 to the invoice number.
Basically i only want the template to carry the incrementing number - not
the copy that i save from the template.
Could someone explain what it is i have to put in to stop it, and would this
be put into the workbook or a module - or in the same code as the
incrementing number?
Help would be appriciated Thankyou


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 20
Default Saving a copy without incrementing number

Hi bob
in the cell H16 i put the initial starting invoice number 100, and in the
workbook code i put the following;

Private Sub Workbook_Open()
Sheet1.Range("H16").Value = Sheet1.Range("H16").Value + 1
End Sub

it works great on adding one to the invoice number each time i open the
template, but when i want to save a copy (save as) its saves as (example -
invoice number 101) but if i need to veiw that copy - when i open it i get
the `enable/disable macro`s box pop up` and it then adds one to the invoice
number - it shouldnt change on the saved copy. How do i put that right?

Pammi J

"Bob I" wrote:

What is actually in Cell H16, a formula? Maybe try "copy, paste special,
value"

Pammi J wrote:

hi
can someone help me - I have an invoice template which when opens increments
the invoice number in cell H16 by 1 each time.
Problem im having is that when i save as (to save a copy) when i reopen the
copy to veiw it - it carries on adding 1 to the invoice number.
Basically i only want the template to carry the incrementing number - not
the copy that i save from the template.
Could someone explain what it is i have to put in to stop it, and would this
be put into the workbook or a module - or in the same code as the
incrementing number?
Help would be appriciated Thankyou



  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,819
Default Saving a copy without incrementing number

Delete/disable the macro.

Pammi J wrote:

Hi bob
in the cell H16 i put the initial starting invoice number 100, and in the
workbook code i put the following;

Private Sub Workbook_Open()
Sheet1.Range("H16").Value = Sheet1.Range("H16").Value + 1
End Sub

it works great on adding one to the invoice number each time i open the
template, but when i want to save a copy (save as) its saves as (example -
invoice number 101) but if i need to veiw that copy - when i open it i get
the `enable/disable macro`s box pop up` and it then adds one to the invoice
number - it shouldnt change on the saved copy. How do i put that right?

Pammi J

"Bob I" wrote:


What is actually in Cell H16, a formula? Maybe try "copy, paste special,
value"

Pammi J wrote:


hi
can someone help me - I have an invoice template which when opens increments
the invoice number in cell H16 by 1 each time.
Problem im having is that when i save as (to save a copy) when i reopen the
copy to veiw it - it carries on adding 1 to the invoice number.
Basically i only want the template to carry the incrementing number - not
the copy that i save from the template.
Could someone explain what it is i have to put in to stop it, and would this
be put into the workbook or a module - or in the same code as the
incrementing number?
Help would be appriciated Thankyou




  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 20
Default Saving a copy without incrementing number

Bob
Is there a way of doing it without clicking the disable/enable macro popup
on opening. ie
fill out template with details
save as
then the copy would go away without carrying the template macro with it?

Then
when copy is opened for veiwing etc by other people - it would open exactly
as it was saved - with the same invoice number it was given when it was
filled in.

Pam

"Bob I" wrote:

Delete/disable the macro.

Pammi J wrote:

Hi bob
in the cell H16 i put the initial starting invoice number 100, and in the
workbook code i put the following;

Private Sub Workbook_Open()
Sheet1.Range("H16").Value = Sheet1.Range("H16").Value + 1
End Sub

it works great on adding one to the invoice number each time i open the
template, but when i want to save a copy (save as) its saves as (example -
invoice number 101) but if i need to veiw that copy - when i open it i get
the `enable/disable macro`s box pop up` and it then adds one to the invoice
number - it shouldnt change on the saved copy. How do i put that right?

Pammi J

"Bob I" wrote:


What is actually in Cell H16, a formula? Maybe try "copy, paste special,
value"

Pammi J wrote:


hi
can someone help me - I have an invoice template which when opens increments
the invoice number in cell H16 by 1 each time.
Problem im having is that when i save as (to save a copy) when i reopen the
copy to veiw it - it carries on adding 1 to the invoice number.
Basically i only want the template to carry the incrementing number - not
the copy that i save from the template.
Could someone explain what it is i have to put in to stop it, and would this
be put into the workbook or a module - or in the same code as the
incrementing number?
Help would be appriciated Thankyou






  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22,906
Default Saving a copy without incrementing number

Chip Pearson shows how to delete VBA modules and/or routines from a workbook
using code.

http://www.cpearson.com/excel/vbe.aspx

Perhaps you can work out a way to delete the code when the workbook is first
saved.


Gord Dibben MS Excel MVP

On Wed, 13 Feb 2008 03:26:02 -0800, Pammi J
wrote:

Bob
Is there a way of doing it without clicking the disable/enable macro popup
on opening. ie
fill out template with details
save as
then the copy would go away without carrying the template macro with it?

Then
when copy is opened for veiwing etc by other people - it would open exactly
as it was saved - with the same invoice number it was given when it was
filled in.

Pam

"Bob I" wrote:

Delete/disable the macro.

Pammi J wrote:

Hi bob
in the cell H16 i put the initial starting invoice number 100, and in the
workbook code i put the following;

Private Sub Workbook_Open()
Sheet1.Range("H16").Value = Sheet1.Range("H16").Value + 1
End Sub

it works great on adding one to the invoice number each time i open the
template, but when i want to save a copy (save as) its saves as (example -
invoice number 101) but if i need to veiw that copy - when i open it i get
the `enable/disable macro`s box pop up` and it then adds one to the invoice
number - it shouldnt change on the saved copy. How do i put that right?

Pammi J

"Bob I" wrote:


What is actually in Cell H16, a formula? Maybe try "copy, paste special,
value"

Pammi J wrote:


hi
can someone help me - I have an invoice template which when opens increments
the invoice number in cell H16 by 1 each time.
Problem im having is that when i save as (to save a copy) when i reopen the
copy to veiw it - it carries on adding 1 to the invoice number.
Basically i only want the template to carry the incrementing number - not
the copy that i save from the template.
Could someone explain what it is i have to put in to stop it, and would this
be put into the workbook or a module - or in the same code as the
incrementing number?
Help would be appriciated Thankyou





  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 20
Default Saving a copy without incrementing number

Hi Gord
I tried the code to delete the code i have in to increment the invoice
number by 1, but it just stops the whole template from working.
I think there is a code to pick up a incrementing number from a txt file
that i can make and save in the same folder as i save the invoice template.
Maybe that code would be a quicker better option for me?
Im a beginner.

Pam
"Gord Dibben" wrote:

Chip Pearson shows how to delete VBA modules and/or routines from a workbook
using code.

http://www.cpearson.com/excel/vbe.aspx

Perhaps you can work out a way to delete the code when the workbook is first
saved.


Gord Dibben MS Excel MVP

On Wed, 13 Feb 2008 03:26:02 -0800, Pammi J
wrote:

Bob
Is there a way of doing it without clicking the disable/enable macro popup
on opening. ie
fill out template with details
save as
then the copy would go away without carrying the template macro with it?

Then
when copy is opened for veiwing etc by other people - it would open exactly
as it was saved - with the same invoice number it was given when it was
filled in.

Pam

"Bob I" wrote:

Delete/disable the macro.

Pammi J wrote:

Hi bob
in the cell H16 i put the initial starting invoice number 100, and in the
workbook code i put the following;

Private Sub Workbook_Open()
Sheet1.Range("H16").Value = Sheet1.Range("H16").Value + 1
End Sub

it works great on adding one to the invoice number each time i open the
template, but when i want to save a copy (save as) its saves as (example -
invoice number 101) but if i need to veiw that copy - when i open it i get
the `enable/disable macro`s box pop up` and it then adds one to the invoice
number - it shouldnt change on the saved copy. How do i put that right?

Pammi J

"Bob I" wrote:


What is actually in Cell H16, a formula? Maybe try "copy, paste special,
value"

Pammi J wrote:


hi
can someone help me - I have an invoice template which when opens increments
the invoice number in cell H16 by 1 each time.
Problem im having is that when i save as (to save a copy) when i reopen the
copy to veiw it - it carries on adding 1 to the invoice number.
Basically i only want the template to carry the incrementing number - not
the copy that i save from the template.
Could someone explain what it is i have to put in to stop it, and would this
be put into the workbook or a module - or in the same code as the
incrementing number?
Help would be appriciated Thankyou






  #8   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22,906
Default Saving a copy without incrementing number

I'm not sure how to get around H16 updating without removing the code or
preventing it from running.

Hang in. I'll bet that one of the more VBA conversant persons will come up with
somrthing for you.


Gord

On Thu, 14 Feb 2008 04:01:01 -0800, Pammi J
wrote:

Hi Gord
I tried the code to delete the code i have in to increment the invoice
number by 1, but it just stops the whole template from working.
I think there is a code to pick up a incrementing number from a txt file
that i can make and save in the same folder as i save the invoice template.
Maybe that code would be a quicker better option for me?
Im a beginner.

Pam
"Gord Dibben" wrote:

Chip Pearson shows how to delete VBA modules and/or routines from a workbook
using code.

http://www.cpearson.com/excel/vbe.aspx

Perhaps you can work out a way to delete the code when the workbook is first
saved.


Gord Dibben MS Excel MVP

On Wed, 13 Feb 2008 03:26:02 -0800, Pammi J
wrote:

Bob
Is there a way of doing it without clicking the disable/enable macro popup
on opening. ie
fill out template with details
save as
then the copy would go away without carrying the template macro with it?

Then
when copy is opened for veiwing etc by other people - it would open exactly
as it was saved - with the same invoice number it was given when it was
filled in.

Pam

"Bob I" wrote:

Delete/disable the macro.

Pammi J wrote:

Hi bob
in the cell H16 i put the initial starting invoice number 100, and in the
workbook code i put the following;

Private Sub Workbook_Open()
Sheet1.Range("H16").Value = Sheet1.Range("H16").Value + 1
End Sub

it works great on adding one to the invoice number each time i open the
template, but when i want to save a copy (save as) its saves as (example -
invoice number 101) but if i need to veiw that copy - when i open it i get
the `enable/disable macro`s box pop up` and it then adds one to the invoice
number - it shouldnt change on the saved copy. How do i put that right?

Pammi J

"Bob I" wrote:


What is actually in Cell H16, a formula? Maybe try "copy, paste special,
value"

Pammi J wrote:


hi
can someone help me - I have an invoice template which when opens increments
the invoice number in cell H16 by 1 each time.
Problem im having is that when i save as (to save a copy) when i reopen the
copy to veiw it - it carries on adding 1 to the invoice number.
Basically i only want the template to carry the incrementing number - not
the copy that i save from the template.
Could someone explain what it is i have to put in to stop it, and would this
be put into the workbook or a module - or in the same code as the
incrementing number?
Help would be appriciated Thankyou







  #9   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default Saving a copy without incrementing number

Private Sub Workbook_Open()
if thisworkbook.path = "" then
'it's never been saved, so increment
Sheet1.Range("H16").Value = Sheet1.Range("H16").Value + 1
end if
End Sub

Pammi J wrote:

Hi bob
in the cell H16 i put the initial starting invoice number 100, and in the
workbook code i put the following;

Private Sub Workbook_Open()
Sheet1.Range("H16").Value = Sheet1.Range("H16").Value + 1
End Sub

it works great on adding one to the invoice number each time i open the
template, but when i want to save a copy (save as) its saves as (example -
invoice number 101) but if i need to veiw that copy - when i open it i get
the `enable/disable macro`s box pop up` and it then adds one to the invoice
number - it shouldnt change on the saved copy. How do i put that right?

Pammi J

"Bob I" wrote:

What is actually in Cell H16, a formula? Maybe try "copy, paste special,
value"

Pammi J wrote:

hi
can someone help me - I have an invoice template which when opens increments
the invoice number in cell H16 by 1 each time.
Problem im having is that when i save as (to save a copy) when i reopen the
copy to veiw it - it carries on adding 1 to the invoice number.
Basically i only want the template to carry the incrementing number - not
the copy that i save from the template.
Could someone explain what it is i have to put in to stop it, and would this
be put into the workbook or a module - or in the same code as the
incrementing number?
Help would be appriciated Thankyou




--

Dave Peterson
  #10   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22,906
Default Saving a copy without incrementing number

Absatively brilliant but so simple when seeing it in person<g

You my man!

Gord

On Thu, 14 Feb 2008 18:48:55 -0600, Dave Peterson
wrote:

Private Sub Workbook_Open()
if thisworkbook.path = "" then
'it's never been saved, so increment
Sheet1.Range("H16").Value = Sheet1.Range("H16").Value + 1
end if
End Sub

Pammi J wrote:

Hi bob
in the cell H16 i put the initial starting invoice number 100, and in the
workbook code i put the following;

Private Sub Workbook_Open()
Sheet1.Range("H16").Value = Sheet1.Range("H16").Value + 1
End Sub

it works great on adding one to the invoice number each time i open the
template, but when i want to save a copy (save as) its saves as (example -
invoice number 101) but if i need to veiw that copy - when i open it i get
the `enable/disable macro`s box pop up` and it then adds one to the invoice
number - it shouldnt change on the saved copy. How do i put that right?

Pammi J

"Bob I" wrote:

What is actually in Cell H16, a formula? Maybe try "copy, paste special,
value"

Pammi J wrote:

hi
can someone help me - I have an invoice template which when opens increments
the invoice number in cell H16 by 1 each time.
Problem im having is that when i save as (to save a copy) when i reopen the
copy to veiw it - it carries on adding 1 to the invoice number.
Basically i only want the template to carry the incrementing number - not
the copy that i save from the template.
Could someone explain what it is i have to put in to stop it, and would this
be put into the workbook or a module - or in the same code as the
incrementing number?
Help would be appriciated Thankyou





  #11   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default Saving a copy without incrementing number

Yeah, you say that until you see one of my screwups--then I can hear the
laughter!

Gord Dibben wrote:

Absatively brilliant but so simple when seeing it in person<g

You my man!

Gord

On Thu, 14 Feb 2008 18:48:55 -0600, Dave Peterson
wrote:

Private Sub Workbook_Open()
if thisworkbook.path = "" then
'it's never been saved, so increment
Sheet1.Range("H16").Value = Sheet1.Range("H16").Value + 1
end if
End Sub

Pammi J wrote:

Hi bob
in the cell H16 i put the initial starting invoice number 100, and in the
workbook code i put the following;

Private Sub Workbook_Open()
Sheet1.Range("H16").Value = Sheet1.Range("H16").Value + 1
End Sub

it works great on adding one to the invoice number each time i open the
template, but when i want to save a copy (save as) its saves as (example -
invoice number 101) but if i need to veiw that copy - when i open it i get
the `enable/disable macro`s box pop up` and it then adds one to the invoice
number - it shouldnt change on the saved copy. How do i put that right?

Pammi J

"Bob I" wrote:

What is actually in Cell H16, a formula? Maybe try "copy, paste special,
value"

Pammi J wrote:

hi
can someone help me - I have an invoice template which when opens increments
the invoice number in cell H16 by 1 each time.
Problem im having is that when i save as (to save a copy) when i reopen the
copy to veiw it - it carries on adding 1 to the invoice number.
Basically i only want the template to carry the incrementing number - not
the copy that i save from the template.
Could someone explain what it is i have to put in to stop it, and would this
be put into the workbook or a module - or in the same code as the
incrementing number?
Help would be appriciated Thankyou



--

Dave Peterson
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to stop formulas from incrementing when you copy and paste? Kirkwill Excel Worksheet Functions 2 May 10th 23 07:45 PM
Automatically incrementing number for each print Nefermet Excel Worksheet Functions 7 January 8th 09 11:10 AM
Copy cells from one worksheet and paste to incrementing sheets? [email protected] Excel Discussion (Misc queries) 2 February 19th 07 11:35 AM
Incrementing a formula by X number Bowbender Excel Worksheet Functions 3 September 21st 05 04:14 PM
How do you copy a formula without incrementing some constants? JohnT Excel Worksheet Functions 2 February 18th 05 11:09 AM


All times are GMT +1. The time now is 03:47 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"