ví dụ một!. Built in Attributes ví dụ thể hiện một hàm dung cho Debug PHP Code: using System; using System.Diagnostics; namespace AdvancedDotnet { class MainClass { [Conditional"DEB
Trang 1ví dụ một!
Built in Attributes
ví dụ thể hiện một hàm dung cho Debug
PHP Code:
using System;
using System.Diagnostics;
namespace AdvancedDotnet
{
class MainClass
{
[Conditional("DEBUG")|
public static void MsgDebug(string msg) {
Console WriteLine(msg);
)
public static void Main()
{
Console WriteLine("this testing for ConditionalAttribute, Before calling MsgDeb ug()");
MsgDebug("Trying out Attributes");
Console.Read();
j
j
j
khi chay chú ý ở 2 chế độ Debug và Release
nếu chay Debug ta sé thay
Quote:
this testing for ConditionalAttribute, Before calling MsgDebug()
Trying out Attributes
nhưng nếu chạy 6 Release thi chi thay
Quote:
this testing for ConditionalAttribute, Before calling MsgDebug()
Trang 2do không có nhiêu thời gian nêu mình post mà không có chú thích nhiêu Bro nào có gì hỏi thì cứ post nha! mình sẽ cô găng trả lời!
dauden(UDS)