Verified Commit 137eacd4 authored by Laurent Sittler's avatar Laurent Sittler ©
Browse files

Import projet from CodePlex

parent 7124c3d4

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2012
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AutoSPInstallerGUI", "AutoSPInstallerGUI\AutoSPInstallerGUI.csproj", "{5D3E3498-9BD9-4DC3-81DB-0841E46F0279}"
EndProject
Global
GlobalSection(TeamFoundationVersionControl) = preSolution
SccNumberOfProjects = 2
SccEnterpriseProvider = {4CA58AB2-18FA-4F8D-95D4-32DDF27D184C}
SccTeamFoundationServer = https://tfs.codeplex.com/tfs/tfs18
SccLocalPath0 = .
SccProjectUniqueName1 = AutoSPInstallerGUI\\AutoSPInstallerGUI.csproj
SccProjectName1 = AutoSPInstallerGUI
SccLocalPath1 = AutoSPInstallerGUI
EndGlobalSection
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{5D3E3498-9BD9-4DC3-81DB-0841E46F0279}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{5D3E3498-9BD9-4DC3-81DB-0841E46F0279}.Debug|Any CPU.Build.0 = Debug|Any CPU
{5D3E3498-9BD9-4DC3-81DB-0841E46F0279}.Release|Any CPU.ActiveCfg = Release|Any CPU
{5D3E3498-9BD9-4DC3-81DB-0841E46F0279}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
EndGlobal
""
{
"FILE_VERSION" = "9237"
"ENLISTMENT_CHOICE" = "NEVER"
"PROJECT_FILE_RELATIVE_PATH" = ""
"NUMBER_OF_EXCLUDED_FILES" = "0"
"ORIGINAL_PROJECT_FILE_PATH" = ""
"NUMBER_OF_NESTED_PROJECTS" = "0"
"SOURCE_CONTROL_SETTINGS_PROVIDER" = "PROJECT"
}
<?xml version="1.0"?>
<configuration>
<startup><supportedRuntime version="v2.0.50727"/></startup></configuration>
<Application
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:System="clr-namespace:System;assembly=mscorlib" x:Class="AutoSPInstallerGUI.App"
StartupUri="MainWindow.xaml"
Startup="Application_Startup">
<Application.Resources>
</Application.Resources>
</Application>
using System;
using System.Windows;
namespace AutoSPInstallerGUI
{
/// <summary>
/// Interaction logic for App.xaml
/// </summary>
public partial class App : Application
{
public static String[] mArgs;
private void Application_Startup(object sender, StartupEventArgs e)
{
if (e.Args != null && e.Args.Length > 0)
{
mArgs = e.Args;
}
}
}
}
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{5D3E3498-9BD9-4DC3-81DB-0841E46F0279}</ProjectGuid>
<OutputType>WinExe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>AutoSPInstallerGUI</RootNamespace>
<AssemblyName>AutoSPInstallerGUI</AssemblyName>
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
<WarningLevel>4</WarningLevel>
<TargetFrameworkProfile />
<IsWebBootstrapper>false</IsWebBootstrapper>
<SccProjectName>SAK</SccProjectName>
<SccLocalPath>SAK</SccLocalPath>
<SccAuxPath>SAK</SccAuxPath>
<SccProvider>SAK</SccProvider>
<PublishUrl>publish\</PublishUrl>
<Install>true</Install>
<InstallFrom>Disk</InstallFrom>
<UpdateEnabled>false</UpdateEnabled>
<UpdateMode>Foreground</UpdateMode>
<UpdateInterval>7</UpdateInterval>
<UpdateIntervalUnits>Days</UpdateIntervalUnits>
<UpdatePeriodically>false</UpdatePeriodically>
<UpdateRequired>false</UpdateRequired>
<MapFileExtensions>true</MapFileExtensions>
<ApplicationRevision>19</ApplicationRevision>
<ApplicationVersion>0.0.0.%2a</ApplicationVersion>
<UseApplicationTrust>false</UseApplicationTrust>
<PublishWizardCompleted>true</PublishWizardCompleted>
<BootstrapperEnabled>true</BootstrapperEnabled>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<DocumentationFile>
</DocumentationFile>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<PropertyGroup>
<StartupObject>AutoSPInstallerGUI.App</StartupObject>
</PropertyGroup>
<PropertyGroup>
<ApplicationIcon>xml.ico</ApplicationIcon>
</PropertyGroup>
<PropertyGroup />
<PropertyGroup>
<ManifestCertificateThumbprint>1989FCB81D157C7B4854F2FC8EC8CEF4AEDD7248</ManifestCertificateThumbprint>
</PropertyGroup>
<PropertyGroup>
<ManifestKeyFile>AutoSPInstallerGUI_TemporaryKey.pfx</ManifestKeyFile>
</PropertyGroup>
<PropertyGroup>
<GenerateManifests>false</GenerateManifests>
</PropertyGroup>
<PropertyGroup>
<SignManifests>false</SignManifests>
</PropertyGroup>
<PropertyGroup>
<TargetZone>LocalIntranet</TargetZone>
</PropertyGroup>
<PropertyGroup />
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Xaml" />
<Reference Include="System.Xml" />
<Reference Include="System.Core" />
<Reference Include="WindowsBase" />
<Reference Include="PresentationCore" />
<Reference Include="PresentationFramework" />
</ItemGroup>
<ItemGroup>
<ApplicationDefinition Include="App.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</ApplicationDefinition>
<Page Include="MainWindow.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Compile Include="App.xaml.cs">
<DependentUpon>App.xaml</DependentUpon>
<SubType>Code</SubType>
</Compile>
<Compile Include="Classes\AutoSPInstallerInput_3.98.Designer.cs" />
<Compile Include="Classes\BindingDebugger.cs" />
<Compile Include="Classes\Converters.cs" />
<Compile Include="Classes\ConfigurationExtensions.cs" />
<Compile Include="MainWindow.xaml.cs">
<DependentUpon>MainWindow.xaml</DependentUpon>
<SubType>Code</SubType>
</Compile>
</ItemGroup>
<ItemGroup>
<Compile Include="Properties\AssemblyInfo.cs">
<SubType>Code</SubType>
</Compile>
<Compile Include="Properties\Resources.Designer.cs">
<AutoGen>True</AutoGen>
<DesignTime>True</DesignTime>
<DependentUpon>Resources.resx</DependentUpon>
</Compile>
<Compile Include="Properties\Settings.Designer.cs">
<AutoGen>True</AutoGen>
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
<EmbeddedResource Include="Properties\Resources.resx">
<Generator>PublicResXFileCodeGenerator</Generator>
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
</EmbeddedResource>
<None Include="Classes\AutoSPInstallerInput_3.98.xsd">
<SubType>Designer</SubType>
</None>
<None Include="Properties\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
</None>
<AppDesigner Include="Properties\" />
</ItemGroup>
<ItemGroup>
<None Include="App.config">
<SubType>Designer</SubType>
</None>
</ItemGroup>
<ItemGroup>
<Resource Include="xml.ico" />
</ItemGroup>
<ItemGroup>
<BootstrapperPackage Include="Microsoft.Net.Client.3.5">
<Visible>False</Visible>
<ProductName>.NET Framework 3.5 SP1 Client Profile</ProductName>
<Install>false</Install>
</BootstrapperPackage>
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
<Visible>False</Visible>
<ProductName>.NET Framework 3.5 SP1</ProductName>
<Install>true</Install>
</BootstrapperPackage>
</ItemGroup>
<ItemGroup>
<SplashScreen Include="Splash.png" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>
\ No newline at end of file
""
{
"FILE_VERSION" = "9237"
"ENLISTMENT_CHOICE" = "NEVER"
"PROJECT_FILE_RELATIVE_PATH" = ""
"NUMBER_OF_EXCLUDED_FILES" = "0"
"ORIGINAL_PROJECT_FILE_PATH" = ""
"NUMBER_OF_NESTED_PROJECTS" = "0"
"SOURCE_CONTROL_SETTINGS_PROVIDER" = "PROVIDER"
}
using System.Diagnostics;
using System.Text;
using System.Windows;
// Code Borrowed from http://tech.pro/tutorial/940/wpf-snippet-detecting-binding-errors
namespace AutoSPInstallerGUI.Classes
{
public class BindingErrorTraceListener : DefaultTraceListener
{
private static BindingErrorTraceListener _Listener;
public static void SetTrace()
{ SetTrace(SourceLevels.Error, TraceOptions.None); }
public static void SetTrace(SourceLevels level, TraceOptions options)
{
if (_Listener == null)
{
_Listener = new BindingErrorTraceListener();
PresentationTraceSources.DataBindingSource.Listeners.Add(_Listener);
}
_Listener.TraceOutputOptions = options;
PresentationTraceSources.DataBindingSource.Switch.Level = level;
}
public static void CloseTrace()
{
if (_Listener == null)
{ return; }
_Listener.Flush();
_Listener.Close();
PresentationTraceSources.DataBindingSource.Listeners.Remove(_Listener);
_Listener = null;
}
private StringBuilder _Message = new StringBuilder();
private BindingErrorTraceListener()
{ }
public override void Write(string message)
{ _Message.Append(message); }
public override void WriteLine(string message)
{
_Message.Append(message);
var final = _Message.ToString();
_Message.Length = 0;
MessageBox.Show(final, "Binding Error", MessageBoxButton.OK,
MessageBoxImage.Error);
}
}
}
namespace AutoSPInstallerGUI.Classes
{
using System;
using System.Collections.Generic;
public partial class Configuration
{
[NonSerialized]
private List<WebTemplate> _webTemplatesField;
[System.Xml.Serialization.XmlIgnore]
public List<WebTemplate> WebTemplates
{
get
{
if ((_webTemplatesField == null))
{
_webTemplatesField = new List<WebTemplate>();
WebTemplates.Add(new WebTemplate("Global template", "GLOBAL#0", 15));
WebTemplates.Add(new WebTemplate("Team Site", "STS#0", 15));
WebTemplates.Add(new WebTemplate("Blank Site", "STS#1", 15));
WebTemplates.Add(new WebTemplate("Document Workspace", "STS#2", 15));
WebTemplates.Add(new WebTemplate("Basic Meeting Workspace", "MPS#0", 15));
WebTemplates.Add(new WebTemplate("Blank Meeting Workspace", "MPS#1", 15));
WebTemplates.Add(new WebTemplate("Decision Meeting Workspace", "MPS#2", 15));
WebTemplates.Add(new WebTemplate("Social Meeting Workspace", "MPS#3", 15));
WebTemplates.Add(new WebTemplate("Multipage Meeting Workspace", "MPS#4", 15));
WebTemplates.Add(new WebTemplate("Central Admin Site", "CENTRALADMIN#0", 15));
WebTemplates.Add(new WebTemplate("Wiki Site", "WIKI#0", 15));
WebTemplates.Add(new WebTemplate("Blog", "BLOG#0", 15));
WebTemplates.Add(new WebTemplate("Group Work Site", "SGS#0", 15));
WebTemplates.Add(new WebTemplate("Tenant Admin Site", "TENANTADMIN#0", 15));
WebTemplates.Add(new WebTemplate("App Template", "APP#0", 15));
WebTemplates.Add(new WebTemplate("App Catalog Site", "APPCATALOG#0", 15));
WebTemplates.Add(new WebTemplate("Access Services Site", "ACCSRV#0", 15));
WebTemplates.Add(new WebTemplate("Access Services Site Internal", "ACCSVC#0", 15));
WebTemplates.Add(new WebTemplate("Access Services Site", "ACCSVC#1", 15));
WebTemplates.Add(new WebTemplate("Document Center", "BDR#0", 15));
WebTemplates.Add(new WebTemplate("Developer Site", "DEV#0", 15));
WebTemplates.Add(new WebTemplate("Academic Library", "DOCMARKETPLACESITE#0", 15));
WebTemplates.Add(new WebTemplate("eDiscovery Center", "EDISC#0", 15));
WebTemplates.Add(new WebTemplate("(obsolete) Records Center", "OFFILE#0", 15));
WebTemplates.Add(new WebTemplate("Records Center", "OFFILE#1", 15));
WebTemplates.Add(new WebTemplate("Shared Services Administration Site", "OSRV#0", 15));
WebTemplates.Add(new WebTemplate("PerformancePoint", "PPSMASite#0", 15));
WebTemplates.Add(new WebTemplate("Business Intelligence Center", "BICenterSite#0", 15));
WebTemplates.Add(new WebTemplate("SharePoint Portal Server Site", "SPS#0", 15));
WebTemplates.Add(new WebTemplate("SharePoint Portal Server Personal Space", "SPSPERS#0", 15));
WebTemplates.Add(new WebTemplate("Storage And Social SharePoint Portal Server Personal Space", "SPSPERS#2", 15));
WebTemplates.Add(new WebTemplate("Storage Only SharePoint Portal Server Personal Space", "SPSPERS#3", 15));
WebTemplates.Add(new WebTemplate("Social Only SharePoint Portal Server Personal Space", "SPSPERS#4", 15));
WebTemplates.Add(new WebTemplate("Empty SharePoint Portal Server Personal Space", "SPSPERS#5", 15));
WebTemplates.Add(new WebTemplate("Contents area Template", "SPSTOC#0", 15));
WebTemplates.Add(new WebTemplate("Topic area template", "SPSTOPIC#0", 15));
WebTemplates.Add(new WebTemplate("News Site", "SPSNEWS#0", 15));
WebTemplates.Add(new WebTemplate("Site Directory", "SPSSITES#0", 15));
WebTemplates.Add(new WebTemplate("Community area template", "SPSCOMMU#0", 15));
WebTemplates.Add(new WebTemplate("Report Center", "SPSREPORTCENTER#0", 15));
WebTemplates.Add(new WebTemplate("Collaboration Portal", "SPSPORTAL#0", 15));
WebTemplates.Add(new WebTemplate("Enterprise Search Center", "SRCHCEN#0", 15));
WebTemplates.Add(new WebTemplate("Profiles", "PROFILES#0", 15));
WebTemplates.Add(new WebTemplate("Publishing Portal", "BLANKINTERNETCONTAINER#0", 15));
WebTemplates.Add(new WebTemplate("My Site Host", "SPSMSITEHOST#0", 15));
WebTemplates.Add(new WebTemplate("Enterprise Wiki", "ENTERWIKI#0", 15));
WebTemplates.Add(new WebTemplate("Project Site", "PROJECTSITE#0", 15));
WebTemplates.Add(new WebTemplate("Product Catalog", "PRODUCTCATALOG#0", 15));
WebTemplates.Add(new WebTemplate("Community Site", "COMMUNITY#0", 15));
WebTemplates.Add(new WebTemplate("Community Portal", "COMMUNITYPORTAL#0", 15));
WebTemplates.Add(new WebTemplate("Basic Search Center", "SRCHCENTERLITE#0", 15));
WebTemplates.Add(new WebTemplate("Basic Search Center", "SRCHCENTERLITE#1", 15));
WebTemplates.Add(new WebTemplate("Visio Process Repository", "visprus#0", 15));
WebTemplates.Add(new WebTemplate("Global template", "GLOBAL#0", 14));
WebTemplates.Add(new WebTemplate("Team Site", "STS#0", 14));
WebTemplates.Add(new WebTemplate("Blank Site", "STS#1", 14));
WebTemplates.Add(new WebTemplate("Document Workspace", "STS#2", 14));
WebTemplates.Add(new WebTemplate("Basic Meeting Workspace", "MPS#0", 14));
WebTemplates.Add(new WebTemplate("Blank Meeting Workspace", "MPS#1", 14));
WebTemplates.Add(new WebTemplate("Decision Meeting Workspace", "MPS#2", 14));
WebTemplates.Add(new WebTemplate("Social Meeting Workspace", "MPS#3", 14));
WebTemplates.Add(new WebTemplate("Multipage Meeting Workspace", "MPS#4", 14));
WebTemplates.Add(new WebTemplate("Central Admin Site", "CENTRALADMIN#0", 14));
WebTemplates.Add(new WebTemplate("Wiki Site", "WIKI#0", 14));
WebTemplates.Add(new WebTemplate("Blog", "BLOG#0", 14));
WebTemplates.Add(new WebTemplate("Group Work Site", "SGS#0", 14));
WebTemplates.Add(new WebTemplate("Tenant Admin Site", "TENANTADMIN#0", 14));
WebTemplates.Add(new WebTemplate("Access Services Site", "ACCSRV#0", 14));
WebTemplates.Add(new WebTemplate("Document Center", "BDR#0", 14));
WebTemplates.Add(new WebTemplate("(obsolete) Records Center", "OFFILE#0", 14));
WebTemplates.Add(new WebTemplate("Records Center", "OFFILE#1", 14));
WebTemplates.Add(new WebTemplate("Shared Services Administration Site", "OSRV#0", 14));
WebTemplates.Add(new WebTemplate("PerformancePoint", "PPSMASite#0", 14));
WebTemplates.Add(new WebTemplate("Business Intelligence Center", "BICenterSite#0", 14));
WebTemplates.Add(new WebTemplate("SharePoint Portal Server Site", "SPS#0", 14));
WebTemplates.Add(new WebTemplate("SharePoint Portal Server Personal Space", "SPSPERS#0", 14));
WebTemplates.Add(new WebTemplate("Contents area Template", "SPSTOC#0", 14));
WebTemplates.Add(new WebTemplate("Topic area template", "SPSTOPIC#0", 14));
WebTemplates.Add(new WebTemplate("News Site", "SPSNEWS#0", 14));
WebTemplates.Add(new WebTemplate("Site Directory", "SPSSITES#0", 14));
WebTemplates.Add(new WebTemplate("Community area template", "SPSCOMMU#0", 14));
WebTemplates.Add(new WebTemplate("Report Center", "SPSREPORTCENTER#0", 14));
WebTemplates.Add(new WebTemplate("Collaboration Portal", "SPSPORTAL#0", 14));
WebTemplates.Add(new WebTemplate("Enterprise Search Center", "SRCHCEN#0", 14));
WebTemplates.Add(new WebTemplate("Profiles", "PROFILES#0", 14));
WebTemplates.Add(new WebTemplate("Publishing Portal", "BLANKINTERNETCONTAINER#0", 14));
WebTemplates.Add(new WebTemplate("My Site Host", "SPSMSITEHOST#0", 14));
WebTemplates.Add(new WebTemplate("Enterprise Wiki", "ENTERWIKI#0", 14));
WebTemplates.Add(new WebTemplate("Basic Search Center", "SRCHCENTERLITE#0", 14));
WebTemplates.Add(new WebTemplate("Basic Search Center", "SRCHCENTERLITE#1", 14));
WebTemplates.Add(new WebTemplate("FAST Search Center", "SRCHCENTERFAST#0", 14));
WebTemplates.Add(new WebTemplate("Visio Process Repository", "visprus#0", 14));
}
return _webTemplatesField;
}
}
}
public class WebTemplate
{
public string Title { get; set; }
public string Name { get; set; }
public int CompatibilityLevel { get; set; }
public WebTemplate() { }
public WebTemplate(string theTitle, string theName, int theCompatibilityLevel)
{
Title = theTitle;
Name = theName;
CompatibilityLevel = theCompatibilityLevel;
}
}
}
\ No newline at end of file
using System;
using System.Globalization;
using System.Windows.Data;
namespace AutoSPInstallerGUI.Classes
{
/// <summary>
/// Used to convert string values to boolean
/// </summary>
public class StringtoBooleanConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
string stringValue = value as string;
if (stringValue != null)
{
return String.Equals(stringValue, parameter.ToString(), StringComparison.CurrentCultureIgnoreCase);
}
return false;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
return parameter;
}
}
/// <summary>
/// Used to convert string values to boolean inverse
/// </summary>
public class InverseStringtoBooleanConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
string stringValue = value as string;
if (stringValue != null)
{
return !String.Equals(stringValue, parameter.ToString(), StringComparison.CurrentCultureIgnoreCase);
}
return true;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
return parameter;
}
}
/// <summary>
/// Used to for inverting Boolean bindings
/// </summary>
[ValueConversion(typeof(bool), typeof(bool))]
public class InverseBooleanConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
if (targetType != typeof(bool))
{
throw new InvalidOperationException("The target must be a Boolean");
}
return !(bool)value;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotSupportedException();
}
}
/// <summary>
/// Returns true if parameter contains value
/// </summary>
public class CollectionOfStringtoBooleanConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
string stringValue = value as string;
if (stringValue != null)
{
string s = parameter as string;
if (s != null)
{
string[] stringParameters = s.Split(";".ToCharArray());
foreach (string item in stringParameters)
{
if (item.ToLower() == stringValue.ToLower())
{
return true;
}
}
}
}
return false;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
throw new NotSupportedException();
}