{"id":679,"date":"2017-01-03T19:41:59","date_gmt":"2017-01-03T19:41:59","guid":{"rendered":"https:\/\/ibex.tech\/windows-iot\/?p=342"},"modified":"2024-07-04T14:52:53","modified_gmt":"2024-07-04T13:52:53","slug":"get-app-version","status":"publish","type":"post","link":"https:\/\/ibex.tech\/csharp\/uwp-programming-in-c\/application-control-uwp-programming-in-c\/get-app-version","title":{"rendered":"Get App Version"},"content":{"rendered":"\n<pre class=\"wp-block-code\"><code>\t\/\/Get application version\n\tWindows.ApplicationModel.Package package = Windows.ApplicationModel.Package.Current;\n\tWindows.ApplicationModel.PackageId packageId = package.Id;\n\tWindows.ApplicationModel.PackageVersion version = packageId.Version;\n\tString AppVersion = String.Format(\"{0:D2}\", version.Major) +  String.Format(\"{0:D2}\", version.Minor);\t\t\/\/Also available: version.Build, version.Revision<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"","protected":false},"author":5,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[147],"tags":[],"class_list":["post-679","post","type-post","status-publish","format-standard","hentry","category-application-control-uwp-programming-in-c"],"_links":{"self":[{"href":"https:\/\/ibex.tech\/csharp\/wp-json\/wp\/v2\/posts\/679","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ibex.tech\/csharp\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ibex.tech\/csharp\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ibex.tech\/csharp\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/ibex.tech\/csharp\/wp-json\/wp\/v2\/comments?post=679"}],"version-history":[{"count":1,"href":"https:\/\/ibex.tech\/csharp\/wp-json\/wp\/v2\/posts\/679\/revisions"}],"predecessor-version":[{"id":1205,"href":"https:\/\/ibex.tech\/csharp\/wp-json\/wp\/v2\/posts\/679\/revisions\/1205"}],"wp:attachment":[{"href":"https:\/\/ibex.tech\/csharp\/wp-json\/wp\/v2\/media?parent=679"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ibex.tech\/csharp\/wp-json\/wp\/v2\/categories?post=679"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ibex.tech\/csharp\/wp-json\/wp\/v2\/tags?post=679"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}