iSeller Commerce
iSeller POS Retail
iSeller POS F&B
iSeller POS Express
Crosslight
WebUI
ClientUI
What's New
Download Trial
Web Solution
Mobile Solution
Enterprise Solution
Custom Development
Blog
Community
Latest Development Blogs
ForumPostTopic
Browse By Tag
Hi,
I can see that "ClientBinding" need some more attention from your QA, it has many issues that delayed our project, and however the performance benefit is a plus.
Now, I've WebGrid set BindingOperationMode="ClientBinding". And as soon as I do that, the checkboxes for Boolean data doesn't get the data correctly from the database, so if the data field is true, the checkbox still remain unchecked!
I realty like to get this fixed ASAP without any delay, its not show stopper to my project.
Just to save time on this, the load function is getting the boolean value correctly (I traced it), and next is the GRID config:
<ISWebGrid:WebGrid ID="TransactionsWebGrid" runat="server" DefaultStyleMode="Win7" Height="322px" UseDefaultStyle="True" Width="99%" BindingOperationMode="ClientBinding" > <LayoutSettings AllowColumnSizing="No" AllowContextMenu="False" AllowEdit="Yes" AllowSorting="Yes" AlwaysShowHelpButton="True" ColumnSetHeaders="Default" EditOnClick="True" FilterBarVisible="False" InProgressUIBehavior="ChangeCursorToHourGlass" RowHeaders="Default" ShowRefreshButton="True" AllowBatchUpdate="False" NewRowLostFocusAction="AlwaysUpdate" > <BatchUpdateSettings AllowReviewChanges="True" /> <ClientSideEvents OnBatchUpdateSuccess="TransactionsWebGrid_OnBatchUpdateSuccess" /> </LayoutSettings> <RootTable Caption="MembershipTransactions" DataKeyField="MembershipTransactionID" > <Columns> <ISWebGrid:WebGridColumn Caption="Date" DataMember="TransactionDate" EditType="NoEdit" Name="TransactionDate" Width="70px" DataFormatString="d" DataType="System.DateTime"> <HeaderStyle Cursor="Hand" Font-Italic="True" Font-Underline="True" HorizontalAlign="Center" /> </ISWebGrid:WebGridColumn> <ISWebGrid:WebGridColumn Caption="Amount" DataMember="Amount" Name="Amount" EditType="NoEdit" Width="55px" DataType="System.Decimal"> <HeaderStyle Cursor="Hand" Font-Italic="True" Font-Underline="True" HorizontalAlign="Center" /> </ISWebGrid:WebGridColumn> <ISWebGrid:WebGridColumn Caption="Cheque No" DataMember="ChequeNo" Name="ChequeNo" EditType="NoEdit" Width="125px" DataType="System.Decimal"> <HeaderStyle Cursor="Hand" Font-Italic="True" Font-Underline="True" HorizontalAlign="Center" /> </ISWebGrid:WebGridColumn> <ISWebGrid:WebGridColumn Caption="Credit-Card No" DataMember="CreditCardNo" Name="CreditCardNo" EditType="NoEdit" Width="125px" DataType="System.Decimal"> <HeaderStyle Cursor="Hand" Font-Italic="True" Font-Underline="True" HorizontalAlign="Center" /> </ISWebGrid:WebGridColumn> <ISWebGrid:WebGridColumn Name="Processed" Width="60px" Caption="Processed" DataMember="Processed" DataType="System.Boolean" EditType="Checkbox" ColumnType="CheckBox"> <HeaderStyle Cursor="Hand" Font-Italic="True" Font-Underline="True" HorizontalAlign="Center" /> </ISWebGrid:WebGridColumn> <ISWebGrid:WebGridColumn Caption="Process Date" CustomEditorName="VistaCalendar" DataFormatString="d" DataMember="ProcessDate" DataType="System.DateTime" EditType="Custom" Name="ProcessDate" Width="70px"> <HeaderStyle Cursor="Hand" Font-Italic="True" Font-Underline="True" HorizontalAlign="Center" /> </ISWebGrid:WebGridColumn> <ISWebGrid:WebGridColumn Caption="Reference" Name="ReferenceNo" Width="80px" DataMember="ReferenceNo"> <HeaderStyle Cursor="Hand" Font-Italic="True" Font-Underline="True" HorizontalAlign="Center" /> </ISWebGrid:WebGridColumn> <ISWebGrid:WebGridColumn Caption="Note" DataMember="Note" Name="Note" Width="95px"> <HeaderStyle Cursor="Hand" Font-Italic="True" Font-Underline="True" HorizontalAlign="Center" /> </ISWebGrid:WebGridColumn> </Columns> </RootTable> <ClientBindingSettings DataSourceType="WebService" ServiceUrl="../MembershipDataService.asmx" ItemTypeName="MembershipTransaction" DataLoadMode="AllData"> <ServiceMethods SelectMethod="GetMembershipTransactions" UpdateMethod="UpdateMembershipTransaction" /> <ServiceEvents Selecting="Selecting_MembershipTransaction" Updating="Updating_MembershipTransaction" /> </ClientBindingSettings> </ISWebGrid:WebGrid>
This is really urgent, and I need your help ASAP.
Thanks,
Maged
Also, I tried to change the col type to be text instead of checkbox, and it was displaying the true/false value correctly while the checkbox is always unchecked!!
Hello,
I attached my sample. It works fine. Please paste into our WebGrid sample. I added my update,insert and delete WebMethod in webservice.cs. Also, please ensure that you did not forget to define the boolean value type in your javascript.
e.g
I use table product in Northwind database. When specify ItemTypeName, we also need to define the value.
function Product() { this.ProductID = 0; this.ProductName = ""; this.SupplierID = 0; this.CategoryID = 0; this.QuantityPerUnit = ""; this.UnitPrice = 0; this.UnitsInStock = 0; this.UnitsOnOrder = 0; this.ReorderLevel = 0; this.Discontinued = false; }
Regards,Handy
I've done lots of investigation on this, and really can't figure out what is wrong.
So I'll share some of my ideas and you may share it with your dev team, so they could help.
- The boolean data is stransfering correctly to WebGrid, I confirmed that by changing the cell type from checkbox to text.
- It only happening with clientside binding.
- It only happen on my project not on your sample at all.
- Seems to me like it fail to draw the checkbox on the virtual UI, and that is why it doesn't happen if we make the binding to happen on the server side, seems like its rendering issue!
- What possible can happen on my project that effect the checkbox drawing if I've the data binding on client side?
If some one from the dev team at Intersoft can answer these, that could help me to resolve this!
Hello Maged,
Thank you for your response.To investigate your issue, we need able to replicate your issue first.In my sample, it also used checkbox boolean type (database) with using client binding WebService.However, it works fine. Is it possible for you to create a simple runable project or modify my sample so we can replicaet your issue in here? We need this to investigate your issue.
I agree with you, and its really hard for me to send mini project like that, my project is quite big project.
I found one thing that if I remove the footer from the web-page, the checkbox got fixed, I have no explanation for that to tell the truth and I tried every possible thing to find why but I can't, if you have any idea please let me know.
Thanks for your help.
Maged Mikaeel
Technical Architect/Development Manager
CompuArt Technology
I still could not replicate the issue in our sample. Using footer should not cause that issue. It would very helpful if we have a simple sample that can replicate the issue. Can you help us?
I'm currently getting exactly the same issue as above.
These client binding settings
<ClientBindingSettings DataSourceType="WebService" ServiceUrl="~/Webservices/settings.asmx" DataLoadMode="PagedData" EnableGroupRowPaging="true" GroupRowPageSize="20" PreloadGroupTotals="true" ItemTypeName="fn_tblProject_GetAllResult"> <ServiceMethods SelectMethod="GetPagedProjects" BatchUpdateMethod="UpdateProject" /> </ClientBindingSettings>
plus
<ISWebGrid:WebGridColumn Caption="Enabled" DataMember="IsEnabled" DataType="System.Boolean" Name="IsEnabled" HeaderTooltip="Enabled" ColumnType="CheckBox" EditType="Checkbox"> </ISWebGrid:WebGridColumn>
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_IsEnabled", DbType="Bit NOT NULL")] [global::System.Runtime.Serialization.DataMemberAttribute(Order=6)] public bool IsEnabled { get { return this._IsEnabled; } set { if ((this._IsEnabled != value)) { this._IsEnabled = value; } } }
Update: 2012-02-17 16:57
Looking at the HTML output the value of the checkbox is set to "on". Hope this might help.
Hello Paul,
Can you provide me a simple working sample that replicates the issue? Also, with my previous sample, do you find any differences? FYI, you would need also to set the initial value of field. For more information, please refer into my sample at previous posted.
Regards.Handy
or
Choose this if you're already a member of Intersoft Community Forum. You can link your OpenID account to your existing Intersoft Social ID.
Choose this if you don't have an Intersoft account yet. Your authenticated OpenID will be automatically linked to your new Intersoft account.
Enter your Wordpress Blogname