共用方式為


LocalReport.ReleaseSandboxAppDomain 方法

LocalReport 物件立即將其參考發行至沙箱應用程式網域。

命名空間:  Microsoft.Reporting.WebForms
組件:  Microsoft.ReportViewer.WebForms (在 Microsoft.ReportViewer.WebForms.dll 中)

語法

'宣告
Public Sub ReleaseSandboxAppDomain
public void ReleaseSandboxAppDomain()
public:
void ReleaseSandboxAppDomain()
member ReleaseSandboxAppDomain : unit -> unit 
public function ReleaseSandboxAppDomain()

備註

In local processing mode, the report viewer loads the expression host assembly into either the current application domain or a sandboxed application domain based on the .NET Framework version (see ExecuteReportInSandboxAppDomain). The sandboxed application domain is shared by multiple instances of the LocalReport class. By default, LocalReport causes the application domain to expire after a set time to reclaim memory.

Use this method to force the LocalReport object to release its reference to the sandboxed application domain immediately and help reduce the time it takes for memory to be reclaimed.

If the LocalReport object requires the sandboxed application domain after the sandboxed application domain has already expired, the LocalReport object will create a new one.

請參閱

參考

LocalReport 類別

Microsoft.Reporting.WebForms 命名空間