Welcome to NexusFi: the best trading community on the planet, with over 150,000 members Sign Up Now for Free
Genuine reviews from real traders, not fake reviews from stealth vendors
Quality education from leading professional traders
We are a friendly, helpful, and positive community
We do not tolerate rude behavior, trolling, or vendors advertising in posts
We are here to help, just let us know what you need
You'll need to register in order to view the content of the threads and start contributing to our community. It's free for basic access, or support us by becoming an Elite Member -- see if you qualify for a discount below.
-- Big Mike, Site Administrator
(If you already have an account, login at the top of the page)
I don't like it any better for an editor either, but I followed the instructions in this thread and got it working for editing just fine. My real goal was to use the debugger, and I still had no source-level debugging capability, I'd appreciate more information on how you pull that off!
Thank you.
Can you help answer these questions from other members on NexusFi?
Debugging in VS. Very easy and I don't see how it can be done without VS.
I write only strategies, so my explanation is for them. (Don't understand people who write indicators. Why?)
1. Open source code in NT.
2. Right click and check the box to allow debug mode. You need to do it only once and from now on you we be in debug mode.
3. Open VS and open the cs file in it too.
4. In NT compile the code. Very important!! Each time after you load VS and cs file go back to NT and compile it. This creates some kind of linkage.
5. In VS in debug menu choose "attach to..." and pick NT from the list of processes.
6. On left margin of code in VS click on the row you want to break on. It will add a dot and in runtime it will stop there. One click on the dot and it will remove the break.
7. Run back test in NT and you will be stooped at the break you put in VS. F5 - continue. F10 - step.
Now you can take any variable and move it to watch window and you will see its value on each interaction.
When you find a bug stop debugging in VS. Correct it in NT. Recompile and run again.
Baruch
p.s.
I write it from memory so I hope the explanation is complete.
Not a book on how to program, but instead a book on how to use the features included in Visual Studio 2010 Pro and an introduction to some of the tools found in the higher-end editions.
Task List: View > Task List. You can drop reminders in your code such as //TODO: Check for divide by zero, and when you view your task list you will see them there for all the code in your Project. You can add custom items on the task list (BUILD_VER is one I made, for example) using the Tool >Options > Environment > Task List dialog.
Toolbox: You can drag and drop code into the Toolbox panel. Personally I prefer Code Snippets but they do need to be created by the user. Drag and drop to/from the Toolbox panel is quick and easy.
I'm sure that is very basic stuff for some of the users here!
I've also had look at how much I don't know courtesy of the book mentioned above. My list of known unknowns just got a whole lot bigger...
Ran into my first hiccup today, but it was more of a Subversion problem than a VS/Ninja problem. Basically I was being a little bit too clever, and would love to hear of a better way to do this:
By following the steps in this thread one is building all ones VS work in the NT7>bin>Custom directory. I have an online SVN that some of my friends can access, and I share that whole project. All works, all is well.
Eight hours ago I decided I wanted a "private" folder in the SVN. Thats where it got messy. I ended up creating then deleting then creating again two seperate SVN repos. The project on my VS2010 was linked to a repos that no longer exists, and I could find no way to unbind it and kill any references to the original repos.
Deleted ankhsvn and installed a 30-day trial of VisualSVN but still no joy. The whole process was a PITA.
Luckily Beta 20 was released so I had an excuse for a clean install, which I have just done, and added that project as in my earlier posts. All is well again... BUT... I'm not putting it in the SVN until I know what I am doing .
What would be the best way to share different Ninja projects that compile in situ in VS using SVN. I recognise only one project can be open at a time in Visual Studio, but I'm sure I'm missing some basic work flow set up paradigm.
Basically I'd like to share ProjectX with Bill and Sue in one repos, and ProjectY with Tom and Lisa in another repos. I know how to set up the repos in SVN, its getting VS and Ninja to play nicely withthe SVN that is frustrating me.
Sorry, I don't have the answer, but my advice is KISS .
This is what I'm doing:
- I use my own repository, or the BMCodex one, and the files I'm working on are in specific directories, not the NT default directory for indicators/strategies/types/...
- for editing the code and writing the "skeleton" of the code, I use Notepad++, which is much better than the NT editor when you have more than 100 lines to play with
- when this code doesn't look too bad, I'm doing the initial commit to the repository
- then, I have to copy the code in the NT directory, edit it with NT, see if the compile is ok or not, do the modifications needed, and when it works like it should, I copy it back this file to my repository directory, and update it with SVN
I know this is a bit "heavy", but I didn't find a good solution for having my NT directories managed by two different repositories, and I don't think it's possible.
The more I learn the more I learn what I don't know. I decided to tackle a basic stand-alone WinForms app that uses NT7 as an API. This is probably where I want to be in the long run... I have a platform I can work with that works to a trading API. Keep my ideas portable.
Anyway. The SampleCSharp app that shipped with NT6.5 is broken in NT7, so I started from scratch and just added some of that apps GUI before I try to add its functionality.
If anyone is interested post back and post some code here.
Attached a screen grab of where I stand. All the middle bits work.
VS2010 is rocking my world. I have not touched WPF yet but it seems the next step...
We all know NT's C# abilities make it very open and powerful. But, can you tell me specifically how your trading is benefiting from all your work in Visual Studio? I believe its a fundamental type question, how you perceive the markets and your ability to make money in them.