Re: C# builder with Mono

David Curylo <[email protected]>
Newsgroups gmane.comp.gnome.mono.general
Message-ID <[email protected]>
This isn’t something the C# language supports.

https://msdn.microsoft.com/en-us/library/0feaad6z.aspx <https://msdn.microsoft.com/en-us/library/0feaad6z.aspx> 

The C# #define does not allow a symbol to be given a value, as in languages such as C++. For example, #define cannot be used to create a macro or to define a constant. If you need to define a constant, use an enum variable. If you want to create a C++ style macro, consider alternatives such as generics. Since macros are notoriously error-prone, C# disallows their use but provides safer alternatives.

> On Apr 25, 2016, at 11:21 AM, Namestnik <[email protected]> wrote:
> 
> I just started learning c #
> I want to pass a variable in the program code when compiling ..
> I would like to do without the resource file, if possible.
> 
> In the program code there is an array:
> string [] conf = { "str1", "str2", "str3", "str4", "str5"};
> 
> 
> I would like to compile redefine its contents
> 
> That is, once the compiler to specify the data to in the compiled exe was
> the actual array
> 
> 
> 
> --
> View this message in context: http://mono.1490590.n4.nabble.com/C-builder-with-Mono-tp4667757.html
> Sent from the Mono - General mailing list archive at Nabble.com.
> _______________________________________________
> Mono-list maillist  -  [email protected]
> http://lists.ximian.com/mailman/listinfo/mono-list

_______________________________________________
Mono-list maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-list
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.