473,769 Members | 7,584 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Error accessing the system registry

3 New Member
I installed Office 2000 Professional onto a Windows Vista laptop and when I tried to compile the code the following error message appears:

'User-Defined type not defined'

I went to check the registry and the following message appears:

'Error accessing the system registry'.

I have tied to repair Access using the Office 2000 repair facility but no luck.

Do you have any suggestions on this problem.

Thank you
May 19 '07 #1
7 13629
ADezii
8,834 Recognized Expert Expert
I installed Office 2000 Professional onto a Windows Vista laptop and when I tried to compile the code the following error message appears:

'User-Defined type not defined'

I went to check the registry and the following message appears:

'Error accessing the system registry'.

I have tied to repair Access using the Office 2000 repair facility but no luck.

Do you have any suggestions on this problem.

Thank you
Post the code that you were attempting to compile.
May 19 '07 #2
Cogito
3 New Member
I forgot to mention that error occurs when I try to look at the references in the Visual Basic window.

Here is a sample of the code. There is no problem with it on an XP laptop.
Expand|Select|Wrap|Line Numbers
  1. Option Compare Database
  2. Option Explicit
  3.  
  4. Private Sub cboProperty_AfterUpdate()
  5.  
  6. Me.cboFlat.Requery
  7.  
  8. End Sub
  9.  
  10. Private Sub cmdClose_Click()
  11.  
  12. On Error GoTo Err_cmdClose_Click
  13.  
  14. DoCmd.OpenForm "frmMainMenu", acNormal
  15. DoCmd.Close acForm, "frmReports"
  16.  
  17. Exit_cmdClose_Click:
  18.     Exit Sub
  19.  
  20. Err_cmdClose_Click:
  21.     MsgBox Err.Description
  22.     Resume Exit_cmdClose_Click
  23.  
  24. End Sub
  25.  
  26. Private Sub cmdLabelP1_Click()
  27.  
  28.  
  29. DoCmd.OpenReport "rptOwners_Labels", acViewPreview
  30. DoCmd.RunMacro "mrToolbar.ShowPrintTool"
  31. End Sub
  32.  
  33. Private Sub cmdLabelP2_Click()
  34.  
  35. DoCmd.OpenReport "rptOwners_Labels_P2", acViewPreview
  36. DoCmd.RunMacro "mrToolbar.ShowPrintTool"
  37. End Sub
  38.  
  39. Private Sub cmdPrint_Click()
  40.  
  41. Dim Msg As String, Msg2 As String, Response As String, Style As String
  42.  
  43. Msg = "There are no Arrears for " & "" & Forms![frmReports].[cboProperty].Column(1)
  44. Style = vbOKOnly + vbInformation + vbDefaultButton1
  45.  
  46. Msg2 = "There are no Outstanding Actions for " & "" & Forms![frmReports].[cboProperty].Column(1)
  47.  
  48. On Error GoTo Err_cmdPrint_Click
  49.  
  50. If Me.lstReports = "rptInvoice" Then
  51.     DoCmd.SetWarnings False
  52.     DoCmd.OpenQuery "qupdInvoicesPrinted"
  53.     DoCmd.SetWarnings True
  54. End If
  55.  
  56. If Me.lstReports = "rptServiceChargeArrearsRpt" Then
  57.     DoCmd.SetWarnings False
  58.     DoCmd.OpenQuery "qdelServiceChargeArrearsTotal"
  59.     DoCmd.OpenQuery "qappServiceChargeASrrearsTotalCY"
  60.     DoCmd.OpenQuery "qappServiceChargeASrrearsTotalPY"
  61.     DoCmd.SetWarnings True
  62. End If
  63.  
  64. If Me.lstReports = "rptInvoiceArrears" And IsNull(DLookup("[PropertyID]", "qselInvoicesArrearsRpt")) Then
  65.     Response = MsgBox(Msg, Style)
  66.     If Response = 1 Then
  67.         GoTo 10
  68.     End If
  69. End If
  70.  
  71. If Me.lstReports = "rptGroundRentArrears" And IsNull(DLookup("[PropertyID]", "qselGroundRentArrears")) Then
  72.     Response = MsgBox(Msg, Style)
  73.     If Response = 1 Then
  74.         GoTo 10
  75.     End If
  76. End If
  77.  
  78. If Me.lstReports = "rptPropertyActions" And IsNull(DLookup("[PropertyID]", "qselPropertyAction")) Then
  79.     Response = MsgBox(Msg2, Style)
  80.     If Response = 1 Then
  81.         GoTo 10
  82.     End If
  83. End If
  84. 'rptPropertyActions
  85. DoCmd.OpenReport Me.lstReports, acViewPreview
  86. DoCmd.RunMacro "mrToolbar.ShowPrintTool"
  87.  
  88. 10
  89.  
  90. Exit_cmdPrint_Click:
  91.     Exit Sub
  92.  
  93. Err_cmdPrint_Click:
  94.     MsgBox Err.Description
  95.     Resume Exit_cmdPrint_Click
  96.  
  97. End Sub
  98.  
  99.  
  100.  
  101. Private Sub Command17_Click()
  102.  
  103. DoCmd.OpenReport "rptOwners_Labels_FH_P2", acViewPreview
  104. DoCmd.RunMacro "mrToolbar.ShowPrintTool"
  105. End Sub
  106.  
  107. Private Sub Command18_Click()
  108.  
  109. DoCmd.OpenReport "rptOwners_Labels_FH_P1", acViewPreview
  110. DoCmd.RunMacro "mrToolbar.ShowPrintTool"
  111. End Sub
  112.  
  113. Private Sub Form_Open(Cancel As Integer)
  114. On Error GoTo Err_Form_Open
  115.  
  116. DoCmd.Maximize
  117.  
  118. Me.cboFlat.Visible = False
  119. Me.cboProperty.Visible = False
  120. Me.cboYear.Visible = False
  121. Me.cboHalfYear.Visible = False
  122.  
  123. Exit_Form_Open:
  124.     Exit Sub
  125.  
  126. Err_Form_Open:
  127.     MsgBox Err.Description
  128.     Resume Exit_Form_Open
  129.  
  130. End Sub
  131.  
  132. Private Sub lstReports_Click()
  133.  
  134. If Me.lstReports = "rptContactProperty" Or Me.lstReports = "rptBillExtraInvoice" Then
  135.     Me.cboFlat.Visible = True
  136.     Me.cboProperty.Visible = True
  137. Else
  138.     Me.cboFlat.Visible = False
  139.     Me.cboProperty.Visible = False
  140. End If
  141.  
  142. If Me.lstReports = "rptInvoiceArrears" Or Me.lstReports = "rptPropertyActions" Or Me.lstReports = "rptInvoiceDetails" Or Me.lstReports = "rptOwners" Or Me.lstReports = "rptInvoice_Phase2" Then
  143.     Me.cboProperty.Visible = True
  144. End If
  145.  
  146. If Me.lstReports = "rptInvoice" Or Me.lstReports = "rptInvoiceRedecWindows" Or Me.lstReports = "rptInvoiceRedecoration" Then
  147.     Me.cboProperty.Visible = True
  148.     Me.cboYear.Visible = True
  149. Else
  150.     Me.cboYear.Visible = False
  151. End If
  152.  
  153. If Me.lstReports = "rptInvoiceReprint" Then
  154.     Me.cboFlat.Visible = True
  155.     Me.cboProperty.Visible = True
  156.     Me.cboYear.Visible = True
  157. Else
  158.     'Me.cboYear.Visible = False
  159. End If
  160.  
  161. If Me.lstReports = "rptGroundRentInvoice" Or Me.lstReports = "rptGroundRentArrears" Then
  162.     Me.cboHalfYear.Visible = True
  163.     Me.lblHalfYear.Visible = True
  164.     Me.cboYear.Visible = True
  165. Else
  166.     Me.cboHalfYear.Visible = False
  167.     Me.lblHalfYear.Visible = False
  168.     Me.cboYear.Visible = False
  169. End If
  170.  
  171. End Sub
  172.  
Thank you for your help in this matter. I am not a experienced programmer, I try an learn as I go along.
May 21 '07 #3
Denburt
1,356 Recognized Expert Top Contributor
The code appears to be o.k. from what I can see. When you get the error message is there a button called "debug" if so click this and tell us what line it is on.
'User-Defined type not defined'

FYI, I know your version is 2000 but have heard that MS Access 2007 is much more restrictive in the syntax department than previous versions. Although many people disagree for one reason or another the correct way to refer to a control is Me!ControlName. Me.Controlname can be quite quirky I have found this to be an issue for me in the past with older versions of Access. Just an idea.

According to Microsoft one thing MS Access will not like in Access 2007 is if you use a boolean as such.

If myBool then

Microsoft states that in 2007 you will need the complete statement.

If myBool = True then
May 21 '07 #4
ADezii
8,834 Recognized Expert Expert
I installed Office 2000 Professional onto a Windows Vista laptop and when I tried to compile the code the following error message appears:

'User-Defined type not defined'

I went to check the registry and the following message appears:

'Error accessing the system registry'.

I have tied to repair Access using the Office 2000 repair facility but no luck.

Do you have any suggestions on this problem.

Thank you
  1. The Style and Response Variables are Declared as String which is incorrect, they shoud be declared as Integers, namely:
    Expand|Select|Wrap|Line Numbers
    1. Dim Msg As String, Msg2 As String, Response As String, Style As String
    2.                                'SHOULD BE
    3. Dim Msg As String, Msg2 As String, Response As Integer, Style As Integer
    4.  
  2. GoTo Line Number, except in Error Trapping, is usually never a good idea to use. It is only supported for backward compatibility and may not even be supported in 2007. Check on this.
May 22 '07 #5
Cogito
3 New Member
Thank you for your prompt reply,

The problem is on a friend's laptop and I do not have access to it this week. From memory when I ran compile the error starts on the first DIM statement.

When I select Tools/References in the Microsoft Visual Basic window the

"Error accessing the system registry" message appears.

The database runs fine on my XP laptop.

I hope this is of help.
May 22 '07 #6
Denburt
1,356 Recognized Expert Top Contributor
It is als nevera goog idea to use a single word for variables you might find yourself bumpininto keywords especially since they can change from version to version.

instead of:
Dim Msg As String, Msg2 As String, Response As Integer, Style As Integer

I would use:
Dim Msg As String, Msg2 As String, intResponse As Integer, strStyle As Integer
May 29 '07 #7
missinglinq
3,532 Recognized Expert Specialist
You might want to look at this forum's posting regarding Vista and Access databases!

http://www.thescripts.com/forum/thread653390.html
May 29 '07 #8

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

Similar topics

2
9085
by: Wanda | last post by:
Hi there, I am getting a Error accessing the OLE registry when the system goes hit the following line set xWd = Server.CreateObject("Word.Application") in my asp? Anything I have to set-up in order to remove this error...
1
3745
by: CLarkou | last post by:
While trying to register MSFLXGRD.OCX with REGSVR32 I got an error (8002801C) which means "error accessing the OLE registry". MSFLXGRD.OCX as COMDLG32 depend on OLE32.DLL & OLEAUT32.DLL. Since COMDLG32 was registered without any problem, what could be the cause ?
1
6041
by: Jody Gelowitz | last post by:
This one should be relatively simple, though I have yet to figure it out. I have an ASP.NET project which uses LDAP authentication to login to the system. When run on our Development or Staging servers, the authentication works great! When running the project on my local computer under \\localhost, I get the following error: System.Runtime.InteropServices.COMException (0x8002801C): Error accessing the OLE registry at...
3
1924
by: mark.jerrom | last post by:
I'm fairly new to this Web Service game so please feel free to suggest something different if it looks like i'm completely off track! I'm trying to write an application that runs on a Pocket PC that is accessing data stored in a SQL server database on a seperate server (not on the pocket pc). This wil be deployed to lots of customers sites so I can't hard-code the location of the database in the program. I wrote a seperate little app...
3
3738
by: hisham123 | last post by:
I had windows xp 2002 service pack 2. i install vb6.0, crystal report 8.0, if i tried to access vb porjects references showing error accessing system registry could anybody give solution for this with regards hisham
0
2552
by: kingkongpennock | last post by:
Hi there, i have a frustrating problem on my hands. at first i had nero 8 ultra, but realized i did not need it any more. so i did the usual thing and tried to uninstall it. all was going well untill a message popped up saying "error accessing ole registry." since im not too bright with my computer, i thought nothing of it. i continued with the uninstallment, and it finished, keying me to restart my computer to finish uninstalling nero...
3
8830
by: rajubaba9 | last post by:
error '8002801c' Error accessing the OLE registry. /iisHelp/common/500-100.asp, line 17
1
1629
by: David Schrader | last post by:
Hello all, Let me start by saying that I'm not certain whether this belongs here, in this notes group, or another more developmentally oriented one. I'll try starting here then go elsewhere if you decide otherwise. (Already forwarded here, sort-of, from: microsoft.public.windowsnt.registry.) I'm writing a Visual Basic program which stores and retrieves data in the registry - no big thing, I've got all that code written
3
3222
by: ranesmitas | last post by:
Hi, In visual Basic when I add reference it shows following error Error Accessing the System Registry Please tell me solution.
0
10214
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10048
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9865
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8872
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7410
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5304
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5447
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3563
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2815
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.