0

I'm using Visual Studio 2019 community

private void CreateDownloadFolders()
{
    string locationToCreateFolderRadar = textBoxRadarPath.Text;
    string locationToCreateFolderSatellite = textBoxSatellitePath.Text;
    string folderName = "";
    string date = DateTime.Now.ToString("ddd MM.dd.yyyy");
    string time = DateTime.Now.ToString("HH.mm tt");
    string format = "{0} On {1} {2}";

    folderName = string.Format(format, date, time, "");

    var p = Path.Combine(locationToCreateFolderRadar + folderName);

    Directory.CreateDirectory(locationToCreateFolderRadar + folderName);
    Directory.CreateDirectory(locationToCreateFolderSatellite + folderName);
}

I put a breakpoint on the line :

 Directory.CreateDirectory(locationToCreateFolderRadar + folderName);

Code execution stops here and then I hover the mouse over the string locationToCreateFolderRadar, but it's not showing its content not also the other variables in this method.

I'm calling this method from this button click event :

private async void btnStart_Click(object sender, EventArgs e)
{
    CreateDownloadFolders();
    
    urls = new List<string>();
    
    lblStatus.Text = "Downloading...";
    
    rad.GetRadarImages();
    await Task.Delay(5000);

    foreach (string link in rad.links)
    {
        urls.Add(link);
    }
    
    await sat.DownloadSatelliteAsync();

    foreach (string link in sat.SatelliteUrls())
    {
        urls.Add(link);
    }
    
    urlsCounter = urls.Count;
    
    await DownloadAsync();
}

Screenshot showing the breakpoint and that it's not showing the content when the mouse cursor is over it.

Stopped on the breakpoint but when I put the mouse over the variable/s it's not showing the content for example when you put a breakpoint on a List and see the List properties items stuff.

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
  • 2
    Have you tried to right-click=>Add Watch. This should open the Watch window with the variable and its value in it. This way you can watch several variables... – Roland Deschain Oct 26 '21 at 08:19
  • 2
    An old thread, but a lot of the solutions suggested have personally worked for me: https://stackoverflow.com/questions/19108801/datatips-mouse-hover-over-variables-in-debug-mode-not-working-in-visual-studio, e.g I had this suggestion help me in the past: https://stackoverflow.com/a/19113074/13108684 – ConnorTJ Oct 26 '21 at 08:21
  • 3
    It also might be that you are executing a release build with optimizations. In such builds the debugger may be inaccuarate – derpirscher Oct 26 '21 at 08:22
  • 1
    Also, another weird issue is that some people are experiencing a similar issue when they are using multiple screens (e.g a Laptop and another monitor) and the scaling being different between the two) – ConnorTJ Oct 26 '21 at 08:22

0 Answers0