How to set named argument for string.Format?

后端 未结 2 1718
离开以前
离开以前 2020-12-20 13:35

I have C# error when calling:

string.Format(format:\"abbccc\", 1,22);

The error is \"Named argument specifications must appear after al

2条回答
  •  囚心锁ツ
    2020-12-20 13:58

    In my case, I had to Clean and Rebuild the solution, that made the error go away. What happened was, I added an argument like this

    sched.ScheduleJob(Jobdetail:job, trigger);

    I was getting an error for trigger, so I removed, JobDetail:, and the syntax error go away but on complication I was still getting the error

    Named argument specifications must appear after all fixed arguments have been specified

    I cleaned the solution and rebuilt and the error went away.

提交回复
热议问题