# C1.Schedule.Localization.C1Localizer.GetString

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="C1_Schedule_Localization_C1Localizer_GetString_" data-uid="C1.Schedule.Localization.C1Localizer.GetString*">GetString Method
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="C1_Schedule_Localization_C1Localizer_GetString_" data-uid="C1.Schedule.Localization.C1Localizer.GetString*"></a>
<h4 id="C1_Schedule_Localization_C1Localizer_GetString_System_String_System_String_System_String_System_String_" data-uid="C1.Schedule.Localization.C1Localizer.GetString(System.String,System.String,System.String,System.String)">GetString(string, string, string, string)</h4>
<div class="markdown level1 summary"><p>Returns the localized string for the specified culture.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public static string GetString(string resourceAssembly, string resourceDictionary, string resourceKey, string defaultValue)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Shared Function GetString(resourceAssembly As String, resourceDictionary As String, resourceKey As String, defaultValue As String) As String</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">resourceAssembly</span></td>
      <td><p>The name of resource assembly.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">resourceDictionary</span></td>
      <td><p>The name of resource dictionary.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">resourceKey</span></td>
      <td><p>The resource key.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">defaultValue</span></td>
      <td><p>The default value.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td></td>
    </tr>
  </tbody>
</table>
<h5 id="C1_Schedule_Localization_C1Localizer_GetString_System_String_System_String_System_String_System_String__remarks">Remarks</h5>
<div class="markdown level1 remarks"><p>Search order:
- searching in the specified resource Assembly;
- searching in satellite Assemblies of the specified resource Assembly;
- searching in the executing assembly;
- repeating the search in above assemblies for the parent culture;
- if result is not found, returning the specified default value.</p>
</div>


<a id="C1_Schedule_Localization_C1Localizer_GetString_" data-uid="C1.Schedule.Localization.C1Localizer.GetString*"></a>
<h4 id="C1_Schedule_Localization_C1Localizer_GetString_System_String_System_String_System_String_System_String_System_Globalization_CultureInfo_" data-uid="C1.Schedule.Localization.C1Localizer.GetString(System.String,System.String,System.String,System.String,System.Globalization.CultureInfo)">GetString(string, string, string, string, CultureInfo)</h4>
<div class="markdown level1 summary"><p>Returns the localized string for the specified culture.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">[Obsolete(&quot;This method is obsolete. Use overload without culture parameter instead.&quot;)]
public static string GetString(string resourceAssembly, string resourceDictionary, string resourceKey, string defaultValue, CultureInfo culture)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">&lt;Obsolete(&quot;This method is obsolete. Use overload without culture parameter instead.&quot;)&gt;
Public Shared Function GetString(resourceAssembly As String, resourceDictionary As String, resourceKey As String, defaultValue As String, culture As CultureInfo) As String</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">resourceAssembly</span></td>
      <td><p>The name of resource assembly.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">resourceDictionary</span></td>
      <td><p>The name of resource dictionary.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">resourceKey</span></td>
      <td><p>The resource key.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">defaultValue</span></td>
      <td><p>The default value.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.globalization.cultureinfo">CultureInfo</a></td>
      <td><span class="parametername">culture</span></td>
      <td><p>The <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.globalization.cultureinfo">CultureInfo</a> info.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td></td>
    </tr>
  </tbody>
</table>
<h5 id="C1_Schedule_Localization_C1Localizer_GetString_System_String_System_String_System_String_System_String_System_Globalization_CultureInfo__remarks">Remarks</h5>
<div class="markdown level1 remarks"><p>Search order:
- searching in the specified resource Assembly;
- searching in satellite Assemblies of the specified resource Assembly;
- searching in the executing assembly;
- repeating the search in above assemblies for the parent culture;
- if result is not found, returning the specified default value.</p>
</div>


<a id="C1_Schedule_Localization_C1Localizer_GetString_" data-uid="C1.Schedule.Localization.C1Localizer.GetString*"></a>
<h4 id="C1_Schedule_Localization_C1Localizer_GetString_System_String_System_String_System_String_" data-uid="C1.Schedule.Localization.C1Localizer.GetString(System.String,System.String,System.String)">GetString(string, string, string)</h4>
<div class="markdown level1 summary"><p>Returns the localized string for the specified culture.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public static string GetString(string resourceDictionary, string resourceKey, string defaultValue)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Shared Function GetString(resourceDictionary As String, resourceKey As String, defaultValue As String) As String</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">resourceDictionary</span></td>
      <td><p>The name of resource dictionary.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">resourceKey</span></td>
      <td><p>The resource key.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">defaultValue</span></td>
      <td><p>The default value.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td></td>
    </tr>
  </tbody>
</table>
<h5 id="C1_Schedule_Localization_C1Localizer_GetString_System_String_System_String_System_String__remarks">Remarks</h5>
<div class="markdown level1 remarks"><p>Search order:
- searching in the executing Assembly;
- repeating the search for the parent culture;
- if result is not found, returning the specified default value.</p>
</div>


<a id="C1_Schedule_Localization_C1Localizer_GetString_" data-uid="C1.Schedule.Localization.C1Localizer.GetString*"></a>
<h4 id="C1_Schedule_Localization_C1Localizer_GetString_System_String_System_String_System_String_System_Globalization_CultureInfo_" data-uid="C1.Schedule.Localization.C1Localizer.GetString(System.String,System.String,System.String,System.Globalization.CultureInfo)">GetString(string, string, string, CultureInfo)</h4>
<div class="markdown level1 summary"><p>Returns the localized string for the specified culture.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">[Obsolete(&quot;This method is obsolete. Use overload without culture parameter instead.&quot;)]
public static string GetString(string resourceDictionary, string resourceKey, string defaultValue, CultureInfo culture)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">&lt;Obsolete(&quot;This method is obsolete. Use overload without culture parameter instead.&quot;)&gt;
Public Shared Function GetString(resourceDictionary As String, resourceKey As String, defaultValue As String, culture As CultureInfo) As String</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">resourceDictionary</span></td>
      <td><p>The name of resource dictionary.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">resourceKey</span></td>
      <td><p>The resource key.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">defaultValue</span></td>
      <td><p>The default value.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.globalization.cultureinfo">CultureInfo</a></td>
      <td><span class="parametername">culture</span></td>
      <td><p>The <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.globalization.cultureinfo">CultureInfo</a> object.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td></td>
    </tr>
  </tbody>
</table>
<h5 id="C1_Schedule_Localization_C1Localizer_GetString_System_String_System_String_System_String_System_Globalization_CultureInfo__remarks">Remarks</h5>
<div class="markdown level1 remarks"><p>Search order:
- searching in the executing Assembly;
- repeating the search for the parent culture;
- if result is not found, returning the specified default value.</p>
</div>
</div>
