Creates a new DataConnection instance with current or default PublicationScope and the given locale. DataConnection can be used to access the Orckestra CMS storage.

Namespace: Composite.Data
Assembly: Composite (in Composite.dll) Version: 5.3.6135.33083

Syntax

C#
public DataConnection(
	CultureInfo locale
)
Visual Basic
Public Sub New ( _
	locale As CultureInfo _
)
Visual C++
public:
DataConnection(
	CultureInfo^ locale
)

Parameters

locale
Type: System.Globalization..::..CultureInfo
The desired locale. This should be one of the locale found in AllLocales

Examples

Here is an example of how to use it
CopyC#
using (DataConnection connection = new DataConnection(new CultureInfo("da-DK")))
{
   var q = 
      from d in connection.Get<IMyDataType>()
      where d.Name == "Foo"
      select d;
}

See Also