Tuesday, July 28, 2020

PowerApps Process receipts with AI Builder

Process receipts with AI Builder

The introduction of a new model in AI Builder: Receipt processing. Now available in preview, you can test the feature right away, no trial or subscription required.
Expense reports can be a very cumbersome and time-consuming task. Between all the manual data entry, approval workflows, and auditing, there are many pain points across the end-to-end process. With the AI Builder receipt processing prebuilt model, you can minimize those pain points and increase the productivity of your employees, delivering real value back to your business.
Receipt processing lets you read and save key information from common sales receipts, like those used in restaurants, gas stations, retail, and more. Using this information, you can automatically pre-populate expense reports simply by scanning photos of your receipts. And when you automate the process at a large scale, there is the potential to save you and your business valuable time and money.
The prebuilt model uses state-of-the-art optical character recognition (OCR) to extract both printed and handwritten text from receipts. You can retrieve valuable information such as the merchant details, transaction date and time, list of purchased items, tax, and totals.
No training or prior configuration is required to use this prebuilt model. Start processing receipts right away in your apps and flows using the new canvas app component and AI Builder flow action.



Wednesday, July 22, 2020

Interesting facts about #if Debug vs Conditional Debug attributes

#if Debug

[Conditional("Debug")]

1 2 3 4 #if DEBUG public void SetPrivateValue(int value) { ... } #endif

 

1 2 3 [System.Diagnostics.Conditional("DEBUG")] public void SetPrivateValue(int value) { ... }

 

#if DEBUG: The code won't even reach the IL(Common Intermediate Language) on release.

 

The code will reach the IL, however calls to the method will be omitted unless DEBUG is set when the caller is compiled.

1 2 3 4 5 #if DEBUG public const String ENDPOINT = "Localhost"; #else public const String ENDPOINT = "BasicHttpBinding"; #endif

 the const ENDPOINT is set to "Localhost" or "BasicHttpBinding" depending on if DEBUG is set or not.

1 2 3 4 5 6 7 8 [Conditional("DEBUG")] public void DoSomething() { } public void Foo() { DoSomething(); //Code compiles and is cleaner, DoSomething always //exists, however this is only called during DEBUG. }

The code all exists, but is just ignored unless DEBUG is on. 

You can use this construct semantic/syntax to any method with return type or any code block

Whereas this is only works with void return value.

Penetration test/Security test code analysis will be give goahead as it is safe.

Whereas security assessment will flag it high severity in case when it is deployed to production environment.