golgepapaz
Topic Author
Posts: 43
Joined: 01 Aug 2013, 01:59

[Unity] Exception when setting ProgressBar ControlTemplate

13 May 2014, 13:43

Hi all,

I am getting following exception when setting ProgressBar control template at v1.1.5.
{{{
Unhandled exception at 0x457EED8F: Access Violation reading location 0x000000FC
}}}
{{{
[ 0] [0x457EED8F] Noesis.dll!Noesis::Gui::UIElement::TryGetEventHandlerRecursive + 0x10f bytes
[ 1] [0x457F097C] Noesis.dll!Noesis::Gui::UIElement::Serialize + 0xdc bytes
[ 2] [0x457F1062] Noesis.dll!Noesis::Gui::UIElement::AddHandler + 0x12 bytes
[ 3] [0x45777E09] Noesis.dll!Noesis::Gui::ProgressBar::OnTemplateChanged + 0x189 bytes
[ 4] [0x4570C80B] Noesis.dll!Noesis::Gui::FrameworkElement::SetFrameworkTemplate + 0x18b bytes
[ 5] [0x456E595D] Noesis.dll!Noesis::Gui::Control::OnPropertyChanged + 0x4d bytes
[ 6] [0x45782FB1] Noesis.dll!Noesis::Gui::RangeBase::OnPropertyChanged + 0x11 bytes
[ 7] [0x45777830] Noesis.dll!Noesis::Gui::ProgressBar::OnPropertyChanged + 0x10 bytes
[ 8] [0x4588484D] Noesis.dll!Noesis::Gui::GridViewColumnHeader::OnTemplateChanged + 0x69d bytes
[ 9] [0x456EACD2] Noesis.dll!Noesis::Gui::TextElement::operator= + 0x4d52 bytes
[10] [0x456ECDE9] Noesis.dll!Noesis::Gui::TextElement::operator= + 0x6e69 bytes
[11] [0x456EE904] Noesis.dll!Noesis::Gui::TextElement::operator= + 0x8984 bytes
[12] [0x456549C9] Noesis.dll!Noesis::Gui::DependencyObject::InternalInvalidateProperty + 0x149 bytes
[13] [0x45654E9A] Noesis.dll!Noesis::Gui::DependencyObject::InvalidateProperty + 0x5a bytes
[14] [0x456A5CEB] Noesis.dll!Noesis::Gui::BaseStyleSetterProvider::InvalidateSettersFromStyle + 0x7b bytes
[15] [0x456A5D54] Noesis.dll!Noesis::Gui::BaseStyleSetterProvider::InvalidateSetters + 0x14 bytes
[16] [0x457BCCA2] Noesis.dll!Noesis::Gui::StyleSetterProvider::OnPropertyChanged + 0x62 bytes
[17] [0x458842B8] Noesis.dll!Noesis::Gui::GridViewColumnHeader::OnTemplateChanged + 0x108 bytes
[18] [0x45979EE0] Noesis.dll!BindEvent_Timeline_Completed + 0x2b0 bytes
[19] [0x45652F84] Noesis.dll!Noesis::Gui::DependencyObject::OnPropertyChanged + 0x34 bytes
[20] [0x45801120] Noesis.dll!Noesis::Gui::Visual::OnPropertyChanged + 0x10 bytes
[21] [0x457F5123] Noesis.dll!Noesis::Gui::UIElement::OnPropertyChanged + 0x13 bytes
[22] [0x4570BF68] Noesis.dll!Noesis::Gui::FrameworkElement::OnPropertyChanged + 0x28 bytes
[23] [0x456E5936] Noesis.dll!Noesis::Gui::Control::OnPropertyChanged + 0x26 bytes
[24] [0x45782FB1] Noesis.dll!Noesis::Gui::RangeBase::OnPropertyChanged + 0x11 bytes
[25] [0x45777830] Noesis.dll!Noesis::Gui::ProgressBar::OnPropertyChanged + 0x10 bytes
[26] [0x4565565B] Noesis.dll!Noesis::Gui::DependencyObject::Init + 0x45b bytes
[27] [0x456C3DAD] Noesis.dll!Noesis::Gui::Collection::Init + 0x7d bytes
[28] [0x45655248] Noesis.dll!Noesis::Gui::DependencyObject::Init + 0x48 bytes
[29] [0x456C3DAD] Noesis.dll!Noesis::Gui::Collection::Init + 0x7d bytes
[30] [0x45722209] Noesis.dll!Noesis::Gui::Grid::OnInit + 0x9 bytes
[31] [0x456555B0] Noesis.dll!Noesis::Gui::DependencyObject::Init + 0x3b0 bytes
[32] [0x456C3DAD] Noesis.dll!Noesis::Gui::Collection::Init + 0x7d bytes
[33] [0x45722209] Noesis.dll!Noesis::Gui::Grid::OnInit + 0x9 bytes
[34] [0x457FBA70] Noesis.dll!Noesis::Gui::UIResource::InitTree + 0x1c0 bytes
[35] [0x457FBB9E] Noesis.dll!Noesis::Gui::UIResource::OnInitInternal + 0x9e bytes
[36] [0x457FBD83] Noesis.dll!Noesis::Gui::UIResource::OnInit + 0x53 bytes
[37] [0x455847CA] Noesis.dll!Noesis::Resource::BaseResource::Init + 0xa bytes
[38] [0x45587119] Noesis.dll!Noesis::File::FileId::~FileId + 0x1149 bytes
[39] [0x455871AF] Noesis.dll!Noesis::File::FileId::~FileId + 0x11df bytes
[40] [0x4578847D] Noesis.dll!Noesis::Gui::RendererLayout::~RendererLayout + 0xdcd bytes
[41] [0x457884F0] Noesis.dll!Noesis::Gui::LoadXaml + 0x30 bytes
[42] [0x4597AEB4] Noesis.dll!Noesis_LoadXAML + 0xd4 bytes
[43] [0x0A1E9232] mono.dll!mono_g_hash_table_lookup + 0x9b3 bytes
[44] [0x0A2F01EE] mono.dll!unity_mono_install_memory_callbacks + 0x8c50 bytes
[45] [0x0A1E1D3D] mono.dll!g_free + 0x316 bytes
}}}
Here is the XAML,
<UserControl
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    Width="Auto"
    Height="Auto"
    x:Class="GuiTestUserControl">
    <Grid>
        <Grid.Resources>
            <Style
                x:Key="progressPie"
                TargetType="{x:Type ProgressBar}">
                <Setter
                    Property="Template">
                    <Setter.Value>
                        <ControlTemplate
                            TargetType="{x:Type ProgressBar}">
                            <Border />
                        </ControlTemplate>
                    </Setter.Value>
                </Setter>
            </Style>
        </Grid.Resources>
            <ProgressBar
                x:Name="progressBar"
                Style="{StaticResource progressPie}">
            </ProgressBar>
    </Grid>
</UserControl>
Is there something wrong about code?

Thanks.
 
User avatar
sfernandez
Site Admin
Posts: 1912
Joined: 22 Dec 2011, 19:20

Re: [Unity] Exception when setting ProgressBar ControlTempla

16 May 2014, 10:26

Hi, sorry for the late answer.

There is a problem in our internal code that is assuming that ProgressBar template always contains a "PART_Track" and "PART_Indicator" elements. We have to make it optional.

We will fix it for the next release.
 
golgepapaz
Topic Author
Posts: 43
Joined: 01 Aug 2013, 01:59

Re: [Unity] Exception when setting ProgressBar ControlTempla

16 May 2014, 14:18

Alright, thanks for the timely response :).
 
User avatar
sfernandez
Site Admin
Posts: 1912
Joined: 22 Dec 2011, 19:20

Re: [Unity] Exception when setting ProgressBar ControlTempla

20 May 2014, 11:28

This issue was resolved in 1.1.8 version.

Who is online

Users browsing this forum: No registered users and 1 guest