0

I have a website where I am attempting to be able to edit the code from my laptop without having to remote connect to the server. The ascx control works perfectly fine but no matter what I try I end up with error code CS0103 whenever I refer from the ascx.cs file to the control found on ascx. The codefile is connected as shown below.

<%@ Control Language="C#" AutoEventWireup="true" CodeFile="Control.ascx.cs" Inherits="AANEM_Accreditation_Step4" %>

Sample of something I might do .NET:

<asp:Label runat="server" ID="lblBanana" />

C#:

lblBanana.Text = "Banana";

This would result with Visual Studio on my local machine giving me error code CS0103. It would display and function properly. I do not get the error when I use Remote Desktop Connection and open it there. This happens with all code files in this solution. I use Visual Studio 2017 on both machines. Some attempts I have tried:

  • Uninstalling and reinstalling
  • Opening with designer and selecting refresh
  • Rebuild solution
Brandon
  • 51
  • 4
  • 1
    `I have a website where I am attempting to be able to edit the code from my laptop without having to remote connect to the server.` Does this mean that you want to recompile this project code locally? Have you tried to package the project and then open and compile it locally? – Jiale Xue - MSFT Jun 14 '22 at 09:29
  • `Does this mean that you want to recompile this project code locally?` No I'm more just looking to be able to edit it locally and be able to get the text autofill for buttons, labels, etc. Everything will be staying on the server but I want to be able to edit from my workstation and have the same autocomplete suggestions or at least not have errors show up when they should not. – Brandon Jun 14 '22 at 13:41

0 Answers0