2017-09-15 46 views
0
static void Main() 
{ 
var config = new JobHostConfiguration(); 
config.UseTimers(); 
var host = new JobHost(config); 
host.RunAndBlock(); 
} 

public static void TimerTrig1([TimerTrigger("00:00:02")] TimerInfo timer) 
{ 
    Console.WriteLine("Triggered"); 
} 

public static void TimerTrig2([TimerTrigger("00:00:04")] TimerInfo timer) 
{ 
    Console.WriteLine("Triggered"); 
} 

觸發我已經出版了蔚藍的代碼,但它給我的錯誤 Click for Error但我在Azure上的門戶Click for Image設置連接字符串解決。但仍然發生。我的方法不會觸發。時間觸發的方法不是在Azure的網絡招聘

回答

0
I have published that code on azure but it give me error Click for Error 
that "** System.InvalidOperationException: Failed to validate Microsoft 
Azure WebJobs SDK Dashboard connection string**. " I resolve it by setting 
connection string on Azure portal [enter image description here][1] [Click 
for detail][2]. but still noting happened. My Methods were not triggering 
so after that i Fund out that i have to make my methods public like this 
[enter image description here][3]. And Finally it run. Output [enter image 
description here][4]