MrExcel Message Board

Go Back   MrExcel Message Board > Question Forums > Excel Questions

Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only.

Reply
 
Thread Tools Display Modes
Old Apr 3rd, 2002, 07:32 AM   #1
pilot
Board Regular
 
Join Date: Feb 2002
Location: Houston, TX
Posts: 303
Default

I maintain personnel information in 3 workbooks with some commonalities. To simplify maintenance and make this easier to share with other users, many of whom are Excel neophytes, I am considering combining everything into one wb and using topical worksheets to control what is visible.

Currently, each wb has a ws named with the employee's first name. Items tracked include absence & attendance codes and notes, employee information, salary history and leave usage. As an example, I'm thinking of creating a control worksheet named Leave that would be blank but house code to hide all worksheets except those containing leave records (and the other control worksheets).

This is more of a "big picture" question than a detailed "how do I", but is there a better way of going about this?

[ This Message was edited by: pilot on 2002-04-03 06:56 ]
pilot is offline   Reply With Quote
Old Apr 3rd, 2002, 09:34 AM   #2
Damon Ostrander
MrExcel MVP
 
Damon Ostrander's Avatar
 
Join Date: Feb 2002
Location: Denver, Colorado USA
Posts: 4,014
Default

Hi Pilot,

This could be done, but in order to really protect each employee's information from others would require a lot of attention to detail. My initial reaction on reading what you want to do was "fear and trepidation", even as an experienced VBA programmer. I think it would be easier to maintain security if you use separate workbooks for each employee. I assume each employee has a password for accessing his/her data? With separate workbooks, the operating system's file access permission system could be used to protect each employee's data from others.

Another immediate reaction was that this is something that might be better accomplished via a real database application, such as Access.
__________________
Keep Excelling.

Damon

VBAexpert Excel Consulting
(My other life: http://damonostrander.com )
Damon Ostrander is offline   Reply With Quote
Old Apr 3rd, 2002, 09:57 AM   #3
pilot
Board Regular
 
Join Date: Feb 2002
Location: Houston, TX
Posts: 303
Default

This is for my own use only, not to be accessed by my employees. I wouldn't have to worry about lots of others having password access. The other users I referred to are other managers in the organkzation who want to use my files as templates for tracking their own people. You're right, Access would probably be better but I've done very little in that program. The reason all employees are in one wb is to make it simpler on me, and to make summary and comparison worksheets easier. Appreciate your comments.
pilot is offline   Reply With Quote
Old Apr 3rd, 2002, 03:42 PM   #4
Jack in the UK
Board Regular
 
Join Date: Feb 2002
Posts: 3,064
Default

Hi

To add, any security in Excel is weak and huys like me take much fun ripping the codes, passwords and protection apart just for the shear fun of it and trying to find what you hide,, even if nothing at all really, tyhsi advanced users can do in a few minutes, Excel i love but security is all but not there. BE CAREFUL....



__________________
Free Excel based Web Toolbar available here.

Jack in the UK
J & R Excel Solutions
"making Excel work for you"
Jack in the UK is offline   Reply With Quote
Old Apr 4th, 2002, 12:32 AM   #5
Damon Ostrander
MrExcel MVP
 
Damon Ostrander's Avatar
 
Join Date: Feb 2002
Location: Denver, Colorado USA
Posts: 4,014
Default

Hi again Pilot,

Since you are not concerned with security, a single workbook is probably a pretty good way to keep all the information in one place, as you say. If you want to hide information just for the sake of giving each user only the information he/she needs without distractions, this is easy to do. As an example of the type of thing you can do, if each user will be accessing the file from their own computer, you can access their names (either their NT login name or their MS Office registered name) as a basis for deciding which sheets to make visible so that it looks to each user like a file that contains information of interest only to him/her. It can also be set up so that the hidden sheets do not show up on the Format -> Sheet -> Hide/Unhide menu and can only be hidden/unhidden by an interface you provide, such as a button on a worksheet or a custom userform, etc. This is done from VBA by assigning the worksheet's Visible property the value xlVeryHidden.

Happy computing.

Damon
Damon Ostrander is offline   Reply With Quote
Old Apr 4th, 2002, 06:46 AM   #6
pilot
Board Regular
 
Join Date: Feb 2002
Location: Houston, TX
Posts: 303
Default

Just a couple more clarifying comments. On security, I know Excel is one of "the weakest links". The file(s) reside on my personal space on our network so it is invisible to anyone else (who hasn't cracked our network, and its security is quite high). Given, the network admin folks can see and invade if they really wanted. That's a risk I'm willing to accept. Other users, especially my employees, would never be accessing this file(s). Any hiding of sheets would only be to make navigation easier for myself. In other words, when posting leave that has been taken, I don't need to see salary history.
pilot is offline   Reply With Quote
Old Apr 4th, 2002, 07:11 AM   #7
Joe Was
MrExcel MVP
 
Joe Was's Avatar
 
Join Date: Feb 2002
Location: Central Florida, USA
Posts: 7,541
Default

You may want to try the built-in Excel Data Form for managing an Excel database. On the pull-down menu it is Data-Form...

The code below will work with a table that is on the same sheet as the navagation menu. I use buttons and Photo objects that act as buttons to activate the code below. For your data table I start in AA1 with cells labled as text and lable the fields (AA1,AB1,AC1...)then load the table with at least one data element in AA2 (A dummy like: "First Record" or 1, anything will work.) this sets the table for the data-form defalts. The Data-Form will use your column lables as the forms field lables. It all works very slick. The code below uses the Sendkeys command to activate or use the Data-Form.

Note Data forms can display a maximum of 32 fields at one time. You can only have one Data-List per sheet, but you may have many sheets in a workbook. JSW

Sub DBForm()
'Macro made; 12/13/2001, By: Joe Was.
'Keyboard Shortcut: Ctrl+b.
'Runs the DataBase input Form.

'Calibrate screen for scroll to DataBase-Data-Table.
Sheets("Menu").Select
Range("A1").Select
ActiveWindow.SmallScroll ToRight:=13

'Select first DataBase record.
Range("AA2").Select

'Clean Screen and show Default Data Form.
ActiveWindow.ScrollColumn = 1
SendKeys "%do"

End Sub


Sub myExit()
'Exit the database form.
SendKeys "%fx"
End Sub


Sub myClose()
'Close the datbase form.
SendKeys "%fc:"
End Sub


Sub myPrint1()
'Print the data table.
Dim Msg, Style, Title, Help, Ctxt, Response, MyString

Msg = "Print Data Now?" ' Define message.
Style = vbOKCancel ' Define buttons.
Title = "Ready to Print?" ' Define title.
'Help = "DEMO.HLP" ' Define Help file.
'Ctxt = 1000 ' Define topic
' context.
' Display message.
Response = MsgBox(Msg, Style, Title)
If Response = vbOK Then ' User chose Yes.
Columns("AA:AI").Select
ActiveSheet.PageSetup.PrintArea = "$AA:$AI"
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
ActiveWindow.ScrollColumn = 1
Else ' User chose No.
GoTo Can
End If
End
Can:

End Sub

Sub mySave()
'Save this workbook.
ActiveWorkbook.Save
End Sub

Sub VDBT()
'Move to the data table.
Range("AA2").Select
End Sub

Sub MainView()
'Return to the navagation menu.
ActiveWindow.ScrollColumn = 1
End Sub



[ This Message was edited by: Joe Was on 2002-04-04 06:25 ]
Joe Was is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump


All times are GMT -4. The time now is 10:21 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2012, vBulletin Solutions, Inc.
All contents Copyright 1998-2012 by MrExcel Consulting.
diabetic desserts recipes recipes Diabetic Soups Holiday Pizza Recipes Popcorn Recipes Recipes For Microwave Pasta Recipes Casserole Recipes Chili Recipes Curry Recipes Crockpot Recipes Apples Recipes Bread Recipes Vegetarian Recipes Vegetable recipes Desserts Recipes Appetizers Ethnic Recipes Meat Dishes Barbecue Recipes Sauces Recipes Marinade Recipes Low Fat Recipes Frugal Gourmet Kitchen Classics Recipes On The Grill Cook Books Seafood Recipes Cajun Recipes Breads Low Fat Low Fat Breads Bread Machine Recipes Yeast Breads Quick Breads Fat Free Vegetarian Salad Recipes Eggplant Recipes Radish Recipes Tomato Recipes Jalapeno Recipes Potato Recipes Lettuce Recipes Cabbage Recipes Beans Ambrosia Recipes Biscotti Recipes Desserts Low Fat Cookie Recipes Cheesecake Recipes Cake Recipes Pie Recipes Muffin Recipes Custard Recipes Best Appetizers Appetizers Low Fat Salsa Recipes Dip Recipes International Recipes Afghan Recipes Alaska Recipes French Recipes German Recipes Greek Recipes Italian Recipes Spanish Recipes Thai Recipes Korean Recipes Chinese Recipes Mexican Recipes Indian Recipes Beef Recipes Pork Pork & Ham Pork Butts Pork Chop Recipes Pork Ribs Rulled Pork Poultry Recipes Stews Recipes Ground Beef Barbecue Grill Barbecue Smoker All Purpose Sauce BBQ Sauce Barbecue Sauce Carolina BBQ Sauce Pickle Recipes Marinades Smoking Low Fat Appetizers & Dips Low Fat Breakfast Low Fat Cakes Low Fat Cheesecakes Low Fat Cookies Low Fat Desserts Low Fat Fish & Seafood Low Fat Meats Low Fat Pasta Low Fat Pies Low Fat Salads Low Fat Sandwiches Low Fat Sauces & Condiments Low Fat Sides Low Fat Soups Low Fat Vegetarian Baker's Dozen Taste of Home Recipe Book Bon Appetit Cookbook Blacktie Cookbook Buster Cook Book Cookbook USA Cook Book Cook Book Sara's Cookbook Sara's Cookbook Appetizers and Dips Poultry recipes Diabetic recipes Holiday recipes Miscellaneous recipes 110 recipes 1986 Usenet cookbook 2900 recipes Cyberrealm recipes Great sysops of world Specialty recipes Ceideburg recipes Cheese recipes Chili recipes Fruits recipes Garlic recipes Great chefs of NY Londontowne recipes Raisins recipes Recipes for kids US Food Vegetarian recipes Bread recipes Drinks Meat Dishes Brisket recipes Caribou recipes Chicken recipes Filet mignons recipes Pork recipes Swordfish recipes Turkey recipes Pasta recipes Uncategorized recipes Ethnic recipes Canada recipes English recipes Ethiopia recipes Germany recipes Greece recipes Mexican recipes Philippines recipes Welsh recipes Microwave recipes Soups recipes Vegetable recipes Asparagus recipes Barley recipes Brown rice recipes Lentil recipes Mushrooms recipes Salads recipes Wild rice Desserts recipes Cakes recipes Chocolate recipes Cookies recipes Ice cream recipes