I'm trying to bind data from the back end to XML view.
Here is my List control definition:
<List items="{path : '/ZZMM_VDB_DETAILSet', parameters:{expand: 'ZZMM_VDB_DETAIL_TO_MATKLSSet'}}">
<items>
<CustomListItem>
<content>
<List items="{path: 'ZZMM_VDB_DETAIL_TO_MATKLSSet'}">
<items>
<ObjectListItem title="Matkl : {Matkl}"></ObjectListItem>
</items>
</List>
</content>
</CustomListItem>
</items>
</List>
I want to display the data of the expanded entity set which consists of 16 objects.
What I get displayed is 15 times object before the last one (array element number 14) and the last row is the data of the last array element (number 15).
What do I miss here?
Related
I want to clear all contents in all LayoutGroups.
So I use
<dx:ASPxPopupControl ID="AspxPopUPDeneme" runat="server" ClientInstanceName="AspxPopUPDeneme" ClientSideEvents-Closing="function(s,e){ASPxClientEdit.ClearEditorsInContainerById('form_clear');}">
<ContentCollection>
<dx:PopupControlContentControl>
<div id="form_clear">
<dx:ASPxFormLayout ID="ASPxFormLayoutDeneme" runat="server" ClientInstanceName="ASPxFormLayoutDeneme">
<Items>
<dx:TabbedLayoutGroup>
<Items>
<dx:LayoutGroup>....</dx:LayoutGroup>
<dx:LayoutGroup>....</dx:LayoutGroup>
</Items>
</dx:TabbedLayoutGroup>
</Items>
</dx:ASPxFormLayout>
</div>
But this method only clear active LayoutGroup when I closing the PopUp.
My problem as shown in this image
How can I solve this problem?
By default, ClearEditorsInContainerById clears all visible editors (i.e. in active tab) that belongs to a container group given by certain containerId. To include invisible editors on other tab, use 3-argument version of ClearEditorsInContainerById as shown below:
function clearAllOnClose(s, e)
{
ASPxClientEdit.ClearEditorsInContainerById('form_clear', null, true);
}
<dx:ASPxPopupControl ID="AspxPopUPDeneme" runat="server" ClientInstanceName="AspxPopUPDeneme"
ClientSideEvents-Closing="clearAllOnClose">
<ContentCollection>
<dx:PopupControlContentControl runat="server">
<div id="form_clear">
<dx:ASPxFormLayout ID="ASPxFormLayoutDeneme" runat="server" ClientInstanceName="ASPxFormLayoutDeneme">
<Items>
<dx:TabbedLayoutGroup>
<Items>
<dx:LayoutGroup>....</dx:LayoutGroup>
<dx:LayoutGroup>....</dx:LayoutGroup>
</Items>
</dx:TabbedLayoutGroup>
</Items>
</dx:ASPxFormLayout>
</div>
</dx:PopupControlContentControl>
</ContentCollection>
</dx:ASPxPopupControl>
Setting true in third argument means that null values are assigned to all controls under form_clear div container, regardless of their visibility status.
Note from documentation:
If the validationGroup parameter is set to null, the method clears
all/visible (under the clearInvisibleEditors parameter value) editors
located within the specified container.
Reference:
DevExpress Documentation: ClearEditorsInContainerById
Say I have a sequence of items,
<items>
<item>B</item>
<item>D</item>
<item>A</item>
<item>B</item>
<item>C</item>
</items>
and I want to capture all sequences of A- and B-items
<items>
<item>B</item>
<item>D</item>
<hit>
<item>A</item>
<item>B</item>
</hit>
<item>C</item>
</items>
Can this be done with XQuery? When iterating, the context item is singular.
I can get
<items>
<item>B</item>
<item>D</item>
<hit-start><item>A</item></hit-start>
<hit-end><item>B</item></hit-end>
<item>C</item>
</items>
but that does not help, nor does
<items>
<item>B</item>
<item>D</item>
<hit-start/>
<item>A</item>
<item>B</item>
<hit-end/>
<item>C</item>
</items>
You can "look around" using preceding-sibling and following sibling.
<items>{
for $item in $xml/items/item
return
if ($item = "A" and $item/following-sibling::item[1] = "B")
then (
<hit-start/>,
<item>A</item>,
<item>B</item>,
<hit-end/>
)
else
$item[not(preceding-sibling::item[1] = "A")]
}</items>
I have a table user in my database containing 2 columns first name and last name.
I want to populate a drop down list so the user can choose from the drop down list a person according to his first and last name.
So how can i enter first and last name into one drop down list?
This my drop down list so far.
<telerik:GridDropDownColumn DataField="DepIDVoit"
HeaderText="Voiture" UniqueName="IdVoiture4"
ListTextField="VMarque" DropDownControlType="DropDownList"
ListValueField="VVID" FilterControlAltText="Filter VMarque column"
ShowFilterIcon="false" CurrentFilterFunction="Contains"
AutoPostBackOnFilter="true"
DataSourceID="SqlDataSource3">
<ColumnValidationSettings
EnableRequiredFieldValidation="true" >
<RequiredFieldValidator ForeColor="Red"
ErrorMessage="* Mandatory Field">
</RequiredFieldValidator>
</ColumnValidationSettings>
</telerik:GridDropDownColumn>
I want to put in the ListTextField : VMarque and VModel separeted with a space
I am using a simple Repeater which has a single component(TextInput).
<mx:Repeater id="myrep" dataProvider="{myAC}" >
<local:TextInputRepeater id="tiRepeater" displaytext="{myrep.currentItem}" />
</mx:Repeater>
<mx:Button label="Get Data" click="getNewValues(event)" />
The repeater has following code:
[Bindable]
public var displaytext:String = "";
<mx:TextInput id="repeatText" text="{displaytext}" change="repeatText_changeHandler(event)"/>
Here is what I want : on click of button in getNewValues function, I want to read the values (user might possibly have changed in the textInputs).
Well, it was a silly issue which I overlooked.
Solution is, tiRepeater[index] will give you the udpated repeater object.
I'm attempting to use a Silverlight ComboBox with a static list of elements in a very simple binding scenario. The problem is the selected item is not returning me the Text of the TextBlock within the ComboBox and is instead returning "System.Windows.Controls.TextBlock".
My XAML is:
<ComboBox SelectedValue="{Binding Country, Mode=TwoWay, NotifyOnValidationError=True, ValidatesOnExceptions=True}">
<TextBlock FontSize="11" Text="Afghanistan" />
<TextBlock FontSize="11" Text="Albania" />
<TextBlock FontSize="11" Text="Algeria" />
</ComboBox>
In my C# file I'm binding to the ComboBox using:
Customer customer = new Customer() { Country = "Albania" };
DataContext = customer;
The binding does not result in Albania as the selected country and updating the ComboBox choice results in the Country being set to "System.Windows.Controls.TextBlock". I've tried fiddling around with DisplayMemberPath and SelectedValuePath but haven't found the answer. I suspect it's something really simple I'm missing.
Changing the ComboBox items to strings works. I'm not sure how you'd go about handling the case where TextBlocks were required for formatting...
<ComboBox SelectedValue="{Binding Country, Mode=TwoWay, NotifyOnValidationError=True, ValidatesOnExceptions=True}">
<System:String>Afghanistan</System:String>
<System:String>Albania</System:String>
<System:String>Algeria</System:String>
</ComboBox>