Trying to use VBA
Hey BB (Funny, that's what I usually call my Big Brother ;) )
You can add following code to your Button:
'-----------------------------------------------
dim MyRange as range
dim Value_ as Double
Set MyRange = worksheets("Sheet1").range("A1")
'this has to be changed to your specific sheet and range
Value_ = MyRange.value + 1
MyRange.value = Value_
'-----------------------------------------------
For the other Problem, I would make an unprotected cell where you can
enter your "code" and in the other cells you can enter a vlookup
formula.
Of course you could also make a userform, but I think that would go
too far.
If you have a question to the above mentioned or to something else,
just ask...i will keep an eye on this thread.
Carlo
PS: When posting, try to include your Excel version and code if you
already have, that way we can easier see where you need help.
On Dec 25, 10:04*am, BB wrote:
Hello,
I'm attempting to use VBA, and am wanting to create a purchase order.
I have a sheet which is a stocklist, containing a 'code' (numbers and
letters) column, description column, cost price, sell price and quantity in
stock. *I also have a supplier sheet, which has a 4 letter supplier code,
supplier name, address, phone and email, all in seperate columns. *On my
purchase order, i want to create a button (have succeeded there...) which
when pressed changes the purchase order number, consecutively, starting from
say 10001 (have failed so far...). *Also, want to enter the company code, and
have their name and phone number appear. *Then, I have a boxed area, and
under the "code" heading, i will enter the appropriate code, and i want the
description and cost price to appear, under their appropriate column
headings, this may be several pages long, and i want to have it total at the
end. *In most cases i will then print this page/pages out and fax to the
relelvant supplier.
Have set myself a big task, i fear, however, does anyone have any hints on
where to start??? *Any help would be greatly appreciated.
Merry Christmas.
|