How to edit the Maco code??

J

Jess

I want to create a macro so that when i select a button ti comes up asking me
to enter the information shownn in the macro and then puts it into choosen
cells?? Does anyone no how to edit this macro so that it actaully works? For
my AS level CW??? Any help woudl be good thnx. The beggining line is
highlited yellow??

Sub InsertNewProduct()
' add a new product
'

'
Application.Run "BikeProject.xls!InsertNewLine"

ActiveCell = Application.InputBox("Enter the new stock reference", "Stock
Reference", , , , , 2)

ActiveCell.Offset(0, 1).Range("A1").Select
ActiveCell = Application.InputBox("Enter the new product type", "Product
Type", , , , , 2)
ActiveCell.Offset(0, 1).Range("A1").Select
ActiveCell = Application.InputBox("Enter the new product manufacturer:",
"Product Manufacturer", , , , , 2)

ActiveCell.Offset(0, 1).Range("A1").Select
ActiveCell = Application.InputBox("Enter new product colour", "Product
Colour", , , , , 2)

ActiveCell.Offset(0, 1).Range("A1").Select
ActiveCell = Application.InputBox("Enter the new product cost", "Product
cost", , , , , 2)
ActiveCell.Offset(1, -4).Range("A1").Select
End Sub
 
J

Jim Aksel

Please post your question to the Excel newsgroup. This newsgroup is
dedicated to Microsoft Project, a scheduling application.
--
If this post was helpful, please consider rating it.

Jim Aksel, MVP

Check out my blog for more information:
http://www.msprojectblog.com
 
J

JulieS

Hello Jess,

This newsgroup is for Microsoft Project. Please repost your question
to a newsgroup for Excel. I suggest also posting information about
the version of Excel you are using.


Julie
Project MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top