Hello,
I'm trying to create two ListBoxes, where items can be transferred from one ListBox to the other. The problem is that when items are transferred the items do not look like the original (they are missing the bound image).
Here is the code I am using:
Any ideas what is going on?
Thanks,
Zeyad
I'm trying to create two ListBoxes, where items can be transferred from one ListBox to the other. The problem is that when items are transferred the items do not look like the original (they are missing the bound image).
Here is the code I am using:
<
telerik:RadListBox
runat
=
"server"
ID
=
"RadActorListBoxSource"
Height
=
"400px"
Width
=
"300px"
AllowTransfer
=
"true"
AllowTransferOnDoubleClick
=
"true"
ButtonSettings-ShowTransferAll
=
"false"
EnableDragAndDrop
=
"true"
TransferToID
=
"RadActorListBoxDestination"
SelectionMode
=
"Multiple"
DataSourceID
=
"LinqDataSource4"
CausesValidation
=
"false"
TransferMode
=
"Move"
DataValueField
=
"ActorId"
>
<
ItemTemplate
>
<
div
>
<
telerik:RadBinaryImage
runat
=
"server"
ID
=
"ActorImage"
Width
=
"50px"
DataValue='<%# ((Binary) Eval("ActorImage")).ToArray() %>'
AutoAdjustImageControlSize="False" />
<%# Eval("Name") %>
</
div
>
</
ItemTemplate
>
</
telerik:RadListBox
>
<
telerik:RadListBox
runat
=
"server"
ID
=
"RadActorListBoxDestination"
Height
=
"400px"
Width
=
"300px"
EnableDragAndDrop
=
"true"
TransferMode
=
"Move"
SelectionMode
=
"Multiple"
EmptyMessage
=
"Please select at least one actor"
CausesValidation
=
"true"
ValidationGroup
=
"addSceneSubmit"
>
<
ItemTemplate
>
<
div
>
<
telerik:RadBinaryImage
runat
=
"server"
ID
=
"ActorImage"
Width
=
"50px"
DataValue='<%# ((Binary) Eval("ActorImage")).ToArray() %>'
AutoAdjustImageControlSize="False" />
<%# Eval("Name") %>
</
div
>
</
ItemTemplate
>
</
telerik:RadListBox
>
<
asp:RequiredFieldValidator
ID
=
"RequiredFieldValidator8"
runat
=
"server"
ControlToValidate
=
"RadActorListBoxDestination"
ErrorMessage
=
"Please select at least one actor"
ValidationGroup
=
"addSceneSubmit"
>
</
asp:RequiredFieldValidator
>
<
asp:LinqDataSource
ID
=
"LinqDataSource4"
runat
=
"server"
ContextTypeName
=
"DataClassesDataContext"
OrderBy
=
"Name"
Select
=
"new (ActorId, Name, ActorImage)"
TableName
=
"Actors"
>
</
asp:LinqDataSource
>
Any ideas what is going on?
Thanks,
Zeyad