Click to See Complete Forum and Search --> : api
venkatesh_cts
Nov 9th, 2000, 06:52 AM
How do i create folders???
oetje
Nov 9th, 2000, 07:39 AM
You don't need the api for that.:) http://msdn.microsoft.com/library/devprods/vs6/vbasic/vbenlr98/vastmMkDir.htm
Incase your wondering, there is an api function for it called CreateDirectory.
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
oetje
Nov 9th, 2000, 09:33 AM
Matthew, I think you forgot this line:
Dim secattr As SECURITY_ATTRIBUTES
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.