Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 88
Default POInv macro w/ if then statement

code works, thank you

jat


"Roger Govier" wrote:

Hi

You could use something like
Range("M7") = Format(date, "dd mmm yyyy")

Date in VBA will return the current date.

If you made your PO a Template, rather than a .xls file, you could save
yourself the task of

- cleans the purchase order back to original state
- saves the new blank po



--
Regards

Roger Govier


"jatman" wrote in message
...
i have a macro that runs when i press the big button (macro is in
module).
macro does the following:
- saves a copy of the purchase order based on the po number and date
stamp
- saves a copy on the hard drive
- emails a copy to accounts payable
- prints a copy for the actual invoice
- cleans the purchase order back to original state
- increases the po number by 1
- saves the new blank po

the date cell contains "[Ctrl] ;" - i want them to use that so the
date is
entered in a preformatted condition and cannot be incorrect

i used the following code at the start of the macro
If .Range("M7") < "[Ctrl] ;" Then
with End If at the end of the macro, but it does not work.

is there any other way to enter the current date into the macro so
that M7
self populates when the macro is run.

- the code =today() cannot be used because the copy stored on the hard
drive
keeps updating itself when the file is opened.

regards

jat




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
If then for POInv macro jatman Excel Programming 1 September 2nd 06 07:01 AM
If statement in macro punter Excel Discussion (Misc queries) 3 June 20th 06 12:23 PM
how can i use an if statement to run a macro? Jack Excel Programming 2 March 4th 05 12:21 AM
HELP w/ Macro and IF Statement randy_tn Excel Programming 1 November 3rd 04 01:49 AM
Macro or IF statement??? HELP! Julia Easter Excel Programming 8 May 26th 04 03:52 PM


All times are GMT +1. The time now is 04:52 PM.

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

About Us

"It's about Microsoft Excel"