VS2022 Intellisense does not work with TinyCLR extension

Hi,

I have installed the latest VS2022 and the latest TinyCLR extension. If I create a TinyCLR application, instellisense will not work. It does not show any information for neither .NET nor TinyCLR types. If I create a Windows Forms Application intellisense works as expected.

I have tried to repair and update VS2022 and the extension, but the result is the same.

Have you seen this before?

/Geir

Did you enable the .NET extension when installing VS?

Skip TinyCLR for a second and try to build a standard .NET windows app to make sure VS/.NET are installed properly.

Yes, I can create a normal .NET application. This is what it looks like when I hover the mouse over “Sleep” in the .NET application:

image

This is what it looks like if I do the same in the TinyCLR application:

image

There is no information about the method. It is like if there was no xml documentation file with the dll.

Exit VS and try deleting your bin, obj, and (most importantly) .vs/ directory. The reason is that VS caches a copy of mscorlib in .vs/ and if the signature doesn’t match the TinyCLR one that you are building against (and it won’t) then you won’t get Intellisense. Not a sure fix, but one thing to double check.

Thanks for your suggestion, but the behaviour is still the same.

I can see the documentation from my own classes, but not from the GHI classes.

I have checked the NuGet “packages” folder in my solution, and there are no xml files with the GHI dll’s. This explains why I get no documentation in Intellisense.

I tried to download another TinyClr NuGet package from Bytewizer. The xml files were included with that package, so Intellisense worked as expected.

Do you know why I don’t get the xml files when I install the NuGet packages? I guess you create xml documentation for your TinyClr dlls?

I also am sorely disappointed that there’s no XML documentation for the GHI classes. I have been looking around everywhere for any working sample code on the WiFi module to no avail, so started walking the classes in the namespaces - and of course! No XML!

This is just basic developer 101 - without class / method descriptions, a number of the classes are mysteryware.

I can’t agree more! The source code to the C# part of TinyCLR can be found on GitHub here. I have found that some of the code is actually documented, but they have not enabled the generation of XML documentation, so it does not show up in VS. A work-around is to download the repo, enable XML and recompile it. Then reference these dlls.

I have filed an Issue for this at their GitHub repo, I hope that they will include it in the next release.

If you are using a GHI board, you can find the wifi tutorial here.

1 Like