Solved

Screen Editor: Cannot create an object of type 'System.Int32' from its string representation '' for the 'ColumnSpan' property.

  • 27 May 2021
  • 5 replies
  • 192 views

Userlevel 3
Badge +1

Only happens when I try to preview.  I can publish and run the screen fine.

ASPx looks OK and there is no ColumnSpan property being set anywhere that I can see.

 

<%@ Page Language="C#" MasterPageFile="~/MasterPages/FormDetail.master" AutoEventWireup="true" ValidateRequest="false" CodeFile="AP504520.aspx.cs" Inherits="Page_AP504520" Title="Untitled Page" %>
<%@ MasterType VirtualPath="~/MasterPages/FormDetail.master" %>

<asp:Content ID="cont1" ContentPlaceHolderID="phDS" Runat="Server">
<px:PXDataSource ID="ds" runat="server" Visible="True" Width="100%"
TypeName="APCustomizations.APStaleDateLettersProcess"
PrimaryView="Filter"
>
<CallbackCommands>

</CallbackCommands>
</px:PXDataSource>
</asp:Content>
<asp:Content ID="cont2" ContentPlaceHolderID="phF" Runat="Server">
<px:PXFormView ID="form" runat="server" DataSourceID="ds" DataMember="Filter" Width="100%" Height="100px" AllowAutoHide="false">
<Template>
<px:PXLayoutRule ID="PXLayoutRule1" runat="server" StartRow="True"></px:PXLayoutRule>
<px:PXLayoutRule runat="server" ID="CstPXLayoutRule8" StartColumn="True" ></px:PXLayoutRule>
<px:PXDateTimeEdit CommitChanges="True" runat="server" ID="CstPXDateTimeEdit2" DataField="StartDate" ></px:PXDateTimeEdit>
<px:PXLayoutRule runat="server" ID="CstPXLayoutRule9" StartColumn="True" ></px:PXLayoutRule>
<px:PXDateTimeEdit CommitChanges="True" runat="server" ID="CstPXDateTimeEdit1" DataField="EndDate" ></px:PXDateTimeEdit></Template>
</px:PXFormView>
</asp:Content>
<asp:Content ID="cont3" ContentPlaceHolderID="phG" Runat="Server">
<px:PXGrid ID="grid" runat="server" DataSourceID="ds" Width="100%" Height="150px" SkinID="Inquire" AllowAutoHide="false">
<Levels>
<px:PXGridLevel DataMember="DetailsView">
<Columns>
<px:PXGridColumn DataField="Selected" Width="60" AllowCheckAll="True" Type="CheckBox" ></px:PXGridColumn>
<px:PXGridColumn LinkCommand="viewDocument" DataField="RefNbr" Width="140" ></px:PXGridColumn>
<px:PXGridColumn DataField="DocType" Width="70" ></px:PXGridColumn>
<px:PXGridColumn DataField="Status" Width="70" ></px:PXGridColumn>
<px:PXGridColumn DataField="ExtRefNbr" Width="180" ></px:PXGridColumn>
<px:PXGridColumn DataField="AdjDate" Width="90" ></px:PXGridColumn>
<px:PXGridColumn DataField="UsrOrigCheckNo" Width="180" ></px:PXGridColumn>
<px:PXGridColumn DataField="UsrStaleDatedOn" Width="90" ></px:PXGridColumn>
<px:PXGridColumn DataField="UsrStaleDatedByDisplay" Width="280" ></px:PXGridColumn>
<px:PXGridColumn DataField="VendorID" Width="140" ></px:PXGridColumn>
<px:PXGridColumn DataField="APContact__FullName" Width="280" ></px:PXGridColumn>
<px:PXGridColumn DataField="CuryOrigDocAmt" Width="100" ></px:PXGridColumn></Columns>
</px:PXGridLevel>
</Levels>
<AutoSize Container="Window" Enabled="True" MinHeight="150" ></AutoSize>
<ActionBar >
</ActionBar>
</px:PXGrid>
</asp:Content>

 

icon

Best answer by rjean09 1 June 2021, 15:30

View original

5 replies

Userlevel 6
Badge +5

I just posted on an older thread but if you are still having this issue the page is in a folder in the CstDesigner folder and mine is prefixed with [Username]_[ProjectName] and there is a [ScreenID].aspx file inside that you can open and change to fix the issue. 

 

Nothing I was able to do from the editor seemed to fix the issue except deleting the project and reimporting it under a different name.

Userlevel 3
Badge +1

I’ll give this a try.  For some reason I thought they had to exist in both places forever.

Userlevel 5
Badge +2

If its a new page, when you are done with changes in Screen section use the Edit ASPX button to get the page source code. Then you can copy/paste it in the Files section (with Edit function) and remove the Screen item. For new screens there is no need to use screen customization.

Userlevel 3
Badge +1

It’s in files and screens.  Can’t find any ColumnSpan property set anywhere in either ASPX on disk or in the Screen Editor.  I had put in a ColumnSpan of 2 on a group control.  Got the error.  Removed the entire group node but still happening.  I guess I can live with it knowing it’s just the preview.  I tend to use that feature just because I’m still using my training wheels :)

 

Update: I just tried exporting and importing my customization package to our staging server and when I bring up the screen editor there no error when previewed!  Weird.

Userlevel 5
Badge +2

This looks like a new page. If that’s the case make sure it is only in the Files section of the customization:

 

Maybe the page is in Files but there are also some customizations applied on top of it. In that case you would have an entry for the page in Files and in Screens section:

It is possible that there’s no ColumnSpan property in Files section but that it was added by customizing the screen in Screens section.

 

Also note that the Preview functionality is not perfect. It is not used very often and therefore some bugs related to Preview features aren’t reported and fixed. This doesn’t affect anything outside of Preview feature.

Reply


About Acumatica ERP system
Acumatica Cloud ERP provides the best business management solution for transforming your company to thrive in the new digital economy. Built on a future-proof platform with open architecture for rapid integrations, scalability, and ease of use, Acumatica delivers unparalleled value to small and midmarket organizations. Connected Business. Delivered.
© 2008 — 2024  Acumatica, Inc. All rights reserved