@msdn=http://search.microsoft.com/search/results.aspx?qu=$$$ @pinvoke=http://pinvoke.net/$$$.htm Summary: The BeginUpdateResource API !!!!C# Signature: [DllImport("kernel32.dll", SetLastError=true)] static extern IntPtr BeginUpdateResource(string pFileName, [MarshalAs(UnmanagedType.Bool)]bool bDeleteExistingResources); !!!!VB.NET Signature: <DllImport("kernel32.dll", SetLastError := False)> _ Public Shared Function BeginUpdateResource(ByVal pFileName As String, _ <MarshalAs(UnmanagedType.Bool)> ByVal bDeleteExistingResources As Boolean) As IntPtr End Function !!!!User-Defined Types: None. !!!!Notes: calls SetLastError. the last error can be retrieved with Marshal.GetLastWin32Error(). !!!!Tips & Tricks: Please add some! !!!!Sample Code: internal void DelFile(ArrayList fileNames) { IntPtr hResource = BeginUpdateResource(mFileName, false); if (hResource.ToInt32() == 0) { throw new Win32Exception(Marshal.GetLastWin32Error()); } foreach (String fileName in fileNames) { if (UpdateResource(hResource, "FILE", fileName, MakeLangId(LANG_ENGLISH, SUBLANG_ENGLISH_US), null, 0) == false) { throw new Win32Exception(Marshal.GetLastWin32Error()); } } if (EndUpdateResource(hResource, false) == false) { throw new Win32Exception(Marshal.GetLastWin32Error()); } } !!!!Alternative Managed API: Do you know one? Please contribute it! Documentation: BeginUpdateResource@msdn on MSDN
Edit kernel32.beginupd...
You do not have permission to change this page. If you feel this is in error, please send feedback with the contact link on the main page.