Microsoft Access Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 



Go Back   Dev Articles Community ForumsDatabasesMicrosoft Access Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
  #1  
Old December 1st, 2016, 06:17 PM
dimitri_interna dimitri_interna is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Dec 2016
Posts: 1 dimitri_interna User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 6 m 22 sec
Reputation Power: 0
VBA CODE PROBLEM WITH access 2010

i have this code and it works great for office 2007 (win 7 32) but with my new computer it does nto work with (win 8.1 64) please help me with the code to open the data base.

-------------------------------
Sub MaterialLookup()
Dim dbsDuke As Database
Dim rstDuke As Recordset
'--- This Routine uses the "Microsoft DAO 2.5/3.5 Compatibility Library"
' Libraries are Referenced by selecting "Tools", "References" on the toolbar

CurrentRow = ActiveCell.Row
If CurrentRow < 25 Or CurrentRow > 55 Then
i = MsgBox("Are you Sure You're on the Right Row?", vbYesNo, "Overwrite Cell...")
If i <> 6 Then
End
End If
End If
GetPath
Load UserForm1
[B] Set dbsDuke = OpenDatabase(MDBPath & "DukeMfg.mdb", , True)
Set rstDuke = dbsDuke.OpenRecordset("SELECT * FROM MtrlCat;", dbOpenDynaset, dbReadOnly)
With rstDuke
.MoveFirst
Do
If Not IsNull(!MtrlCatDescription) Then
UserForm1.ComboBox1.AddItem Trim(!MtrlCatNum) & " - " & Trim(!MtrlCatDescription)
End If
.MoveNext
Loop Until .EOF
End With
rstDuke.Close
dbsDuke.Close
UserForm1.ComboBox1.ListIndex = 0
UserForm1.Show
End Sub

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsDatabasesMicrosoft Access Development > VBA CODE PROBLEM WITH access 2010


Developer Shed Advertisers and Affiliates


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.

© 2003-2017 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap