Rishabh Shukla
Rishabh Shukla

Reputation: 1

How to add square border in xaml

I am working on the xamarin forms and using the xaml to make the UI.

enter image description here

Please see the aboveimage and let me know how to draw this in xaml and in the image number is dynamic

Upvotes: 0

Views: 203

Answers (2)

François
François

Reputation: 3274

Use AbsoluteLayout and just use an image (or better a svg) on top of which you add a Label bound to your int value.

Upvotes: 0

EvZ
EvZ

Reputation: 12179

You could use Frame, here is a simple example:

<Frame OutlineColor="White" BackgroundColor="Black">
    <Label Text="{Binding MyNumber}" TextColor="White" />
</Frame>

The outcome:
enter image description here

Upvotes: 2

Related Questions