ChrisCreateBoss asked
Something more, the class is finished, I want now to use it in my project, the class is in the same solution of Form1, but I can't use "using Hotkeys", it looks like if the class does not exists.
This is not how
using
directive (not to be mixed up with
using
statement) is used. First of all, this is not more that shortcut. There are alias and regular namespace forms.
Say, your class full name is
My.Namespace.Hot.HotKey
. Then, you can shortcut this full name in usage if you use
using
:
using My.Namespace.Hot;
Hotkey instance;
or
using My.Namespace;
Hot.Hotkey instance;
or
using My;
Namespace.Hot.Hotkey instance;
or, finally alias:
using VeryHot = My.Namespace.Hot.HotKey;
VeryHot instance;
In all cases, you can use the full names of the types, no matter is you use
using
or not.
I hope the examples are clear, but why not reading about it and learning both namespaces and
using
? Please see:
https://msdn.microsoft.com/en-us/library/z2kcy19k.aspx,
https://msdn.microsoft.com/en-us/library/0d941h9d.aspx,
https://msdn.microsoft.com/en-us/library/sf0df423.aspx.
—SA