danparker276
Top achievements
Rank 2
danparker276
asked on 30 Oct 2013, 10:52 PM
So, this is a Silverlight known bug they won't fix, but I'm wondering if there would be any workaround with Telerik and the RadListBox vs the regular Listbox? (I'm guessing no).
https://connect.microsoft.com/VisualStudio/feedback/details/675390/silverlight-using-shift-in-extended-selection-mode-in-a-listbox-does-not-honor-disabled-listboxitems#tabs
https://connect.microsoft.com/VisualStudio/feedback/details/675390/silverlight-using-shift-in-extended-selection-mode-in-a-listbox-does-not-honor-disabled-listboxitems#tabs
4 Answers, 1 is accepted
0
Hi Dan,
This issue doesn't exist in RadListBox - I've attached a sample project for your convenience. Could you give it a try and inform us in case you have any problems or concerns?
Hope this helps.
Regards,
Rosen Vladimirov
Telerik
This issue doesn't exist in RadListBox - I've attached a sample project for your convenience. Could you give it a try and inform us in case you have any problems or concerns?
Hope this helps.
Regards,
Rosen Vladimirov
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
0
danparker276
Top achievements
Rank 2
answered on 05 Nov 2013, 05:25 PM
I can't use isEnabled though. I want to use IsHitTestVisible which doesn't work in a template like below. Well I guess I could use isEnabled if it's not grayed out.
I use it in a template like below
I use it in a template like below
<
telerik:RadListBox
Name
=
"rlbTemplate"
Height
=
"300"
SelectionMode
=
"Extended"
>
<
telerik:RadListBox.Resources
>
<
Style
TargetType
=
"ListBoxItem"
>
<
Setter
Property
=
"IsHitTestVisible"
Value
=
"{Binding isHitTestVisible}"
/>
</
Style
>
</
telerik:RadListBox.Resources
>
<
telerik:RadListBox.ItemTemplate
>
<
DataTemplate
>
<
TextBlock
Text
=
"{Binding Display}"
/>
</
DataTemplate
>
</
telerik:RadListBox.ItemTemplate
>
</
telerik:RadListBox
>
namespace
RadListBox_SL_753414
{
public
class
largeObject
{
public
string
Display
{
get
;
set
; }
public
bool
isHitTestVisible
{
get
;
set
; }
}
public
partial
class
MainPage : UserControl
{
public
MainPage()
{
InitializeComponent();
List<largeObject> llo =
new
List<largeObject>();
for
(
int
i = 0; i < 100; i++)
{
largeObject lo =
new
largeObject();
lo.Display=
"item number: "
+ i;
if
(i % 5 == 0)
{
lo.isHitTestVisible =
false
;
}
else
{
lo.isHitTestVisible =
true
;
}
llo.Add(lo);
}
rlbTemplate.ItemsSource = llo;
// rlbTemplate2.ItemsSource = llo;
}
}
}
0
Accepted
Hi Dan,
Using IsHitTestVisible is not an option in such scenario - one item could be selected, but with IsHitTestVisible to false. If you want to modify the Disabled state, you have to modify RadListBoxItem template - if you remove the Disabled state from the VisualStates, the disabled items will look just like all the other items.
I've modified the sample project to show you how to achieve this. The modified implicit style is in App.xaml. Could you give it a try and inform us in case you have any problems or concerns?
Regards,
Rosen Vladimirov
Telerik
Using IsHitTestVisible is not an option in such scenario - one item could be selected, but with IsHitTestVisible to false. If you want to modify the Disabled state, you have to modify RadListBoxItem template - if you remove the Disabled state from the VisualStates, the disabled items will look just like all the other items.
I've modified the sample project to show you how to achieve this. The modified implicit style is in App.xaml. Could you give it a try and inform us in case you have any problems or concerns?
Regards,
Rosen Vladimirov
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
0
danparker276
Top achievements
Rank 2
answered on 09 Nov 2013, 12:29 AM
Yes this works great, Thank you