Click to See Complete Forum and Search --> : CreateHardLink


Koka
April 26th, 2001, 09:33 AM
There's CreateHardLink API function in Win2K that creates hard links to files.

Can anyone help me with an example of using it in VB? I do not know how to pass parameters correctly
TYA

TimCottee
April 27th, 2001, 08:39 AM
Use this, I haven't tried it but it should work:

Declare Function CreateHardLink Lib "Kernel32" (lpFileName as string, lpExistingFileName as string, lpSecurityAttributes as Any) as Long



Then use as

lngReturn = CreateHardLink ("Myfilename","MyExistingFileName",0&)

Koka
April 27th, 2001, 09:41 AM
Thanks,
It works.