Page 1 of 1

Errors on all child pages when accessed from Master (v2023)

Posted: Sat Feb 11, 2023 4:19 am
by darkdragon

Hi,

This error appears on all child pages. Project converted from v2021.

An error occurred during the compilation of a resource required to process this request. Please review the following specific error details and modify your source code appropriately.
d:\APPS\EvOLT-2023\bin\Debug\net6.0\publish\Views\Home\EventsApprovalsMaster.cshtml

'EvOLT_2023.EventsApprovals' does not contain a definition for 'IsModal' and no accessible extension method 'IsModal' accepting a first argument of type 'EvOLT_2023.EventsApprovals' could be found (are you missing a using directive or an assembly reference?)

...

#line default
#line hidden
#nullable disable
            WriteLiteral("\", \"EventsApprovals\", ew.templateData.rows[0], ");
#nullable restore
#line (233,180)-(233,222) 6 "d:\APPS\EvOLT-2023\bin\Debug\net6.0\publish\Views\Home\EventsApprovalsMaster.cshtml"
Write(eventsApprovals.IsModal ? "true" : "false");

Re: Errors on all child pages when accessed from Master (v2023)

Posted: Sat Feb 11, 2023 4:42 am
by darkdragon

On the other hand, the Preview extension works well, as row, offcanvas, modal.


Re: Errors on all child pages when accessed from Master (v2023)

Posted: Sat Feb 11, 2023 5:29 am
by darkdragon

Accesing the View page of the Master with detail view of the child table gives this error:

An error occurred during the compilation of a resource required to process this request. Please review the following specific error details and modify your source code appropriately.
d:\APPS\EvOLT-2023\bin\Debug\net6.0\publish\Views\Home\EventAttachmentsGrid.cshtml

Use of unassigned local variable 'rowIndex'

Unfortunately I have no idea what to paste here, as there are countless rowIndex in the code


Re: Errors on all child pages when accessed from Master (v2023)

Posted: Sat Feb 11, 2023 7:54 am
by Webmaster

Please send your project file/database to the support email for a quick resolution if you are a registered user.


Re: Errors on all child pages when accessed from Master (v2023)

Posted: Sat Feb 11, 2023 7:36 pm
by darkdragon

This is a quite large project. I will try to reproduce it on a smaller one.
Anyway, it seems the issue appears only on pages with CustomTemplate.


Re: Errors on all child pages when accessed from Master (v2023)

Posted: Mon Feb 13, 2023 7:41 am
by darkdragon

OK, so for the first issue, error with isModal appears when Master Record Page has a CustomTemplate, in which case a *Master.cshtml page is being generated.

<script class="ew-apply-template">
loadjs.ready(ew.applyTemplateId, function() {
    var $ = jQuery;
    ew.templateData = { rows: @Html.Raw(ConvertToJson(applicationWorkflowTeams.Rows)) };
    ew.applyTemplate("tpd_ApplicationWorkflowTeamsmaster", "tpm_ApplicationWorkflowTeamsmaster", "ApplicationWorkflowTeamsmaster", "@(applicationWorkflowTeams.Export)", "ApplicationWorkflowTeams", ew.templateData.rows[0], @(applicationWorkflowTeams.IsModal ? "true" : "false"));
    loadjs.done("customtemplate");
});
</script>

I will send a small project to support.


Re: Errors on all child pages when accessed from Master (v2023)

Posted: Tue Feb 14, 2023 6:46 pm
by darkdragon

The error with rowIndex is when I want to acces the View page of a Master Page together with a Detail table that contains a FileUpload control

<span id="el@(rowIndex)_ContractAttachments_filename" class="el_ContractAttachments__filename">

I will get back to support.


Re: Errors on all child pages when accessed from Master (v2023)

Posted: Tue Feb 14, 2023 9:34 pm
by psjohnso

I had the same issue. I updated the template this morning which solved the problem.