Type a page name and press Enter. You'll jump to the page if it exists, or you can create it if it doesn't.
To create a page in a module other than netapi32, prefix the name with the module name and a period.
NetFileClose (netapi32)
.
C# Signature:
[DllImport("netapi32.dll", SetLastError=true, CharSet = CharSet.Unicode)]
static extern int NetFileClose(
string servername,
int id);
VB Signature:
Declare Unicode Function NetFileClose Lib "netapi32.dll" _
ByVal servername As String, _
ByVal fileid As Integer) As Integer
Declare Function NetFileClose Lib "netapi32.dll" _
ByVal servername As String, _
ByVal fileid As Integer) As Integer
if (MessageBox.Show(this, "Are you sure you want to close this connection?" == DialogResult.Yes))
if (MessageBox.Show(this, "Are you sure you want to close this connection?" == DialogResult.Yes)
NetFileClose(strServerName, fileId);
VB.Net Sample Code:
If MsgBox("Are you sure you want to disconnect this resource?", MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
NetFileClose(strServerName, fileid)
End If
Alternative Managed API:
Do you know one? Please contribute it!
The NetFileEnum function returns information about some or all open files on a server, depending on the parameters specified
12/9/2009 11:45:08 AM - -194.203.23.2
Please edit this page!
Do you have...
helpful tips or sample code to share for using this API in managed code?
corrections to the existing content?
variations of the signature you want to share?
additional languages you want to include?
Select "Edit This Page" on the right hand toolbar and edit it! Or add new pages containing supporting types needed for this API (structures, delegates, and more).