Not updating integer fields

Posts   
 
    
seyfullah
User
Posts: 18
Joined: 20-Jul-2010
# Posted on: 24-Aug-2010 09:51:55   

Hello,

I started to have problems because of not updating integer and bit values.

We are using devexpress grids and we are using LLBLGenProDataSource control, when we want to update an entity, it is updated but entity's integer and bit values are not being updated.

What was changed before yesterday is that I regenerated classes using llblgen class generator tool.

What could cause this problem?

Thanks.

Walaa avatar
Walaa
Support Team
Posts: 14995
Joined: 21-Aug-2005
# Posted on: 24-Aug-2010 10:00:45   

Are the fields marked as read-Only in the Designer?

seyfullah
User
Posts: 18
Joined: 20-Jul-2010
# Posted on: 24-Aug-2010 10:25:25   

No, they are not read only.

Walaa avatar
Walaa
Support Team
Posts: 14995
Joined: 21-Aug-2005
# Posted on: 24-Aug-2010 11:01:03   

Could you please post the aspx code of the Grid.

seyfullah
User
Posts: 18
Joined: 20-Jul-2010
# Posted on: 24-Aug-2010 11:38:49   

I am sending ascx file where the code resides, if needed I can send aspx file also.

<%@ Control Language="C#" AutoEventWireup="true" CodeFile="EditPictures.ascx.cs"
    Inherits="operation_product_UserControls_prdpictures" %>
<%@ Register Assembly="DevExpress.Web.v10.1, Version=10.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxCallbackPanel" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.ASPxGridView.v10.1, Version=10.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxGridView" TagPrefix="dx" %>
<%@ Register Assembly="SD.LLBLGen.Pro.ORMSupportClasses.NET20" Namespace="SD.LLBLGen.Pro.ORMSupportClasses"
    TagPrefix="llblgenpro" %>
<%@ Register Assembly="DevExpress.Web.v10.1, Version=10.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxCallback" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.v10.1, Version=10.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxPanel" TagPrefix="dx" %>
<script type="text/javascript">
    $("table[id$='dtlProductSpecialityHasNoImage']").css('visibility', 'hidden').css('display', 'none');
</script>
<div style="padding-bottom: 5px;">
    <span style="border-bottom: #DDD 1px solid; line-height: 30px; padding-bottom: 5px;">
        Bu ürün üzerinde genel resim oluşturmak için <a id="linkSpecialityItem" href='<%= "javascript:LinkSpecialityWithImage(" + Request.QueryString["id"] + ",0);" %>'>
            tıklayınız. </a></span>
    <dx:ASPxCallbackPanel ID="datalistRefresher" runat="server" ClientInstanceName="datalistRefresherClient"
        OnCallback="datalistRefresher_Callback" Width="500px">
        <PanelCollection>
            <dx:PanelContent runat="server" SupportsDisabledAttribute="True">
                <span runat="server" id="spnDatalistHasWarnings" style="visibility: hidden; display: none;
                    cursor: pointer; font-size: 14px;">Bu ürünün bazı renkleri fotoğraflar ile ilişkilendirilmemiş.
                    Detay için tıklayın. </span>
                <asp:DataList ID="dtlProductSpecialityHasNoImage" runat="server" CellPadding="0">
                    <ItemTemplate>
                        <div>
                            <span style="font-family: Lucida Sans Unicode; font-size: 11px;">
                                <%# Eval("Name","Bu ürünün {0} rengi ile herhangi bir fotoğraf ilişkilendirilmemiş. ") %>
                                <a id="linkSpecialityItem" href='<%# "javascript:LinkSpecialityWithImage(" + Request.QueryString["id"] + "," + Eval("Id") + ");" %>'>
                                    Yeni Ekle</a> </span>
                        </div>
                    </ItemTemplate>
                </asp:DataList>
            </dx:PanelContent>
        </PanelCollection>
    </dx:ASPxCallbackPanel>
</div>
<dx:ASPxGridView ID="grdImagesMain" runat="server" AutoGenerateColumns="False" ClientIDMode="AutoID"
    DataSourceID="dtsImagesMainSource" KeyFieldName="Id" OnCustomCallback="grdImagesMain_CustomCallback"
    ClientInstanceName="grdImagesMainClient" OnRowDeleting="grdImagesMain_RowDeleting"
    OnRowUpdated="grdImagesMain_RowUpdated" 
    onrowupdating="grdImagesMain_RowUpdating">
    <ClientSideEvents EndCallback="function(s, e) {
    datalistRefresherClient.PerformCallback();
}" />
    <GroupSummary>
        <dx:ASPxSummaryItem FieldName="SpecialityItemId" ShowInColumn="True" />
    </GroupSummary>
    <Columns>
        <dx:GridViewDataImageColumn Caption="Görsel" FieldName="Url" ShowInCustomizationForm="True"
            VisibleIndex="0">
            <EditFormSettings Visible="False" />
            <DataItemTemplate>
                <asp:Image ImageUrl='<%# Eval("FImgPath","{0}") %>' ID="productSpecialityImage" runat="server"
                    alt="resim" Style="max-height: 100px; max-width: 100px;" />
            </DataItemTemplate>
        </dx:GridViewDataImageColumn>
        <dx:GridViewDataComboBoxColumn Caption="Ürün Özelliği" FieldName="SpecialityItemId"
            GroupIndex="0" ShowInCustomizationForm="True" SortIndex="0" SortOrder="Ascending"
            VisibleIndex="1">
            <PropertiesComboBox DataSourceID="dtsProductSpecialtyComboSource" NullDisplayText="Genel"
                TextField="Name" ValueField="Id" ValueType="System.Int32">
            </PropertiesComboBox>
            <EditFormSettings Visible="False" />
        </dx:GridViewDataComboBoxColumn>
        <dx:GridViewDataTextColumn Caption="Açıklama" FieldName="Description" ShowInCustomizationForm="True"
            VisibleIndex="2" Width="200px">
        </dx:GridViewDataTextColumn>
        <dx:GridViewDataComboBoxColumn FieldName="SpecialityItemId" VisibleIndex="3" Caption="Özellik">
            <PropertiesComboBox DataSourceID="dtsProductSpecialtyComboSource" TextField="Name"
                ValueField="Id" ValueType="System.Int32">
            </PropertiesComboBox>
        </dx:GridViewDataComboBoxColumn>
        <dx:GridViewDataTextColumn Caption="Sıra" FieldName="Order" ShowInCustomizationForm="True"
            VisibleIndex="4" Width="30px">
        </dx:GridViewDataTextColumn>
        <dx:GridViewDataCheckColumn Caption="Varsayılan" FieldName="IsMainImage" ShowInCustomizationForm="True"
            VisibleIndex="5">
        </dx:GridViewDataCheckColumn>
        <dx:GridViewDataCheckColumn Caption="Geçerli" FieldName="IsValid" ShowInCustomizationForm="True"
            VisibleIndex="6">
        </dx:GridViewDataCheckColumn>
        <dx:GridViewCommandColumn Caption="Düzenle / Sil" ShowInCustomizationForm="True"
            VisibleIndex="7">
            <EditButton Text="Düzenle" Visible="True">
            </EditButton>
            <DeleteButton Text="Sil" Visible="True">
            </DeleteButton>
        </dx:GridViewCommandColumn>
    </Columns>
    <SettingsBehavior AutoExpandAllGroups="True" />
    <SettingsPager PageSize="20">
    </SettingsPager>
    <SettingsEditing PopupEditFormHorizontalAlign="NotSet" />
</dx:ASPxGridView>
<llblgenpro:LLBLGenProDataSource runat="server" ID="dtsImagesMainSource" DataContainerType="EntityCollection"
    EntityCollectionTypeName="ETrade2010.Library.CollectionClasses.ProductDescriptionImageCollection, ETrade2010.Library"
    >
    <SelectParameters>
        <asp:QueryStringParameter DefaultValue="0" Name="ProductDesctiptionID" QueryStringField="id" />
    </SelectParameters>
</llblgenpro:LLBLGenProDataSource>
<llblgenpro:LLBLGenProDataSource ID="dtsProductSpecialtyComboSource" runat="server"
    DataContainerType="EntityCollection" EntityCollectionTypeName="ETrade2010.Library.CollectionClasses.SpecialityItemCollection, ETrade2010.Library"
    >
    <SelectParameters>
        <asp:Parameter DefaultValue="2" Name="SpecialityTypeId" />
    </SelectParameters>
</llblgenpro:LLBLGenProDataSource>
Walaa avatar
Walaa
Support Team
Posts: 14995
Joined: 21-Aug-2005
# Posted on: 24-Aug-2010 12:03:04   

Which LLBLGen Pro runtime library version (build number) are you using?

seyfullah
User
Posts: 18
Joined: 20-Jul-2010
# Posted on: 24-Aug-2010 12:47:37   

Version : 3.0.10.526

template group + .NET version LLBLGen Pro Runtime Framework .NET 4.0.

Database server : Sql Server 2008 Enterprise

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39888
Joined: 17-Aug-2003
# Posted on: 24-Aug-2010 19:15:41   

Please update to the latest llblgen pro build (re-install the full installer from the customer area), this was fixed some weeks ago: Fix Runtime Libraries 3.0 07162010 16-Jul-2010 DataSource controls: In the scenario where the bound control passed the values in their real types, the datasource control couldn't set the properties as it assumed the values should be originally be passed in string format.

(changelog viewer in customer area )

Frans Bouma | Lead developer LLBLGen Pro
seyfullah
User
Posts: 18
Joined: 20-Jul-2010
# Posted on: 25-Aug-2010 09:07:03   

I downloaded LLBLGen Pro v3.0 18-Aug-2010 August 18th, 2010 but the problem still exists.

Walaa avatar
Walaa
Support Team
Posts: 14995
Joined: 21-Aug-2005
# Posted on: 25-Aug-2010 09:24:41   

Are you sure the application is using the new runtime library? It might be still using the old runtime.

seyfullah
User
Posts: 18
Joined: 20-Jul-2010
# Posted on: 25-Aug-2010 10:09:45   

Yes, I am sure the application is using the new library, I uninstalled and reinstalled it.

Walaa avatar
Walaa
Support Team
Posts: 14995
Joined: 21-Aug-2005
# Posted on: 25-Aug-2010 10:43:18   

It might not be related to installing and un-installing. Just check the file version of the runtime dll in the application's bin folder.

It might also be cached in the ASP.NET temp folders.

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39888
Joined: 17-Aug-2003
# Posted on: 25-Aug-2010 11:16:27   

Also, if you are sure you are using the latest runtime dll at runtime, please create a 1 page repro page on northwind or adventure works, so we can try to reproduce it with that.

Frans Bouma | Lead developer LLBLGen Pro
seyfullah
User
Posts: 18
Joined: 20-Jul-2010
# Posted on: 25-Aug-2010 11:22:45   

I updated the llblgen dlls in the bin folder, then the problem is solved.

Thanks.

Posts: 1
Joined: 14-Mar-2011
# Posted on: 14-Mar-2011 13:27:54   

Is this a problem with 2.6 Final as well? If so is there a solution for 2.6?

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39888
Joined: 17-Aug-2003
# Posted on: 14-Mar-2011 14:05:09   

You can get the v2.6 runtimes from the customer area.

Frans Bouma | Lead developer LLBLGen Pro