按F11时,我的代码找不到我的静态方法

时间:2016-08-15 13:41:50

标签: c# enums static sms

我有一个静态类,它获取了保存文本的方法。在我调试时的业务逻辑上,按F11调试类。它给出了以下错误。我错过了什么?

找不到方法:System.String info.Notifications.AppointmentBookedText(Int32, Int32, Int32, Int32, Int32)

类。

   public static class Notifications
   {
      public enum SmsTypeCatergory
      {
          AppointmentCreated = 1,
      }
   }

public static string AppointmentBookedText(int claimId, int day, int month, int year, int time)
{
    string Text = "Your doctor's appointment has been booked for " + day + " " + month + " " + year + " " + time + ".";
    return Text;
}

商业逻辑

    public void SMSConfirmation(int SmsTypeId)
    {
        switch (SmsTypeId)
        {

            case (int)Notifications.SmsTypeCatergory.AppointmentCreated:
                Notifications.SendSMSSingle(this.Cellnumber, Notifications.AppointmentBookedText(this.day, Convert.ToInt32(this.month.ToString()), this.year, Convert.ToInt32(this.time.ToString())));
                break;
        }
    }

0 个答案:

没有答案