Hi there. I'm extremely new to VBA and MS-Access.
I very simply need to have specific folder names on my desktop to appear in a msgbox when a form is loaded. This folder then needs to be copied to another location. The folder name contains the characters "BAC". Thus it could be aaBac2013 or bbBack2013. I'm stuck at after obtaining the desktop path. From there I need help. This is my code:
Private Sub Form_Load()
Dim spath As String
Dim strPartName As String
spath = Environ("USERPROFILE") & "\Desktop"
strPartName = "BAC"
MsgBox strPartName, , "strPartName"
End Sub
I know the code is incomplete... hence my request for assistance.
Thanking you
I very simply need to have specific folder names on my desktop to appear in a msgbox when a form is loaded. This folder then needs to be copied to another location. The folder name contains the characters "BAC". Thus it could be aaBac2013 or bbBack2013. I'm stuck at after obtaining the desktop path. From there I need help. This is my code:
Private Sub Form_Load()
Dim spath As String
Dim strPartName As String
spath = Environ("USERPROFILE") & "\Desktop"
strPartName = "BAC"
MsgBox strPartName, , "strPartName"
End Sub
I know the code is incomplete... hence my request for assistance.
Thanking you
Last edited: