Search code examples
angularsmsqr-code

How do i launch SMS mobile app from a QR code scanning using angularx-qrcode library?


Original (documentation):

<qrcode [qrdata]="'Your data string'" [width]="256" [errorCorrectionLevel]="'M'"></qrcode>

What i want:

<qrcode [qrdata]="<Open SMS app with the the number to send and text i need to write>" [width]="256" [errorCorrectionLevel]="'M'"></qrcode>

Solution

  • I already knew how to achieve it

    This is the way:

    <qrcode [qrdata]="'SMSTO:<phonenumber>:<Text message here>'"[width]="256" [errorCorrectionLevel]="'M'"></qrcode>