473,395 Members | 1,968 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Access rights!!!!

52
hi,
im trying to create access rights on my project. i have a form with check boxes so when ticked it will dissable the user from having access to that area, i am using a list box with this so you can select the access rights for different users. the thing is i keep getting problems. this is my list code:

LISTBOX
Expand|Select|Wrap|Line Numbers
  1. rs2.FindFirst "StaffID=" & Str(List1.ItemData(List1.ListIndex))
  2.  
  3. Text1.Text = rs2!StaffID
  4. chkStaff.Value = rs!Staff
  5. chkBooking.Value = rs!Booking
  6. chkStock.Value = rs!Stock
  7. chkIncome.Value = rs!Income
  8. chkPayment.Value = rs!Payment
  9. chkLogin.Value = rs!Login
  10. chkContact.Value rs!Contact
  11. Text1.Text = rs!User
  12.  
FORMLOAD

Expand|Select|Wrap|Line Numbers
  1. Dim db As Database
  2. Dim rs As Recordset
  3. Dim rs2 As Recordset
  4. Dim db2 As Database
  5. Form_load
  6.     Set db2 = OpenDatabase("E:\skol\A2 Computing\Speedy Pizza database.mdb")
  7.     Set rs2 = db2.OpenRecordset("Staff", dbOpenDynaset)
  8. If Not rs2.EOF Then rs2.MoveFirst
  9.  
  10. Do While Not rs2.EOF
  11.     List1.AddItem rs2!StaffID
  12.     List1.ItemData(List1.NewIndex) = rs!StaffID
  13.     rs.MoveNext
  14. Loop
  15.  
  16.     Set db = OpenDatabase("E:\skol\A2 Computing\Password.mdb")
  17.     Set rs = db.OpenRecordset("Access_Rights", dbOpenDynaset)
  18. If Not rs.EOF Then rs.MoveFirst
  19.  
  20. Do While Not rs.EOF
  21.     rs.MoveNext
  22. Loop
  23.  
im trying to get info from one table add some info from another table and save this on a new table. I keep getting the error "object variable or with block not set"
can you please help. Can anyone think of an SQL statement that i can use.
THANK YOU
Feb 9 '08 #1
3 1064
Bum
19
are you adding a reference to the Microsoft Office [version] Access Library?
Feb 14 '08 #2
THEAF
52
are you adding a reference to the Microsoft Office [version] Access Library?
Sorry but i don't get what your sayin.
are you sayin if im using the reference Microsoft Office Access Library or somfing.
Feb 15 '08 #3
lotus18
866 512MB
At which line do you get an error?
Feb 15 '08 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Markus Stehle | last post by:
Hi all! Within my web applikation I would like to centrally manage page access rights. Users of my web application belong to certain departments and have certain roles. The departments and roles...
5
by: jannordgreen | last post by:
I use windows 2000 and Visual Studio 2003. I have a vbnet web application on our intranet that needs to read a text file that sits on a different server. The general user does not have access to...
0
by: Jay | last post by:
Hey There, I was able to change the access rights to a file through adding an ACE to the DACL of a file. I have two questions that I am still trying to get resolved regarding this: 1). When I...
1
by: Thomas Strauss, SRS | last post by:
Hi, I have a really hard time to find the access rights required for monitoring a printing queue or share in windows XP or Win2000/2003 server. We have an application that will remote control...
2
by: Marcus | last post by:
I want to set file access rights in c++. First time my application is run it is run by a Windows administrator. This run creates some files that I want all users of that local computer to be...
1
by: kalpesh | last post by:
hey i want to create a named pipe with FILE_CREATE_PIPE_INSTANCE access rights. for that i have to create one security discriptor but i dont which type of secirity discriptor i use to cerate...
7
by: Jurjen de Groot | last post by:
I'm developping a web-app using VS2008 (Pro edition) on a Vista Ultimate machine .. For some reason images aren't shown, the only thing shown is the little square with the circel, triangle and...
1
by: pechar | last post by:
Hi guys, I have a Content Management System (CMS) which will be used by clients to update their site. The CMS has multiple users. What I'd like to implement is access rights. Some users are not...
0
by: Samuel R. Neff | last post by:
I'm having trouble creating a Semaphore with read-access rights for everyone. Originally I was trying to use this code: semaphore = new Semaphore(maxLocks, maxLocks, "RwLock#" + name); but...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.