Visual Studio to run when evaluating variable

Asked

Viewed 30 times

1

Doing some tests on an old system, I arrived at a strange behavior for the Visual Studio part. When I hover over a variable of a specific type, Visual Studio closes, as you can see in the GIF below:

inserir a descrição da imagem aqui

(Note that queries appear in the name of properties for a few moments.

At first, I thought he went into some kind of loop in the get of some property, but I put breakpoints in all class properties and that didn’t happen.

The object I assess at first is of the type:

List<EntrevDeslig.Planilha> listaDados = new List<EntrevDeslig.Planilha>();

And the attributes of the object Planilha are the following:

    private string _nomeplan;
    public string sNomePlan { get { return _nomeplan; } set { _nomeplan = value.Replace("'", "''"); } }

    private string _tituloplan {  get { return _tituloplan; } set { _tituloplan = value.Replace("'", "''"); } }
    public string sTituloPlan;

    private string _grade;
    public string sGrade { get { return _grade; } set { _grade = value.Replace("'", "''"); } }

    private string _quesito;
    public string sQuesito { get { return _quesito; } set { _quesito = value.Replace("'", "''"); } }

    private string _dataini;
    public string sSdataIni { get { return _dataini; } set { _dataini = value.Replace("'", "''"); } }

    private string _datafim;
    public string sSdataFim { get { return _datafim; } set { _datafim = value.Replace("'", "''"); } }

    private string _grupocar;
    public string sGrupoCar { get { return _grupocar; } set { _grupocar = value.Replace("'", "''"); } }

    private string _cargo;
    public string sCargo { get { return _cargo; } set { _cargo = value.Replace("'", "''"); } }

    private string _datareg;
    public string sSdataReg { get { return _datareg; } set { _datareg = value.Replace("'", "''"); } }

    private string _chave;
    public string sChave { get { return _chave; } set { _chave = value.Replace("'", "''"); } }
    public int iOrdem;

    private string _titulo;
    public string sTitulo { get { return _titulo; } set { _titulo = value.Replace("'", "''"); } }

    private string _titulopai;
    public string sTituloPai { get { return _titulopai; } set { _titulopai = value.Replace("'", "''"); } }

    private string _processo;
    public string sProcesso { get { return _processo; } set { _processo = value.Replace("'", "''"); } }

    private string _nivel;
    public string sNivel { get { return _nivel; } set { _nivel = value.Replace("'", "''"); } }

    public string BCOID;
    public string sOPC;

The problem only happens when I evaluate the Worksheet class, not the list.

Did anyone have a similar problem? Or at least know some way to identify the cause of the problem (VS logs, something like that.)? The system works perfectly in production environment, but I would like to correct this, or at least understand

  • Have you checked if it’s an extension? I’ve had a similar problem, and when I deactivated the extensions, I identified one that when activated, I didn’t let it debug normally. I can’t remember the name of the extension.

  • @But I don’t use any extension, and it’s just in that object Planilha that this happens

  • The only thing abnormal I’ve seen in the attributes is the get and set in the private variable. private string _tituloplan { get { return _tituloplan; } set { _tituloplan = value.Replace("'", "''"); } }&#xA;public string sTituloPlan; instead of being in the public variable.

  • @How can this be the cause of the problem? The funny thing is that the system works perfectly in production...

  • That’s why I put as "abnormal", I could not perform a practical test. Didactically I do not know how to report this scenario.

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.