{"id":1378,"date":"2017-10-11T07:41:39","date_gmt":"2017-10-11T13:41:39","guid":{"rendered":"https:\/\/toddbaginski.com\/blog\/?p=1378"},"modified":"2018-06-04T14:48:04","modified_gmt":"2018-06-04T18:48:04","slug":"powerapps-grammar-school","status":"publish","type":"post","link":"https:\/\/toddbaginski.com\/blog\/powerapps-grammar-school\/","title":{"rendered":"PowerApps Grammar School"},"content":{"rendered":"<p>Here&#8217;s a little function you can use to ensure your PowerApps follow basic English language grammar rules for the words A and AN.<\/p>\n<p>This function displays the words A and AN appropriately, based on the word that comes after them in a sentence.<\/p>\n<p><code>If(IsMatch(<strong>&lt;TEXT TO EVALUATE&gt;<\/strong>, \"[AEIOUaeiou]\", BeginsWith), \"an \", \"a \")<\/code><\/p>\n<p><strong>Note:\u00a0<\/strong>This function does not take into account special cases like the words university and honor, but you could easily adapt the logic to handle additional words.<\/p>\n<p>The following screenshots show it in action.<\/p>\n<p><a href=\"https:\/\/toddbaginski.com\/blog\/wp-content\/uploads\/2017\/10\/PA-Grammar-1.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1376\" src=\"https:\/\/toddbaginski.com\/blog\/wp-content\/uploads\/2017\/10\/PA-Grammar-1.jpg\" alt=\"\" width=\"921\" height=\"430\" srcset=\"https:\/\/toddbaginski.com\/blog\/wp-content\/uploads\/2017\/10\/PA-Grammar-1.jpg 921w, https:\/\/toddbaginski.com\/blog\/wp-content\/uploads\/2017\/10\/PA-Grammar-1-300x140.jpg 300w, https:\/\/toddbaginski.com\/blog\/wp-content\/uploads\/2017\/10\/PA-Grammar-1-768x359.jpg 768w, https:\/\/toddbaginski.com\/blog\/wp-content\/uploads\/2017\/10\/PA-Grammar-1-260x121.jpg 260w, https:\/\/toddbaginski.com\/blog\/wp-content\/uploads\/2017\/10\/PA-Grammar-1-50x23.jpg 50w, https:\/\/toddbaginski.com\/blog\/wp-content\/uploads\/2017\/10\/PA-Grammar-1-150x70.jpg 150w\" sizes=\"auto, (max-width:767px) 480px, (max-width:921px) 100vw, 921px\" \/><\/a><\/p>\n<p><a href=\"https:\/\/toddbaginski.com\/blog\/wp-content\/uploads\/2017\/10\/PA-Grammar-2.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1377\" src=\"https:\/\/toddbaginski.com\/blog\/wp-content\/uploads\/2017\/10\/PA-Grammar-2.jpg\" alt=\"\" width=\"924\" height=\"436\" srcset=\"https:\/\/toddbaginski.com\/blog\/wp-content\/uploads\/2017\/10\/PA-Grammar-2.jpg 924w, https:\/\/toddbaginski.com\/blog\/wp-content\/uploads\/2017\/10\/PA-Grammar-2-300x142.jpg 300w, https:\/\/toddbaginski.com\/blog\/wp-content\/uploads\/2017\/10\/PA-Grammar-2-768x362.jpg 768w, https:\/\/toddbaginski.com\/blog\/wp-content\/uploads\/2017\/10\/PA-Grammar-2-260x123.jpg 260w, https:\/\/toddbaginski.com\/blog\/wp-content\/uploads\/2017\/10\/PA-Grammar-2-50x24.jpg 50w, https:\/\/toddbaginski.com\/blog\/wp-content\/uploads\/2017\/10\/PA-Grammar-2-148x70.jpg 148w\" sizes=\"auto, (max-width:767px) 480px, (max-width:924px) 100vw, 924px\" \/><\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Here&#8217;s a little function you can use to ensure your PowerApps follow basic English language grammar rules for the words A and AN. This function displays<span class=\"excerpt-hellip\"> [\u2026]<\/span><\/p>\n","protected":false},"author":1,"featured_media":1379,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[103,96,104,121],"tags":[10,5,54,112],"class_list":["post-1378","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-cloud","category-mobile","category-office-365","category-powerapps","tag-custom-development","tag-helpful-code","tag-mobile","tag-powerapps"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/toddbaginski.com\/blog\/wp-json\/wp\/v2\/posts\/1378","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/toddbaginski.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/toddbaginski.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/toddbaginski.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/toddbaginski.com\/blog\/wp-json\/wp\/v2\/comments?post=1378"}],"version-history":[{"count":2,"href":"https:\/\/toddbaginski.com\/blog\/wp-json\/wp\/v2\/posts\/1378\/revisions"}],"predecessor-version":[{"id":1381,"href":"https:\/\/toddbaginski.com\/blog\/wp-json\/wp\/v2\/posts\/1378\/revisions\/1381"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/toddbaginski.com\/blog\/wp-json\/wp\/v2\/media\/1379"}],"wp:attachment":[{"href":"https:\/\/toddbaginski.com\/blog\/wp-json\/wp\/v2\/media?parent=1378"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/toddbaginski.com\/blog\/wp-json\/wp\/v2\/categories?post=1378"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/toddbaginski.com\/blog\/wp-json\/wp\/v2\/tags?post=1378"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}