{"id":24,"date":"2007-06-20T06:43:46","date_gmt":"2007-06-20T06:43:46","guid":{"rendered":"https:\/\/www.wapshere.com\/missmiis\/?page_id=24"},"modified":"2008-01-18T16:24:49","modified_gmt":"2008-01-18T16:24:49","slug":"function-runqueuedjob","status":"publish","type":"page","link":"https:\/\/www.wapshere.com\/missmiis\/code-snippets\/function-runqueuedjob","title":{"rendered":"jobRunner.vbs: Function RunQueuedJob"},"content":{"rendered":"<p style=\"margin: 0cm 0cm 0pt\" class=\"MsoNormal\"><span lang=\"EN-GB\"><font face=\"Times New Roman\">Calls the appropriate sub based on what was found in the Queue. For an explanation of the subs see <a href=\"https:\/\/www.wapshere.com\/missmiis\/?p=26\">this post<\/a>.<\/font><\/span><\/p>\n<p style=\"margin: 0cm 0cm 0pt\" class=\"Code\"><span lang=\"EN-GB\"><font size=\"1\" face=\"Microsoft Sans Serif\">Function RunQueuedJob(Task, Name, Profile)<\/font><\/span><\/p>\n<p style=\"margin: 0cm 0cm 0pt\" class=\"Code\"><span lang=\"EN-GB\"><font size=\"1\"><font face=\"Microsoft Sans Serif\"><span>\u00c2\u00a0 \u00c2\u00a0 <\/span>Dim Status<\/font><\/font><\/span><\/p>\n<p style=\"margin: 0cm 0cm 0pt\" class=\"Code\"><span lang=\"EN-GB\"><font size=\"1\"><font face=\"Microsoft Sans Serif\"><span>\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0 <\/span>If LCase(Task) = \u00e2\u20ac\u0153rundts\u00e2\u20ac\u009d Then<\/font><\/font><\/span><\/p>\n<p style=\"margin: 0cm 0cm 0pt\" class=\"Code\"><span lang=\"EN-GB\"><font size=\"1\"><font face=\"Microsoft Sans Serif\"><span>\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0 <\/span>RunDTS Name<\/font><\/font><\/span><\/p>\n<p style=\"margin: 0cm 0cm 0pt\" class=\"Code\"><span lang=\"EN-GB\"><font size=\"1\"><font face=\"Microsoft Sans Serif\"><span>\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0 <\/span>ElseIf LCase(Task) = \u00e2\u20ac\u0153runsub\u00e2\u20ac\u009d Then<\/font><\/font><\/span><\/p>\n<p style=\"margin: 0cm 0cm 0pt\" class=\"Code\"><span lang=\"EN-GB\"><font size=\"1\"><font face=\"Microsoft Sans Serif\"><span>\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0 <\/span>RunSub Name<\/font><\/font><\/span><\/p>\n<p style=\"margin: 0cm 0cm 0pt\" class=\"Code\"><span lang=\"EN-GB\"><font size=\"1\"><font face=\"Microsoft Sans Serif\"><span>\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0 <\/span>ElseIf LCase(Task) = \u00e2\u20ac\u0153runprofile\u00e2\u20ac\u009d Then<\/font><\/font><\/span><\/p>\n<p style=\"margin: 0cm 0cm 0pt\" class=\"Code\"><span lang=\"EN-GB\"><font size=\"1\"><font face=\"Microsoft Sans Serif\"><span>\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0 <\/span>Status = RunProfile(Name, Profile)<\/font><\/font><\/span><\/p>\n<p style=\"margin: 0cm 0cm 0pt\" class=\"Code\"><span lang=\"EN-GB\"><font size=\"1\"><font face=\"Microsoft Sans Serif\"><span>\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0 <\/span>If Profile = \u00e2\u20ac\u0153Delta Import and Delta Sync\u00e2\u20ac\u009d And status = 0 Then<\/font><\/font><\/span><\/p>\n<p style=\"margin: 0cm 0cm 0pt\" class=\"Code\"><span lang=\"EN-GB\"><font size=\"1\"><font face=\"Microsoft Sans Serif\"><span>\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0 <\/span>ClearDeltaTable(MA)<\/font><\/font><\/span><\/p>\n<p style=\"margin: 0cm 0cm 0pt\" class=\"Code\"><span lang=\"EN-GB\"><font size=\"1\"><font face=\"Microsoft Sans Serif\"><span>\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0 <\/span>End If<\/font><\/font><\/span><\/p>\n<p style=\"margin: 0cm 0cm 0pt\" class=\"Code\"><span lang=\"EN-GB\"><font size=\"1\"><font face=\"Microsoft Sans Serif\"><span>\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0 <\/span>End If<\/font><\/font><\/span><\/p>\n<p style=\"margin: 0cm 0cm 0pt\" class=\"Code\"><span lang=\"EN-GB\"><font size=\"1\" face=\"Microsoft Sans Serif\">End Function<\/font><\/span><\/p>\n<p><span lang=\"EN-GB\"><\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Calls the appropriate sub based on what was found in the Queue. For an explanation of the subs see this post. Function RunQueuedJob(Task, Name, Profile) \u00c2\u00a0 \u00c2\u00a0 Dim Status \u00c2\u00a0\u00c2\u00a0\u00c2\u00a0 If LCase(Task) = \u00e2\u20ac\u0153rundts\u00e2\u20ac\u009d Then \u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0 RunDTS Name \u00c2\u00a0\u00c2\u00a0\u00c2\u00a0 ElseIf LCase(Task) = \u00e2\u20ac\u0153runsub\u00e2\u20ac\u009d Then \u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0 RunSub Name \u00c2\u00a0\u00c2\u00a0\u00c2\u00a0 ElseIf LCase(Task) = \u00e2\u20ac\u0153runprofile\u00e2\u20ac\u009d Then \u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0\u00c2\u00a0 Status&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":30,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"jetpack_post_was_ever_published":false,"footnotes":""},"class_list":["post-24","page","type-page","status-publish","hentry"],"jetpack_shortlink":"https:\/\/wp.me\/Pkp1o-o","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/www.wapshere.com\/missmiis\/wp-json\/wp\/v2\/pages\/24","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wapshere.com\/missmiis\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.wapshere.com\/missmiis\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.wapshere.com\/missmiis\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wapshere.com\/missmiis\/wp-json\/wp\/v2\/comments?post=24"}],"version-history":[{"count":0,"href":"https:\/\/www.wapshere.com\/missmiis\/wp-json\/wp\/v2\/pages\/24\/revisions"}],"up":[{"embeddable":true,"href":"https:\/\/www.wapshere.com\/missmiis\/wp-json\/wp\/v2\/pages\/30"}],"wp:attachment":[{"href":"https:\/\/www.wapshere.com\/missmiis\/wp-json\/wp\/v2\/media?parent=24"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}