• Dijkstra's Algorithm C#
    6 replies, posted
Was working on a team project in C#, I called it Dijkstra's Algorithm, and when I was done writing my code down I went to debug using Visual Studio 2010 and I would keep getting an error like this: [IMG]https://lh5.googleusercontent.com/-M8DCWHZMhig/UXYtd_9z3OI/AAAAAAAAAJQ/njtUVLTHxq4/w497-h373/Error.png[/IMG] This kept happening more and more when I re-did the project under a similar name. Only when I took out the name Dijkstra would it properly run and debug. Why is that?
i'm not entirely sure but i think it's caused by the " 's ". The ' might be an invalid character to use as a title. Best to only use numbers and letters.
[QUOTE=Sergesosio;40386718]i'm not entirely sure but i think it's caused by the " 's ". The ' might be an invalid character to use as a title.[/QUOTE] I'll test that out and let you know [editline]23rd April 2013[/editline] [QUOTE=omiver;40386732]I'll test that out and let you know[/QUOTE] After testing with 5 projects I can confirm that what you said is true. Seems you aren't allowed to use " ' " in a project name. Although I think they should throw an error at the user if they do attempt to do that. Made me waste a lot of time sifting through my code looking for errors.
Yeah, as a general rule, keep namespaces and assembly names alphanumeric - a-z, A-Z, 0-9, dashes and underscores should also be fine. [editline]22nd April 2013[/editline] Yep, this is your problem: [url]http://social.msdn.microsoft.com/Forums/en-US/Vsexpressvb/thread/02be3d7e-cff5-47a7-a00a-1c5ebfcb47a7/[/url]
[QUOTE=robmaister12;40386754]Yeah, as a general rule, keep namespaces and assembly names alphanumeric - a-z, A-Z, 0-9, dashes and underscores should also be fine. [editline]22nd April 2013[/editline] Yep, this is your problem: [url]http://social.msdn.microsoft.com/Forums/en-US/Vsexpressvb/thread/02be3d7e-cff5-47a7-a00a-1c5ebfcb47a7/[/url][/QUOTE] Thanks for the link!
[QUOTE=omiver;40386732]Although I think they should throw an error at the user if they do attempt to do that. Made me waste a lot of time sifting through my code looking for errors.[/QUOTE] While it may be a good idea, you should avoid naming anything with non-alphanumeric characters in code. You'll get weird bugs like this if you do.
[QUOTE=robmaister12;40386786]While it may be a good idea, you should avoid naming anything with non-alphanumeric characters in code. You'll get weird bugs like this if you do.[/QUOTE] Will Definitely keep that in mind from now on.
Sorry, you need to Log In to post a reply to this thread.