I have been through the code formatting options in MonoDevelop and I am trying to get my code to vertically align.
I have been able to get the Access Modifiers, etc to line up, but I would like to get the variable names and their values, equal signs and values to align.
This is what I have:
And this is what I am going for:
It seems trivial but helps me keep my code clean.
Is there a setting I have missed?
I don't think there's an option for this in monodevelop. Honestly, I used monodevelop for about a year, and there were just too many things it didn't do. I switched to VS Code and then Visual Studio for Mac for all my development, and it's... it's just so much better. VS Code and VS Mac both can use the CodeAlignment plugin for this task.
Related
I want to use Visual Studio Code as my editor for c # code in Unity and I want to hover over the code to display a short description of what, for example, the method does.
I found this thread but I don't know what to do exactly.
Does anyone know how to do it and is it such an option?
P.S.:
And by the way, does anyone know a good extension with syntax highlighting?
OK, I found something like an answer. I didn't think this would change anything, but I downloaded the Windows: .NET Framework 4.7.1 Developer Pack as this tutorial says and the syntax started to stand out and I get a little hint as I hover over the methods.
Okay so I wanted to get into mobile development and decided to start with Android Studio, but I wanted to more easily reach both Android and IOS so switched over to Xamarin.
Honestly, Xamarin looks really cool and I have been trying so hard to get into it, but every time I open a new Xamarin project it seems to break right away before I really get to do anything.
Sometimes it asks me to update something so I do so before I begin development and it breaks, sometimes I run an initial build right when I make the project with no changes made and it breaks. Sometimes I do something as simple as adding a button or entry in the XAML code and it just breaks, and when I erase all my changes it is still broken.
I just want to know, is this just me or is this just how Xamarin is? I know there is a huge chance it is just me having no idea what I'm doing, but the project seems to break even when I follow updated tutorials and documentation. I have gotten errors even involving the file path it made.
Summary
The short time I used Android Studio I was able to get decently far into development and it still didn't break, but with Xamarin I am having a hard time just getting past the creation of the project without some error. Why is this? Does this happen to experienced Xamarin Developers or just for beginners?
There are certainly issues in Xamarin Mobile Development. Those issues you are referering, happen to everyone from time to time (not that common these days though).
Ignore compiling errors (assuming its the programmer's fault), those issues are usually related with Visual Studio. So, the process is always the same:
Clean Solution
Delete bin/objs folders (if the clean has errors)
Restart Visual Studio
Rebuild
I started C# a while ago and really like it.
I work with VS 2008 and really like it.
I tried Resharper and loved it.
Now I am starting with Macros in VS2008 to increase my coding speed a little more. And stumble upon visual basic. And I do not like that.
Is there any way to write macros in C#. Or a workaround, in writing a plugin for VS to reach the same goal. Just let me stress out, its a productivity issue. I just want to automate some features I use often (create macro, assign shortcut, tell my touchscreen-app to send this shortcut)...
So from an experts point of view, is there an easy way to e.g. "collapse all items in the solution explorer, but expand all starting with the letter A" (just a silly example) without using visual basic?
Thanks for any tips,
Chris
PS: I was nearly happy with recording and playback. But, as it turns out, some "external" resharper command (like collapse all) do not play well with macros (getting strange com errors). So I thought, hey, a loop to collapse all items, I can do that. But unfortunately not really quick in VB :-)
Try writing a DLL in C# and referencing it in a VB macro.
This way, the only VB you'll need to write is the code to connect the DLL to the IDE.
Unfortunately no, Visual Studio only supports VB.NET for macros.
I wouldn't stress too much about not having C# for macros (many C# developers seem mortified that VB.NET code will stick to their shoe like toilet paper). Rather take pride in your ability to be productive in multiple languages!
Visual Commander (developed by me) lets you write Visual Studio 2010+ (macro) commands in C#.
Snippets are the closest which I've come across. Snippet Editor 2.1 does a pretty good job setting them up without to much hassle.
I read a post by Joshua Kerievsky about 'Limited Red Time' Link
His org. Industrial Logic as part of a training module, has a screen where you upload an archive. In return, the screen shows you a graph of how much time were you in the red state vs the green state. It also hooks up with Resharper and annotates points at which the specific refactorings were performed.
The resulting graph gives some vital insights to self-assess your skills/behavior. e.g. I am myself guilty of getting into a red state and not giving in to a revert+retry, instead hacking away at it for a few hours before I get it to green (if I am lucky).
From my limited exposure, it looks to be proprietary. Is there such a visualization plugin for Visual Studio that is available ?
You could try looking at Beacons, a VS 2010 extension which shows you detailed information about your testing session. A demo of it can be found here.
Must admit that I´ve not used this myself, as I only found out about it the other day whilst on holiday. But it looks promising enough, and it's free.
http://visualstudiogallery.msdn.microsoft.com/en-us/B5EC8514-E251-41D2-8728-C1D0F5FD067D is an extension that builds timesheets based on your TFS activities... possibly you could set it up to support this? Of course if you're not using TFS then I doubt it would work.
This question already has answers here:
C# Console/CLI Interpreter?
(17 answers)
Closed 7 years ago.
Some programming language implementations provide a Read, Evaluate, Print Loop interactive shell to allow the programmer to evaluate expressions and program fragments, and to program in an incremental, interactive manner.
What implementations of a C# REPL have you used, and liked? It would be nice to have one that could integrate with Visual Studio as well.
I have found, but not tried, the Mono C# REPL and Don Box's C# REPL
Mono comes with a REPL tool called "csharp". I just tried it on Mac OS X and it works like magic. The only feature it currently lacks is Intellisense, promised to appear in Mono 2.6
Visual Studio 2008 includes REPL-like capabilities, though I wouldn't necessarily call them "good". I think they have the advantage of being included and always available--which can be handy when trying to do work at a workstation other than your own.
In Visual Studio, you can instantiate and invoke methods of objects using the Object Test Bench. You can also write interactive C# code (with many limits) using the Immediate Window (Debug->View->Immediate Window). Immediate Window can be used outside of a debugging session.
The best tool I've found for writing interactive c# code is the C# Snippet Compiler.
Not sure if it's exactly REPL but it is a great way to test out almost anything using C#/.NET.
It supports framework versions up to 3.5. It is not designed to integrate directly with Visual Studio, however it even provides its own intellisense.
Of course it's very easy to copy/export the code from this into your Visual Studio projects.
One that I've only seen is at the end of this video from PDC where Hejlsberg is going beyond C#4.
I do not know of an interactive shell for running c# code snippets. There is one for the mono project, but I have not tried it: http://www.mono-project.com/CsharpRepl
I tried the C# snippet compiler, and it seems to be pretty much the same as creating a new console application in Visual Studio, but with limited intellisense, and none of the debugging features.
Right now I use the built in console application template anytime I want to try out simple input-output type experimental code. I use console Console.ReadLine() and Console.WriteLine() for input and output.
It actually works pretty well for me. I typically save all my little test programs so I can go back and find something I worked with a few months ago, and you get the full debugging features of Visual Studio.
Have you tried the VisualStudio C# REPL - O2 Platform (v5.1) plugin (more info at O2Platform question on 'Interactive development with Visual Studio' )
There is also the stand alone version C# REPL Script (see this readme for more details on the APIs https://github.com/o2platform/FluentSharp/blob/master/README.md )