Immaginate un'applicazione web, realizzata con asp.net 1.1, composta da due cartelle che contengono files aspx identici (o quasi..) che sino ad oggi hanno funzionato perfettamente
Faccio una modifica in un file della prima cartella. una cosa molto semplice, aggiungo un link button ad un datagrid collegandolo ad una subroutine; il risultato della modifica è perfettamente funzionante
Riporto la medesima modifica nel file relativo della seconda cartella e non funziona segnalando come errore che non vede la subroutine che, naturalmente ho copiato precisamente:
Ho provato a rinominare la subroutine, il file , il code behind, a cancellare e ricreare tutto, ho cambiato il modificatore di accesso, la firma della subroutine ma non funziona, non lo vede proprio..
Ho cercato su Google ma non c'è niente di preciso e non mi aiuta
nel dettaglio l'errore è il seguente
Server Error in '/LuigiCorriasProject' Application.
--------------------------------------------------------------------------------
Compilation Error
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.
Compiler Error Message: BC30456: 'ShowHASHMD5' is not a member of 'ASP.DownloadDocument_aspx'.
Source Error:
Line 26: <asp:TemplateColumn HeaderText="Nome del File">
Line 27: <ItemTemplate>
Line 28: <asp:LinkButton Runat="server" ID="Linkbutton4" CommandName="ID_Documento" OnCommand="ShowHASHMD5" CommandArgument= <%# Container.DataItem("ID_Documento") %> CausesValidation="False">
Line 29: <asp:Label ID="Etichetta" title="Selezionando questo link è possibile conoscere l'HASH MD5 del File" Runat=server text=' <%# Container.DataItem("NomeDocumentoOriginale") %> ' />
Line 30: </asp:LinkButton>
Source File: c:\inetpub\wwwroot\LuigiCorriasProject\Administrat orRoom\DownloadDocument.aspx Line: 28
Show Detailed Compiler Output:
C:\WINDOWS\system32> "c:\windows\microsoft.net\framework\v1.1.4322\vbc. exe" /t:library /utf8output /R:"c:\windows\assembly\gac\system.xml\1.0.5000.0__ b77a5c561934e089\system.xml.dll" /R:"c:\windows\assembly\gac\system.drawing\1.0.5000 .0__b03f5f7f11d50a3a\system.drawing.dll" /R:"c:\windows\assembly\gac\system.web.mobile\1.0.5 000.0__b03f5f7f11d50a3a\system.web.mobile.dll" /R:"c:\windows\microsoft.net\framework\v1.1.4322\te mporary asp.net files\luigicorriasproject\ee457e74\e345da47\assemb ly\dl2\32efe143\005eeca6_a52dc601\magicajax.dll" /R:"c:\windows\assembly\gac\system.data\1.0.5000.0_ _b77a5c561934e089\system.data.dll" /R:"c:\windows\microsoft.net\framework\v1.1.4322\te mporary asp.net files\luigicorriasproject\ee457e74\e345da47\assemb ly\dl2\a2fd2e09\008e5ca4_d4bac601\autosuggestbox.d ll" /R:"c:\windows\microsoft.net\framework\v1.1.4322\te mporary asp.net files\luigicorriasproject\ee457e74\e345da47\assemb ly\dl2\710c31e8\76f5b701_8757c801\luigicorriasproj ect.dll" /R:"c:\windows\microsoft.net\framework\v1.1.4322\te mporary asp.net files\luigicorriasproject\ee457e74\e345da47\wddg3l dy.dll" /R:"c:\windows\microsoft.net\framework\v1.1.4322\te mporary asp.net files\luigicorriasproject\ee457e74\e345da47\assemb ly\dl2\6ec963e4\00a26211_9aaac601\freetextbox.dll" /R:"c:\windows\microsoft.net\framework\v1.1.4322\te mporary asp.net files\luigicorriasproject\ee457e74\e345da47\bcyjae zr.dll" /R:"c:\windows\microsoft.net\framework\v1.1.4322\te mporary asp.net files\luigicorriasproject\ee457e74\e345da47\npwjwc 4x.dll" /R:"c:\windows\assembly\gac\system.web\1.0.5000.0__ b03f5f7f11d50a3a\system.web.dll" /R:"c:\windows\assembly\gac\system\1.0.5000.0__b77a 5c561934e089\system.dll" /R:"c:\windows\microsoft.net\framework\v1.1.4322\te mporary asp.net files\luigicorriasproject\ee457e74\e345da47\assemb ly\dl2\939b57dd\d4720cf3_c5d9c701\webcontrolcaptch a.dll" /R:"c:\windows\assembly\gac\system.web.services\1.0 .5000.0__b03f5f7f11d50a3a\system.web.services.dll" /R:"c:\windows\assembly\gac\system.enterpriseservic es\1.0.5000.0__b03f5f7f11d50a3a\system.enterprises ervices.dll" /out:"C:\WINDOWS\MICROSOFT.NET\FRAMEWORK\V1.1.4322\ Temporary ASP.NET Files\luigicorriasproject\ee457e74\e345da47\dpm98n 5j.dll" /DEBUG=1 /debug+ /win32resource:"C:\WINDOWS\MICROSOFT.NET\FRAMEWORK\ V1.1.4322\Temporary ASP.NET Files\luigicorriasproject\ee457e74\e345da47\dpm98n 5j.res" "C:\WINDOWS\MICROSOFT.NET\FRAMEWORK\V1.1.4322\Temp orary ASP.NET Files\luigicorriasproject\ee457e74\e345da47\dpm98n 5j.0.vb"
Microsoft (R) Visual Basic .NET Compiler version 7.10.6001.4
for Microsoft (R) .NET Framework version 1.1.4322.2407
Copyright (C) Microsoft Corporation 1987-2002. All rights reserved.
c:\inetpub\wwwroot\LuigiCorriasProject\Administrat orRoom\DownloadDocument.aspx(28) : error BC30456: 'ShowHASHMD5' is not a member of 'ASP.DownloadDocument_aspx'.
AddHandler __ctrl.Command, AddressOf Me.ShowHASHMD5
~~~~~~~~~~~~~~
c:\inetpub\wwwroot\LuigiCorriasProject\Administrat orRoom\DownloadDocument.aspx(28) : error BC30456: 'ShowHASHMD5' is not a member of 'ASP.DownloadDocument_aspx'.
RemoveHandler __ctrl.Command, AddressOf Me.ShowHASHMD5
Questo è il datagrid
<asp:datagrid id="DataGridDocumentiAttivi01" style="Z-INDEX: 110; LEFT: 240px; POSITION: absolute; TOP: 250px"
runat="server" AllowPaging="True" PageSize="10" PagerStyle-Mode="NumericPages" PagerStyle-HorizontalAlign="Right"
PagerStyle-NextPageText="Next" PagerStyle-PrevPageText="Prev" OnPageIndexChanged="MyDataGrid_Page"
AutoGenerateColumns="False" HeaderStyle-BackColor="#aaaadd" Font-Size="8pt" Font-Name="Verdana"
HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center" ItemStyle-Wrap="False"
HeaderStyle-Wrap="False" CellPadding="3" BorderWidth="1" OnItemDataBound="ShowCross" BorderColor="black">
<Columns>
<asp:TemplateColumn HeaderText="Nome del File">
<ItemTemplate>
<asp:LinkButton Runat="server" ID="Linkbutton4" CommandName="ID_Documento" OnCommand="ShowHASHMD5" CommandArgument= <%# Container.DataItem("ID_Documento") %> CausesValidation="False">
<asp:Label ID="Etichetta" title="Selezionando questo link è possibile conoscere l'HASH MD5 del File" Runat=server text=' <%# Container.DataItem("NomeDocumentoOriginale") %> ' />
</asp:LinkButton>
<asp:LinkButton Runat="server" Visible=False ID="Linkbutton2" CommandName="ID_Documento" CommandArgument= <%# Container.DataItem("NomeDocumentoOriginale") %> OnCommand="VaiAdArchivio" CausesValidation="False">
[img]../APP_Skin/img/cross.gif[/img]</asp:LinkButton>
</ItemTemplate>
</asp:TemplateColumn>
Questo è il codice
Protected Sub ShowHASHMD5(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.CommandEventArgs)
.....
End Sub

EBUG=1 /debug+ /win32resource:"C:\WINDOWS\MICROSOFT.NET\FRAMEWORK\ V1.1.4322\Temporary ASP.NET Files\luigicorriasproject\ee457e74\e345da47\dpm98n 5j.res" "C:\WINDOWS\MICROSOFT.NET\FRAMEWORK\V1.1.4322\Temp orary ASP.NET Files\luigicorriasproject\ee457e74\e345da47\dpm98n 5j.0.vb"
Rispondi quotando
