DataTrigger is not working in xaml wpf

Hi All,
I want to change the Data templates dynamically based on some selection. Here I have used DataTrigger to which I have binded a property which is not working. I don't know why its not working.
Please find below .xaml code -                                
        <DataTemplate x:Key="StackTemplate">
            <TextBlock x:Name="txtStack" Text="We are using Stack Panel"></TextBlock>
        </DataTemplate>
        <DataTemplate x:Key="DockTemplate">
            <TextBlock x:Name="txtDock" Text="We are using Dock Panel"></TextBlock>
        </DataTemplate>
        <DataTemplate x:Key="WrapTemplate">
            <TextBlock x:Name="txtWrap" Text="We are using Wrap Panel"></TextBlock>
        </DataTemplate>
        <DataTemplate x:Key="CanvasTemplate">
            <TextBlock x:Name="txtcanvas" Text="we are using Canvas panel"></TextBlock>
        </DataTemplate>
    </Window.Resources>
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="50"></RowDefinition>
            <RowDefinition Height="*"></RowDefinition>
        </Grid.RowDefinitions>
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="170"></ColumnDefinition>
            <ColumnDefinition Width="*"></ColumnDefinition>
        </Grid.ColumnDefinitions>
        <TextBlock Grid.Column="0" Grid.Row="0" x:Name="Txtblk" Text="Choose Layout Panel"></TextBlock>
        <ComboBox Grid.Column="1" Width="200"  ItemsSource="{Binding Source={StaticResource LoadCombo}}" Margin="66,12,66,0"></ComboBox> // loaded from xaml
        <ItemsControl Grid.Column="1" Grid.Row="1" x:Name="itemctrl" Height="250" Width="280">
            <DataTemplate>
                <ContentControl Content="{Binding}">
                    <ContentControl.Style>
                        <Style TargetType="{x:Type ContentControl}">
                            <Style.Triggers>
                                <DataTrigger Binding="{Binding Path=MyProperty,RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type Window}}}" Value="0">
                                    <Setter Property="ContentTemplate" Value="{StaticResource StackTemplate}"></Setter>
                                </DataTrigger>
                                <DataTrigger Binding="{Binding Path=MyProperty,RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type Window}}}" Value="1">
                                    <Setter Property="ContentTemplate" Value="{StaticResource DockTemplate}"></Setter>
                                </DataTrigger>
                                <DataTrigger Binding="{Binding Path=MyProperty,RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type Window}}}" Value="2">
                                    <Setter Property="ContentTemplate" Value="{StaticResource WrapTemplate}"></Setter>
                                </DataTrigger>
                                <DataTrigger Binding="{Binding Path=MyProperty,RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type Window}}}" Value="3">
                                    <Setter Property="ContentTemplate" Value="{StaticResource CanvasTemplate}"></Setter>
                                </DataTrigger>                                
                            </Style.Triggers>
                        </Style>
                    </ContentControl.Style>
                </ContentControl>
            </DataTemplate>
        </ItemsControl>
Here is my .xaml.cs class - 
  public partial class MainWindow : Window
        public string Select { get; set; }
        public string MyProperty
            get
                string number=string.Empty;
                switch (Select)
                    case "STACKPANEL": 
                        number = "0"; break;
                    case "DOCKPANEL":
                        number = "1"; break;
                    case "WRAPPANEL":
                        number = "2"; break;
                    case "CANVAS":
                        number= "3"; break;
                return number;
        public MainWindow()
            InitializeComponent();
            DataContext = this;
            Select = "0";
            cmb.SelectionChanged += new SelectionChangedEventHandler(cmb_SelectionChanged);
        void cmb_SelectionChanged(object sender, SelectionChangedEventArgs e)
            Select = (sender as ComboBox).Text;
Please help me.

That isn't going to work.
Selecting datatemplate is a one off process.
When you're looking at the view, it's done.
I think if you used a contenttemplateselector you could force the issue:
MyControl.ContentTemplateSelector =
new MyDataTemplateSelector();
I very rarely use those myself though.
Personally, I would be inclined to just switch out the control for a new one with the appropriate template.
It's a view responsibility so doing that in code behind isn't even breaking mvvm.
Your code coverage might dip a little, but this doesn't look like a real app anyhow.
I agree with Andy, using DataTemplateSelector should be the right direction, please refer to this case to know how it works:
https://social.msdn.microsoft.com/Forums/vstudio/en-US/f7c60968-f3a0-499a-a20e-01aac82d942f/datatemplate-for-generic-type-is-not-working?forum=wpf
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey.

Similar Messages

  • My sound system does not work AFTER installing pc to tv wireless connection

    my sound system does not work after installing hp pc to tv wireles device when I am using lap top for other purposes.

    Hi,
    You don’t install VS2010 on the client PC, then where did the Form Invoice not work? When you run it from another version of VS? Or when you run the application with application.exe?
    Based on your description, one form works well, another form does not. I assume that two forms are in two different projects, then please check the .Net Framework used by the two projects. If they are different, you can use the
    one used by the Form contact for Form Invoice.
    Because this issue is a project issue, I recommend you to consult it on some application forum such as Windows Forms General forum for better support.
    VS General Question forum mainly discusses
    the usage of Visual Studio IDE such as
    WPF & SL designer, Visual Studio Guidance Automation Toolkit, Developer Documentation and Help
    System and Visual Studio Editor.
    Thanks,
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • My DotNet application does not work after installing Framework 4.0 on My client PC

    HI 
    I created application in Visual 2010 therefore I need framework 4.0 to work my application on client PC but it is still not working. 
    I have few forms in my application. 
    Form contact has controls Textbox, labels, button on it. (This form works fine absolutely ) 
    Form Invoice has DatagridView, textbox, label,button . (This form is NOT working at all, give me an error) 
    Any bright suggestion will help me to NOT install whole carp of visual studio 2010 on my client pc and also save Space. 
    Thank you in advance

    Hi,
    You don’t install VS2010 on the client PC, then where did the Form Invoice not work? When you run it from another version of VS? Or when you run the application with application.exe?
    Based on your description, one form works well, another form does not. I assume that two forms are in two different projects, then please check the .Net Framework used by the two projects. If they are different, you can use the
    one used by the Form contact for Form Invoice.
    Because this issue is a project issue, I recommend you to consult it on some application forum such as Windows Forms General forum for better support.
    VS General Question forum mainly discusses
    the usage of Visual Studio IDE such as
    WPF & SL designer, Visual Studio Guidance Automation Toolkit, Developer Documentation and Help
    System and Visual Studio Editor.
    Thanks,
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Silverlight 5 binding on a property with logic in its setter does not work as expected when debug is attached

    My problem is pretty easy to reproduce.
    I created a project from scratch with a view model.
    As you can see in the setter of "Age" property I have a simple logic.
        public class MainViewModel : INotifyPropertyChanged
                public event PropertyChangedEventHandler PropertyChanged;
                private int age;
                public int Age
                    get
                        return age;
                    set
                        /*Age has to be over 18* - a simple condition in the setter*/
                        age = value;
                        if(age <= 18)
                            age = 18;
                        OnPropertyChanged("Age");
                public MainViewModel(int age)
                    this.Age = age;
                private void OnPropertyChanged(string propertyName)
                    if (this.PropertyChanged != null)
                        PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
    In the MainPage.xaml 
         <Grid x:Name="LayoutRoot" Background="White">
                <TextBox 
                    Text="{Binding Path=Age, Mode=TwoWay}" 
                    HorizontalAlignment="Left"
                    Width="100"
                    Height="25"/>
                <TextBlock
                    Text="{Binding Path=Age, Mode=OneWay}"
                    HorizontalAlignment="Right"
                    Width="100"
                    Height="25"/>
            </Grid>
    And MainPage.xaml.cs I simply instantiate the view model and set it as a DataContext.
        public partial class MainPage : UserControl
            private MainViewModel mvm;
            public MainPage()
                InitializeComponent();
                mvm = new MainViewModel(20);
                this.DataContext = mvm;
    I expect that this code will limit set the Age to 18 if the value entered in the TextBox is lower than 18.
    Scenario: Insert into TextBox the value "5" and press tab (for the binding the take effect, TextBox needs to lose the focus)
    Case 1: Debugger is attached =>
    TextBox value will be "5" and TextBlock value will be "18" as expected. - WRONG
    Case 2: Debugger is NOT attached => 
    TextBox value will be "18" and TextBlock value will be "18" - CORRECT
    It seems that when debugger is attached the binding does not work as expected on the object that triggered the update of the property value. This happens only if the property to which we are binding has some logic into the setter or getter.
    Has something changed in SL5 and logic in setters is not allowed anymore?
    Configuration:
    VisualStudio 2010 SP1
    SL 5 Tools 5.1.30214.0
    SL5 sdk 5.0.61118.0
    IE 10
    Thanks!                                       

    Inputting the value and changing it straight away is relatively rare.
    Very few people are now using Silverlight because it's kind of deprecated...
    This is why nobody has reported this.
    I certainly never noticed this problem and I have a number of live Silverlight systems out there.
    Some of which are huge.
    If you want a "fix":
    private void OnPropertyChanged(string propertyName)
    if (this.PropertyChanged != null)
    //PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
    Storyboard sb = new Storyboard();
    sb.Duration = new Duration(new TimeSpan(0, 0, 0, 0, 100));
    sb.Completed += delegate
    PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
    sb.Begin();
    The fact this works is interesting because (I think ) it means the textbox can't be updated at the point the propertychanged is raised.
    Please don't forget to upvote posts which you like and mark those which answer your question.
    My latest Technet article - Dynamic XAML

  • AutoSuggestBox.selecteditem is Not Working in Windows Phone8.1

    For AutoSuggestBox Selected item is Enabled in _SuggestionChosen Event But in "getitemselected()" method selected item is not working, in WP8.1
    In XAML File:
    <AutoSuggestBox x:Name="tblkpersonname" Width="380" Margin="0,-7,0,0" ItemsSource="{Binding}" TextChanged="tblkpersonname_TextChanged">
    <AutoSuggestBox.ItemTemplate>
    <DataTemplate>
    <TextBlock Text="{Binding Name}"
    Tag="{Binding PersonID}"/>
    </DataTemplate>
    </AutoSuggestBox.ItemTemplate>
    </AutoSuggestBox>
    In Cs File:
    private void tblkpersonname_SuggestionChosen(AutoSuggestBox sender, AutoSuggestBoxSuggestionChosenEventArgs args)
    System.Diagnostics.Debug.WriteLine("Suggestion chosen : {0}", ((values)args.SelectedItem).Name);
    public void getitemselected()
    //Error in this line when select item from AutoSuggestBox
    if (((values)tblkpersonname.SelectedItem) != null)
    //Some Statements

    Hi chinni987,
    >>selectedItem getting null value when i selected a valu
    Have you handled the
    AutoSuggestBox.SuggestionChosen event? From your code snippets, you should have a custom class named "values", here is my completed sample, it worked well:
    <AutoSuggestBox x:Name="tblkpersonname" Width="380" ItemsSource="{Binding}" SuggestionChosen="tblkpersonname_SuggestionChosen">
    <AutoSuggestBox.ItemTemplate>
    <DataTemplate>
    <TextBlock Text="{Binding Name}"
    Tag="{Binding PersonID}"/>
    </DataTemplate>
    </AutoSuggestBox.ItemTemplate>
    </AutoSuggestBox>
    public sealed partial class MainPage : Page
    List<values> list = new List<values>();
    public MainPage()
    this.InitializeComponent();
    this.NavigationCacheMode = NavigationCacheMode.Required;
    for (int i=0; i<10; i++ )
    list.Add(new values() { Name = "name" + (i + 1).ToString(), PersonID = i + 1 });
    this.DataContext = list;
    protected override void OnNavigatedTo(NavigationEventArgs e)
    values selectedItem = null;
    private void tblkpersonname_SuggestionChosen(AutoSuggestBox sender, AutoSuggestBoxSuggestionChosenEventArgs args)
    System.Diagnostics.Debug.WriteLine("Suggestion chosen : {0}", ((values)args.SelectedItem).Name);
    selectedItem = args.SelectedItem as values;
    public void getitemselected()
    //Error in this line when select item from AutoSuggestBox
    if (selectedItem != null)
    //Some Statements
    public class values
    public string Name { get; set; }
    public int PersonID { get; set; }
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Flip Card Animation is not working properly when Button's PointOver State remain Activated.

     I am facing problems with flip car animation which is not working properly when its mouse point over state remains activated but it works perfect when its tapped two times and instantly change pointer position. Kindly Help me out as soon as possible.
    Code is here:
    Xaml:
    <Image Name="imgCapital" RenderTransformOrigin=".5,.5" Tag="1" Tapped="imgCapital_Tapped">
    <Image.Projection>
    <PlaneProjection RotationY="0"/>
    </Image.Projection>
    </Image>
    <Image Name="imgSmall" RenderTransformOrigin=".5,.5" Tag="2" Opacity="1" Tapped="imgSmall_Tapped">
    <Image.Projection>
    <PlaneProjection RotationY="-90"/>
    </Image.Projection>
    </Image>
    Storyboard:
    <Storyboard x:Name="FlipOpen">
    <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Projection).(PlaneProjection.RotationY)" Storyboard.TargetName="imgCapital">
    <EasingDoubleKeyFrame KeyTime="0:0:0" Value="0"/>
    <EasingDoubleKeyFrame KeyTime="0:0:0.4" Value="90"/>
    </DoubleAnimationUsingKeyFrames>
    <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Projection).(PlaneProjection.RotationY)" Storyboard.TargetName="imgSmall">
    <EasingDoubleKeyFrame KeyTime="0:0:0.4" Value="-90"/>
    <EasingDoubleKeyFrame KeyTime="0:0:0.8" Value="0"/>
    </DoubleAnimationUsingKeyFrames>
    </Storyboard>
    <Storyboard x:Name="FlipClose">
    <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Projection).(PlaneProjection.RotationY)" Storyboard.TargetName="imgCapital">
    <SplineDoubleKeyFrame KeyTime="0:0:0.4" Value="90"/>
    <SplineDoubleKeyFrame KeyTime="0:0:0.8" Value="0"/>
    </DoubleAnimationUsingKeyFrames>
    <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Projection).(PlaneProjection.RotationY)" Storyboard.TargetName="imgSmall">
    <SplineDoubleKeyFrame KeyTime="0:0:0" Value="0"/>
    <SplineDoubleKeyFrame KeyTime="0:0:0.4" Value="-90"/>
    </DoubleAnimationUsingKeyFrames>
    </Storyboard>

    Actually i simply want flip card animation which is not working here in my code. When i tapped button to invoke animation its behavior not exactly flipping.  Its one side work properly but other collapsed suddenly not rotate if i keep mouse right at
    the button, but if i change mouse pointer at that very time after tapping it works properly. Mouse Pointer Over mean screen points where i tapped.
    Triggered Function is here:
      private void btnChangCase_Tapped(object sender, TappedRoutedEventArgs e)
                if(isCaseChanged==false)
                    isCaseChanged = true;
                    FlipOpen.Begin();
                else if(isCaseChanged==true)
                    isCaseChanged = false;
                    FlipClose.Begin();

  • Default azurewebsite continous deployment not working due to multiple solutions

    I am using default build template for build and deployment to azure web site. it was working when I had only my website solution to compile. but now I have modified input to build template and added other solution files also to compile, now my deployment
    step is not working. build log says
    "More than one solution found. Continuous Deployment skipped."
    I am using tfvcContinousDeploymentTemplate.12.xaml, in this template how can I have deployment, when I have multiple solutions for build.
    Thanks
    singhhome

    Hi singhhome,
    Please confirm whether you mean "modified input to build template" as change to use another build process template.
    When you use AzureContinuousDeployment.11.xaml, you can upgrade to a newer version of nuget.exe and check that version in with their solution and to see if it's a workaround. Or you can add the referenced assemblies into source control and check in.
    There are detailed instructions on the NuGet.org site about the various ways to do package restore.
    http://docs.nuget.org/docs/reference/package-restore
    http://docs.nuget.org/docs/reference/Package-Restore-with-Team-Build
    You can also set logging verbosity to "Diagnostic" as I mentioned above to see the detailed build log if there any issues occurred during the process. Another option is create a separate build definition for each solution to do the contrinuous
    build/deployment to Azure website.
    Best regards,
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • 6300 & Lotus Notes - Calander Alert Not Working

    Hi I have an O2 6300 & Lotus Notes ( v6 )and the phones calander alert not working / going off when it should.
    I've not changed any thing that I am aware of from the defaults and its less than a week or two old so I'm hoping its not a software OS bug and a user issue / some thing I have to switch on some where.
    Can any one help me ?
    Terran
    ( PS I noticed some N95 users had the same prob last year )

    Hi SaikatDas,
    Thank you for posting in MSDN forum.
    Since this forum is to discuss: Visual Studio WPF/SL Designer, Visual Studio Guidance Automation
    Toolkit, Developer Documentation and Help System, and Visual Studio Editor.
    Based on your issue, it is related to the IIS, so I’m afraid that it is not the correct forum for this issue. therefore, I suggest you can post this issue directly to the IIS forum:http://forums.iis.net/
    , maybe you will get better support.
    Thanks for your understanding.
    Best Regards,
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Automatic discovery not working if empty WebSphere Application Server folders in Windows registry

    We were trying to discover WebSphere 8.5.5 servers in our environment but the JEE MP couldn't find them. The discovery wrote this kind of error to the Windows Log:
    The process started at 8:56:25 AM failed to create System.Discovery.Data. Errors found in output:
    C:\Program Files\Microsoft Monitoring Agent\Agent\Health Service State\Monitoring Host Temporary Files 9\73626\Microsoft.JEE.WebSphere.Install.Discover.vbs(196, 1) Microsoft VBScript runtime error: Object not a collection
    Command executed: "C:\Windows\system32\cscript.exe" /nologo "Microsoft.JEE.WebSphere.Install.Discover.vbs" {10FEBF68-F318-4F09-8E6B-4567D66E2559} {014E39AA-B032-13EC-E5F1-3B880E645FFC} ServerName {D7E586A0-5480-9B71-F731-D3F15B3627FD} "8"
    Working Directory: C:\Program Files\Microsoft Monitoring Agent\Agent\Health Service State\Monitoring Host Temporary Files 9\73626\
    One or more workflows were affected by this.
    Workflow name: Microsoft.JEE.WebSphere.8.Windows.Installation.Discovery
    Instance name: ServerName
    Instance ID: {014E39AA-B032-13EC-E5F1-3B880E645FFC}
    Management group: SOKSCOM2012
    I investigated the discovery vbs script and Windows registry and found out that one of the users had empty WebSphere Application Server folder under Software/IBM in Windows registry. This was probably left after uninstallation of WAS. After I removed the
    empty registry entry then the auto-discovery found WAS instances.
    Would it be possible to enhance the discovery vbs script to exclude empty USER/Software/IBM/WebSphere Application Server key folder in the next version?

    I have contacted IIS forum support.
    Please review the link: http://forums.iis.net/p/1213109/2079229.aspx?Re+Windows+Server+2012+Printing+using+UNC+path+not+working
    Their final response:
    Printing from ASP.NET using System.Drawing.Printing itself is a horrible approach, as this namespace was designed for Windows Forms only. The designers did not take everything about ASP.NET in mind, so any issue can happen. That can answer why the HP model
    works while the Samsung fails, as the HP one just "happens
    to work",
    http://msdn.microsoft.com/en-us/library/system.drawing.printing.printdocument.aspx
    Similarly, System.Printing was designed just for WPF.
    About which printing API to use in ASP.NET/IIS, there is no clear answer so far. Thus, your only resource is Microsoft support, who can perform further analysis (with their dedicate utilities and of course Windows source code) and might come across a solution
    to help you out. This is not a trivial scenario.

  • Call Of Duty LAN Servers does not work after installing Mavericks on my Mac Air, I need help!

    Hey everyone, I have some troubles making LAN servers on Call of Duty 4 and people can't join them after installing Mavericks on my Macbook Air. I need help!
    Thx!

    Hi,
    You don’t install VS2010 on the client PC, then where did the Form Invoice not work? When you run it from another version of VS? Or when you run the application with application.exe?
    Based on your description, one form works well, another form does not. I assume that two forms are in two different projects, then please check the .Net Framework used by the two projects. If they are different, you can use the
    one used by the Form contact for Form Invoice.
    Because this issue is a project issue, I recommend you to consult it on some application forum such as Windows Forms General forum for better support.
    VS General Question forum mainly discusses
    the usage of Visual Studio IDE such as
    WPF & SL designer, Visual Studio Guidance Automation Toolkit, Developer Documentation and Help
    System and Visual Studio Editor.
    Thanks,
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • System.Windows.Drawing not working on server Environment (Windows 2008 and 2012 server) ?

    HI All,
    I am facing a problem from past few days on server environment. I have created the code for taking the screen shot of the windows as follow...This code is perfectly working in Run time environment. While running and debugging the application it is working
    fine. 
    But once i configured this website on Windows server 2008 or Server 2012 it is not working it hangs out the application at the method graphics.CopyFromScreen().
    I am unable to find out the solution for this from last few day's.  please help me to fix it. The code is as follow.
    Bitmap bitmap = new Bitmap(600, 500);
    Graphics graphics = Graphics.FromImage(bitmap as System.Drawing.Image);  // The application hangs at this pt
    graphics.CopyFromScreen(160, 235, 0, 0, bitmap.Size);
    string mappath = Server.MapPath("~/dimurl/image/");
    bitmap.Save(mappath + "myfile.jpeg", System.Drawing.Imaging.ImageFormat.Jpeg);
    Please help me to resolve this.
    Vaibhav Bhutkar, Jr. .Net Developer, Pune India.

    Hello Vaibhav,
    Welcome to MSDN forum.
    Your issue is out of support range of VS General Question forum which mainly discusses
    the usage of Visual Studio IDE such as WPF & SL designer, Visual Studio Guidance Automation Toolkit, Developer Documentation and Help System
    and Visual Studio Editor.
    If  your issue is on ASP.NET website, I suggest that you can consult your issue on ASP.NET forum:
    http://forums.asp.net/
     for better solution and support.
    Best regards,
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Windows Server 2012 - Printing using UNC path not working

    Hi,
    I have a problem printing using the printer's UNC path ("\\Server_Name\Printer_Hostname") to work with a web
    app hosted on IIS 8. With a windows forms application the UNC path is working fine and the app prints.
    With
    the web app I receive an error "The data area passed to a system call is tool small". 
    Also,
    in the event viewer under Applications and Services Logs -> Microsoft -> PrintService -> Operational, I receive the error "The print spooler failed to reopen an existing printer connection because it could not read the configuration information
    from the registry key S-1-5-82-1980832875-2702362896-1795126167-3622310632-1152289074\Printers\Connections. The print spooler could not open the registry key. This can occur if the registry key is corrupt or missing, or if the registry recently became unavailable."

    I have contacted IIS forum support.
    Please review the link: http://forums.iis.net/p/1213109/2079229.aspx?Re+Windows+Server+2012+Printing+using+UNC+path+not+working
    Their final response:
    Printing from ASP.NET using System.Drawing.Printing itself is a horrible approach, as this namespace was designed for Windows Forms only. The designers did not take everything about ASP.NET in mind, so any issue can happen. That can answer why the HP model
    works while the Samsung fails, as the HP one just "happens
    to work",
    http://msdn.microsoft.com/en-us/library/system.drawing.printing.printdocument.aspx
    Similarly, System.Printing was designed just for WPF.
    About which printing API to use in ASP.NET/IIS, there is no clear answer so far. Thus, your only resource is Microsoft support, who can perform further analysis (with their dedicate utilities and of course Windows source code) and might come across a solution
    to help you out. This is not a trivial scenario.

  • Windows 10 start menu not working, app settings gone, startup programs not starting (no tray icons) KB3034229 installed

    Hi, even after installing KB3034229 my start menu is gone, search does not work so I don't have any good way to start applications. I am worried because they say update fixes this error, but not for me :-(
    Most of my settings are also gone. I cannot revert back (getting error about moved account, but I did not move my account location after installing technical preview)
    Any help is much appreciated. Thank you!

    Actually, I decided to take a look around in the Event Viewer and saw that there were errors in the "Application" section under windows logs, with the message stating "Activation of app (Insert app name here with a bunch of characters after
    it) failed with error: The remote procedure call failed. See the Microsoft-Windows-TWinUI/Operational log for additional information." And a more specific error to do with ShellExperienceHost.exe  http://pastebin.com/c62Fm8xz
    . (Cant figure out how to change the font back, so ill stick with this one) All the errors in the Application tab in windows logs that are "Application Errors" all come from the faulting module "Windows.UI.Xaml.dll" After trying to open
    the start menu, an Application error (http://pastebin.com/WVktd0Ti) (Suddenly the font fixed itself, okay.) appeared. This is all on build 10041. The logs in "Microsoft-Windows-TWinUI/Operational" all contain something along the lines of this
    "Activation of the app Microsoft.Cortana_8wekyb3d8bbwe!CortanaUI for the Windows.Launch contract failed with error: The remote procedure call failed.."
    Hopefully this contains useful information to help fix this bug.
    EDIT:
    After looking up the error code from the log in "Microsoft-Windows-TWinUI/Operational" (https://support.microsoft.com/en-us/kb/2798317/) It seems to be a permissions issue maybe? I'll update this if I find a solution.

  • Not work tablet UI on Prestigio 5080 PRO tablet

    I read that browser.ui.layout.tablet = "1" can fix this problem. But it not works. I can work only in pnone interface that is not good for my 8'' tablet.

    Would it be possible for you to share the problematic pdf and OS information  with us at [email protected] so that we may investigate?
    Thanks,
    Adobe Reader Team

  • Why self-defined access sequences of free goods can not work?

    Hi gurus,
    I have maintained access sequences of free goods self-defined.but when i creat the SO it does not work!
    when i used the standard access sequences ,it is OK .
    Can anybody tell me why?
    thanks in advance

    Dear Sandy,
    Go to V/N1 transaction select your self defined access sequence then go in to the accesses and fields and check all fields are activated.
    Make sure that these fields are flowing in your sales order.
    I hope this will help you,
    Regards,
    Murali.

Maybe you are looking for

  • IMac starts with blank screen

    Hello, My iMac has been acting a little weird lately, until last night, when it got much worse. It's a 2009 iMac running Mavericks. Every so often when I would turn it on, it would give the Apple chime and the screen would never come on, it would rem

  • Formula for comparing dates and display data

    I have 3 objects on my query: Date, Product name and Quantity sold I have a table on my reports showing the top 3 products by quantity sold, and I want to add the quantity sold today on the same table. I am looking for a formula that compares de date

  • Mutilple Pages Report

    hi, I have a requirement that i have to print an agreement, which is three pages. Most of the contents are typing in the report, few fields will be inserting into the reports. I have total 10 fields. 1st page i need to display 3 fields, 2nd page anot

  • Installer freezes after download is done. Instantly goes into not responding when I try.

    Instantly says not responding the second I try to run it. I deleted the install file and tried to re-download, but I get the same problem. I don't know if it helps at all, but this is the error it was giving me in console when I would try to run it a

  • FORM 6I FOR WIN 98 & 9IAS FOR LINUX

    DEAR SIR/MADAM, IF I DEVELOP FORMS ON WIN98 PLATFORM. THEN UPLOAD OFORMS OBJECT TO 9IAS ENTERPRISE EDITION FOR LINUX SERVER FOR DEPLOY APLLICATION ON WEB. PLS ANSWER ME THIS ACCEPT OR NOT ? BEST REGARDS BILLY LEE null