Skip to main content

Get-Card-Content

Command Description

Get card content in general card recognition results

Command Prototype

sRet = Mage.ExtractCardInfo(jsonRet,invoice_type,invoice_key)

Parameter Description

ParameterRequiredTypeDefaultDescription
jsonRetTrueexpressionjsonRetUse the variable output to the "Screen Customer Template", "Image Card OCR" command, such as the "PDF Custom Template" command, you need to use the value of traverse an array
invoice_typeTrueenum""Select the type of card to be obtained
invoice_keyTrueenum""Select the field under obtaining card type

return

sRet,The variable used to save the output of the command.

Demo

Dim jsonRet=''  // Card identification result, such as: bank card, etc. 

TracePrint "--------------------Get the card content--------------------"
// --------------------------------------------------------
// [Remarks] Get the card content
// Input parameter 1:
// jsonRet--card identification result
// Input parameter 2:
// invoice_type--extraction type
// Input parameter 3:
// invoice_key--extract field

// Output parameters:
// sRet--the variable to which the output of the function call is saved

// Command prototype: sRet = Mage.ExtractCardInfo(jsonRet, invoice_type, invoice_key)
// --------------------------------------------------------

sRet = Mage.ExtractCardInfo(jsonRet,"bank_card","card_number")