Code Snippet Details

<- Back to List


Language
VB.Net
Description
Release Excel object
Code
Public Class ExcelUtilities Public Shared Sub ReleaseObject(ByVal objectToRelease As Object) Try System.Runtime.InteropServices.Marshal.ReleaseComObject(objectToRelease) objectToRelease = Nothing Catch ex As Exception objectToRelease = Nothing End Try End Sub End Class