C# Static types cannot be used as parameters

前端 未结 8 2588
被撕碎了的回忆
被撕碎了的回忆 2021-02-18 13:22
public static void SendEmail(String from, String To, String Subject, String HTML, String AttachmentPath = null, String AttachmentName = null, MediaTypeNames AttachmentTy         


        
8条回答
  •  孤城傲影
    2021-02-18 13:38

    You can't pass a static type to a method as a parameter because then it would have to be instantiated, and you can't create an instance of a static class.

提交回复
热议问题