I got a snippet of c# code from Koders and all the code greyed up after
#if 开发者_开发问答CONFIG_CRYPTO && CONFIG_FRAMEWORK_1_2
What I am suppose to do to match the condition?
(I use Visual Studio)
Suggestions :
put a little more information in your question : a link to the source on Koders.com ? Maybe tell us, in general terms, what the library this is part of is doing ?
Go back to Koders, and examine the complete code for the library (assuming it's not obfuscated), and figure out the role of the Boolean variables CONFIG_CRYPTO and CONFIG_FRAMEWORK_1_2 : what code sets them; what is their function.
Experiment : comment out the #if block enclosure out, and see if the code will work on your machine.
Also note that you can enable conditional compilation flags like these by right-clicking your project in the Solution Explorer, clicking the Build tab, going to the "Conditional compilation symbols" field, and entering "CONFIG_CRYPTO CONFIG_FRAMEWORK_1_2" (symbols separated by a space).
Of course, I agree with BillW, it's nice to understand the purpose behind the symbols first.
精彩评论