I have absolutely no idea where to start

B

Bill Burke

Hello,

I am a newbie with VBA. I do okay with VBS. I have a large Excel spreadsheet
that I need to update and would love to use a VBA GUI to do it - but I have
absolutely no idea where to start.

All suggestions will be greatly appreciated.

TIA,
Bill Burke
(e-mail address removed)
 
R

Rob van Gelder

Hello World:

From Visual Basic Editor: Insert | Module

Type the following into the new window:
Sub mysub()
MsgBox "hello world"
End Sub

click the word 'test' then click the Play button (or press F5)

The module is generally where all code goes. Start playing and using the
Help. Click on a word and press F1 to get help on it. eg. Click MsgBox and
press F1.

Once you've got the hang of things, start using "Option Explicit" - you'll
save yourself a lot of time and bugs.
 
M

mudraker

Bill your post is lacking details of what you are wanting to acheive. N
details = no hel
 
B

Bill Burke

The spreadsheet is an inventory of +200 servers. I was able to piece together
partial information from serveral other sources, the rest I've gotten from doing
a physical inventory. I would like to create a GUI that automatically generates
a dropdown box (list box) from the values in one column. I would then like to
have several text boxes in the GUI that are associated with certain fields in
the spreadsheet. I would like to enter the data obtained from the physical
inventory into the appropriate text box then save the info to the spreadsheet.

TIA,
Bill Burke
 
C

count

Hi Bill,
It sounds like you can achieve what you need without touching VBA.
Features you can use are: Data Validation using Named Ranges, AutoFilters,
Recording Macro, Hiding Unhiding Columns, Changing Column Width and Sort

If this sounds cryptic, below is detailed expl. Also use Help on capitalized
words above
1. In empty sheet type in your values in column "A": a dozen manufacturers,
a few processor types, departments, floors, operating systems etc - one such
group under another, with a few blank rows between. This sheet you can call
Parms
2. Select one such group; extend perhaps by one row more at bottom
3. In a top left rectangular, where normally A1 etc appears type, say,
Manufacturers and hit Enter. You just created Named Range. Repeat for all
groups, give meaningful names.
4. In your main sheet, where you already have data for eventual filling in:
select a column of data, where 'policing' should occur, go menu
Data...Validation. In dialog box choose List and in the box below
type equal sign followed by Named Range e.g. =Manufacturers. Your main sheet
should now offer drop down list in relevant cells.
5. To view only some type data on the sheet use
menu..Data...Filter...Autofilter. Play with it.
6. Adjust the width of columns, hide and unhide them to present type of info
you want. E.g. hide most columns to show just AssetNo, Department, Operating
System - you can print such lists.
7. Switch on menu...Tools...Macros...Record New Macro while you manipulate
your columns. If you give macro a meaningful name it'll make life easier.
Your recorded macros can be assigned to toolbars and Menu.

Good luck!
BTW a glimpse of VBA you get after recording a macro: hit Alt+F11 and open
Module1 tree. You will see what code is generated from your column
manipulations. If you have full Office installed then Help will work.
highlight any word in code and hit F1. Use See Also blue link to surf the
VBA world.
HTH somebody :)
Paul


U¿ytkownik "Bill Burke said:
The spreadsheet is an inventory of +200 servers. I was able to piece together
partial information from serveral other sources, the rest I've gotten from doing
a physical inventory. I would like to create a GUI that automatically generates
a dropdown box (list box) from the values in one column. I would then like to
have several text boxes in the GUI that are associated with certain fields in
the spreadsheet. I would like to enter the data obtained from the physical
inventory into the appropriate text box then save the info to the spreadsheet.

TIA,
Bill Burke
 
C

CAA

'Owdoo Bill

If you can find your way around VBS then VBA is very similar, there ar
few limitations such as drawings and a few more noticeabl
differances, such as a whopping big worksheet that is like a huge arra
which can hold all sorts of information and formulas. which by the wa
you can add shapes and lines in.

The help in VBA is different to the Help in Excel, get to know th
excel enviroment and in vba help, how to write to cells and ranges
most of the other code is very much like VBS although there are quite
few inbuilt functions within excel at your disposal.

But where to start.. well HERE has got to be the BEST place ever,
have had so much help just reading the past posts, also do a googl
groups search for something you need to familiarize yourself with, th
archives go way back.
theres also http://www.exceltip.com. Has a really good excel vibe t
it with lots of tips.

Books, probably a good beginner one is Excel power programming by joh
Walkenbach, However there are some very knowlegeable & may i ad
extremely helpful people here.

Good luck,

& if you ever get stuck..
you know eher to come..

CA
 

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