|
Thread: api
-
Nov 9th, 2000, 07:52 AM
#1
Thread Starter
New Member
How do i create folders???
-
Nov 9th, 2000, 08:39 AM
#2
Fanatic Member
-
Nov 9th, 2000, 10:14 AM
#3
Incase your wondering, there is an api function for it called CreateDirectory.
Code:
Declare Function CreateDirectory Lib "kernel32.dll" Alias "CreateDirectoryA" (ByVal lpPathName As String, lpSecurityAttributes As SECURITY_ATTRIBUTES) As Long
Type SECURITY_ATTRIBUTES
nLength As Long
lpSecurityDescriptor As Long
bInheritHandle As Boolean
End Type
Usage
Private Sub Command1_Click()
' Set the desired security attributes
secattr.nLength = Len(secattr) ' size of the structure
secattr.lpSecurityDescriptor = 0 ' default (normal) level of security
secattr.bInheritHandle = 1 ' this is the default setting
CreateDirectory "C:\MyDir", secattr
End Sub
-
Nov 9th, 2000, 10:33 AM
#4
Fanatic Member
Matthew, I think you forgot this line:
Code:
Dim secattr As SECURITY_ATTRIBUTES
-
Nov 9th, 2000, 10:40 AM
#5
Thanks oetje!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|