Skip to main content

CodeCompletionRequestManager.UseLocalEngine(ICodeCompletionContextStorage) Method

Activates the local code completion engine and stores report layouts in the specified storage.

Namespace: DevExpress.XtraReports.CodeCompletion

Assembly: DevExpress.XtraReports.v24.2.CodeCompletion.dll

NuGet Package: DevExpress.Reporting.CodeCompletion

Declaration

public static void UseLocalEngine(
    ICodeCompletionContextStorage contextStorage
)

Parameters

Name Type Description
contextStorage ICodeCompletionContextStorage

A report layout storage that implements the ICodeCompletionContextStorage interface.

Remarks

Intelligent code completion requires connection to the Internet and supports only .NET Framework and DevExpress libraries deployed with the application.

For End-User Report Designers, you can activate the local code completion engine that works without Internet connection and additionally supports types defined in custom assemblies. Install the DevExpress.Reporting.CodeCompletion NuGet package and call the UseLocalEngine method at the application startup.

The local engine requires a storage for report layouts. You can use the predefined storage (the FileCodeCompletionContextStorage or InMemoryCodeCompletionContextStorage class) or provide your custom storage.

The following code demonstrates how to pass the FileCodeCompletionContextStorage instance to store report layouts in the specified folder.

using DevExpress.XtraReports.CodeCompletion;
using DevExpress.XtraReports.CodeCompletion.Storages;

CodeCompletionRequestManager.UseLocalEngine(new FileCodeCompletionContextStorage("D:\\CodeCompletionContext"));

You can also implement the ICodeCompletionContextStorage interface, create its instance and pass it to the method as the parameter.

The UseLocalEngine() method overload without parameters activates an in-memory storage (InMemoryCodeCompletionContextStorage).

See the Scripts Overview topic for more information.

See Also