Ext:BooleanColumn,when editing ,it shows true or false value - ext.net

I have a grid and there is ext:BooleanColumn inside it,and I put a combobox for editing boolen colum.everything works fine ,except of this one .when I click boolen colum to edit,it shows false or true inside it,
I added a image what I trying to say.
how I can avoid this .thank you
and here is the my code :
<ext:BooleanColumn ID="BooleanColumn1" runat="server" DataIndex="BorcOdendimi" TrueText="odendi" Text="ödenme durumu"
FalseText="odenmedi" >
<Editor>
<ext:ComboBox runat="server" Text="odendi durumu" Editable="false">
<Items>
<ext:ListItem Text="Odendi" Value="1" />
<ext:ListItem Text="Odenmedi" Value="0" />
</Items>
</ext:ComboBox>
</Editor>
</ext:BooleanColumn>

To get it working the Values of the ComboBox's Items should match the values of a BooleanColumn. Currently, true/false (BooleanColumn's values) doesn't match 1/0 (ComboBox Items' values).
You can replace the existing ComboBox's Items with:
<ext:ListItem Text="Odendi" Value="true" Mode="Raw" />
<ext:ListItem Text="Odenmedi" Value="false" Mode="Raw" />
Answered in the Ext.NET forums thread.

Related

ShowExportToExcelButton is not displayed in Telerik RadGrid with less than 10 records

I'm using CommandItemSettings with ShowExportToExcelButton = true to have a button to export to Excel in the RadGrid's MasterTableView.
The Export button is displayed when I have at least 10 records or after Paging event if the next page has less than 10 records.
However, when I do a search and the resulting grid has less than 10 records, the Export button is not displayed.
<telerik:RadAjaxPanel ID="RadAjaxPanel2" runat="server" LoadingPanelID="RadAjaxLoadingPanel2" PostBackControls="btnExport" ClientEvents-OnRequestStart="requestStart" >
<telerik:RadGrid
...all the settings are defined here
>
<MasterTableView AllowNaturalSort="false" CommandItemDisplay="Bottom">
<CommandItemSettings ShowExportToExcelButton="true" ShowAddNewRecordButton="false" ShowRefreshButton="false" />
<CommandItemStyle HorizontalAlign="Right" />
<PagerStyle AlwaysVisible="true" Mode="NextPrevAndNumeric" PageSizes="10,25,50,100" />
<Columns>
<telerik:GridBoundColumn DataField="Moss2 MID" HeaderText="MOSS2 MID" AllowSorting="false" DataFormatString="{0:#}"></telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="DBA" HeaderText="DBA" HeaderStyle-Width="250px">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="Original MID" HeaderText="ORIGINAL MID" AllowSorting="false" DataFormatString="{0:#}"></telerik:GridBoundColumn>
<telerik:GridBoundColumn
DataField="BoardingDate"
DataType="System.DateTime"
HtmlEncode="false"
DataFormatString="{0:MM/dd/yyyy}"
SortExpression="BoardingDate"
UniqueName="BoardingDate"
HeaderText="BOARDING DATE"
HeaderStyle-Width="170px"
ShowFilterIcon="false"
/>
<telerik:GridBoundColumn DataField="Status" HeaderText="STATUS" AllowSorting="false"></telerik:GridBoundColumn>
</Columns>
</MasterTableView>
</telerik:RadGrid>
</telerik:RadAjaxPanel>
RadGrid is defined inside of RadAjaxPanel as I showed above and Search button is defined in its own RadAjaxPanel as well with a calendar controls to search by date:
<telerik:RadAjaxPanel ID="RadAjaxPanel1" runat="server">
.
.
.
Calendar controls are going here....
.
.
.
<telerik:RadButton RenderMode="Lightweight" runat="server" Text="Search" ID="btnSearch" OnClick="btnSearch_Click"/>
</telerik:RadAjaxPanel>
And I use RadAjaxmanager where I hook the Search button with the grid:
<telerik:RadAjaxManager ID="RadAjaxManager" runat="server" EnableAJAX="true" OnAjaxSettingCreated="RadAjaxManager1_AjaxSettingCreated">
<AjaxSettings>
<telerik:AjaxSetting AjaxControlID="btnSearch">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="grdMoss2Merchants" LoadingPanelID="RadAjaxLoadingPanel2"></telerik:AjaxUpdatedControl>
</UpdatedControls>
</telerik:AjaxSetting>
</AjaxSettings>
</telerik:RadAjaxManager>
What am I doing wrong here?
I've been trying to solve that for the past 2 days with no luck.

In ext.net, how do I align a tabpanel button to the right?

I would like to align the button of the right, but keep the content tabs on the left. This is my code:
<ext:TabPanel ID="TabPanel1" runat="server" Height="295" Plain="true" DeferredRender="false" meta:resourcekey="TabPanel1Resource1">
<TabBar>
<ext:Button runat="server" Icon="ArrowOut" meta:resourcekey="fullscreenResource1">
<DirectEvents>
<Click OnEvent="edit_fullOpenAdd" />
</DirectEvents>
</ext:Button>
</TabBar>
<Defaults>
<ext:Parameter Name="autoScroll" Value="true" Mode="Raw" />
</Defaults>
<Items>
......the content ......
</Items>
</ext:TabPanel>
Any Ideas?
Thank you!
Edit: I was told to try tabCls: 'right-tab', but I do not know how to implement this.
Use TabStrip control.
Please see this example: http://examples.ext.net/#/TabPanel/TabStrip/Overview/

Adding dynamic column using trinidad by clicking on a link in JSF 1.2

<trh:tableLayout width="25%" borderWidth="3" cellSpacing="5"
halign="center" >
<h:commandLink action="#{dataBean.setInitial}" value="ShowView">
</h:commandLink>
<trh:rowLayout shortDesc="head">
<tr:panelHeader size="4" text="Id" />
<tr:forEach var="row" begin="0" end="#{dataBean.size}" items="#{dataBean.dataList}">
<tr:outputText value="#{row.id}" rendered="#{row.editable}"/>
</tr:forEach>
</trh:rowLayout>
<trh:rowLayout>
<tr:panelHeader size="4" text="Name" />
<tr:forEach var="row" begin="0" end="#{dataBean.size}" items="#{dataBean.dataList}">
<tr:outputText value="#{row.text}" rendered="#{row.editable}" />
</tr:forEach>
</trh:rowLayout>
</trh:tableLayout>
I am using trh tags in trinidad to display row wise data ..
and output is like...
Show View
ID 2 1
Name raj Narendra
I want to add a dynamic column in row wise by clicking on link show view..If i click back on show view it should hide that column...Please suggest me how to add rendered attribute and where it should be..
Why don't you use
Something like this:
<tr:commandLink action="#{dataBean.setInitial}" value="ShowView" id="showHideLink"/>
<tr:table value="#{dataBean.dataList}" var="row" id="itemTable" partialTrigger="showHideLink">
<tr:column rendered="#{row.column1Visible}" id="itemCol">
<tr:outputText value="#{row.text1}"/>
</tr:column>
<tr:column rendered="#{row.column2Visible}" id="itemCol">
<tr:outputText value="#{row.text2}"/>
</tr:column>
</tr:table>
In order to get the table to refresh when you click the link, set the partialTrigger property of the table to the id of the button.
To control the visibility of the columns you'll need to use the objects in the dataList.
For example, you could have the fields column1Visible and column2Visible in those objects (with public getters and setters).

Get selected values from MultiCombo in Ext.NEt via JS

I am using Ext.Net I have a form with a ComboBox which I have just changed to a MultiCombo.
Previously I used "SelectEnquiry.getValues()" to retrieve the selected item and pass it into a parameter used with a Button Direct Event.
How do I get the selected values when using the MultiCombo?
Combo Box Bit
<ext:MultiCombo runat="server" ID="SelectEnquiry" FieldLabel="Enquiry" AnchorHorizontal="95%" Editable="false" ValueField="Id" DisplayField="ProviderName" TypeAhead="true" Mode="Local" ForceSelection="true" TriggerAction="All" EmptyText="Select Enquiry" ValueNotFoundText="Select Enquiry" ItemSelector="div.list-item" SelectOnFocus="true" AllowBlank="false">
Button form submit bit
<ext:Button runat="server" ID="ButtonEmailTaskAccept" Text="OK">
<Listeners>
<Click Handler="if (PanelUnlinked.isVisible() && !$form.validate( [SelectProject, SelectEnquiry])) return false;">
</Click>
</Listeners>
<DirectEvents>
<Click Url='<%# Url.Action("CompleteEmailTask") %>' AutoDataBind="true"
Success="window.$messageBus.publish('task-admin', 'inbox-changed');
window.$messageBus.publish('task-admin', 'task-changed');
WindowAssignEmail.close()" Failure="$shell.requestFailedHandler(response, null)"
Json="true">
<EventMask ShowMask="true"></EventMask>
<ExtraParams>
<ext:Parameter Name="emailResponseId" Value="<%# Model.EmailResponse.Id %>" Mode="Value"
AutoDataBind="true" />
<ext:Parameter Name="enquiryId" Value="SelectEnquiry.getValues()" Mode="Raw" />
<ext:Parameter Name="documentList" Value="buildSelectionList()" Mode="Raw" />
</ExtraParams>
</Click>
</DirectEvents>
</ext:Button>
With <ext:MultiCombo> you can just call .getValue() to return an Array of selected values. I'll look into adding .getValues() as well, so it's consistent with the <ext:ComboBox> api.
Edit
It appears the ComboBox does not have a client-side .getValues() function, so we won't be adding to the MultiCombo. Just use .getValue(), which is standardised across all Form Fields.
The problem seemed to be that it could not locate the control I was try to get the value from.
So managed to solve it by doing:
#{SelectEnquiry}.getSelectedValues()

Ribbon button should be hidden based on lead status - CRM 2011

I have custom button in lead ribbon. The custom button should be hidden when lead is qualified. How can I do that? Can any one please explain. I appreciate.
You can actually accomplish this entirely with built-in DisplayRule functionality. When a Lead is qualified, the StatusCode property is set to "Qualified", which translates into an OptionSet value of "3". You can check for the value of this property in a ValueRule and display/hide the control appropriately. I can think of two ways to achieve this:
Erik Pool's Visual Ribbon Editor
RibbonXml
<RibbonDiffXml>
<CustomActions>
<CustomAction Id="CompanyName.Form.lead.MainTab.Actions.Sample.CustomAction" Location="Mscrm.Form.lead.MainTab.Actions.Controls._children" Sequence="41">
<CommandUIDefinition>
<Button Id="CompanyName.Form.lead.MainTab.Actions.Sample" Command="CompanyName.Form.lead.MainTab.Actions.Sample.Command" Sequence="29" ToolTipTitle="$LocLabels:CompanyName.Form.lead.MainTab.Actions.Sample.LabelText" LabelText="$LocLabels:CompanyName.Form.lead.MainTab.Actions.Sample.LabelText" ToolTipDescription="$LocLabels:CompanyName.Form.lead.MainTab.Actions.Sample.Description" TemplateAlias="isv" />
</CommandUIDefinition>
</CustomAction>
</CustomActions>
<Templates>
<RibbonTemplates Id="Mscrm.Templates"></RibbonTemplates>
</Templates>
<CommandDefinitions>
<CommandDefinition Id="CompanyName.Form.lead.MainTab.Actions.Sample.Command">
<EnableRules />
<DisplayRules>
<DisplayRule Id="CompanyName.Form.lead.MainTab.Actions.Sample.Command.DisplayRule.ValueRule" />
</DisplayRules>
<Actions>
<Url Address="http://www.bing.com" />
</Actions>
</CommandDefinition>
</CommandDefinitions>
<RuleDefinitions>
<TabDisplayRules />
<DisplayRules>
<DisplayRule Id="CompanyName.Form.lead.MainTab.Actions.Sample.Command.DisplayRule.ValueRule">
<ValueRule Field="statuscode" Value="3" />
</DisplayRule>
</DisplayRules>
<EnableRules />
</RuleDefinitions>
<LocLabels>
<LocLabel Id="CompanyName.Form.lead.MainTab.Actions.Sample.LabelText">
<Titles>
<Title languagecode="1033" description="Sample" />
</Titles>
</LocLabel>
<LocLabel Id="CompanyName.Form.lead.MainTab.Actions.Sample.Description">
<Titles>
<Title languagecode="1033" description="Sample Description" />
</Titles>
</LocLabel>
</LocLabels>
</RibbonDiffXml>

Resources