Select to view content in your preferred language

DateTimePickerControl has fixed internal margin

328
3
03-07-2025 02:37 AM
AnkushMadankar
Emerging Contributor

I am trying to use ArcGIS.Desktop.Framework.Controls.DateTimePickerControl in xaml. But control has fixed internal margin of 4. I am not able to remove this margin anyhow. Here is sample code. I have added border to show extra fixed internal margin.

<controls:DateTimePickerControl BorderBrush="Red" BorderThickness="1"/>

AnkushMadankar_0-1741343615608.png

 

0 Kudos
3 Replies
CodyPatterson
MVP Regular Contributor

Hey @AnkushMadankar 

I haven't specifically edited the margins in this way before, but something you may be able to do is increase the size of the input box, and then shrink the border margins to fit that new input box using negative margins. This will visually bring everything together, but I have not been able to personally get the internal margins fixed, typically this is extremely easy to do in HTML/CSS, but this has an extra layer of complexity.

Cody

0 Kudos
AnkushMadankar
Emerging Contributor

I am trying to avoid providing negative margin for control which likely to take space from other controls. With even providing margin of 0 control not able to remove extra internal margin. Somehow I don't see any style option provided by esri to override.

0 Kudos
CodyPatterson
MVP Regular Contributor

Hey @AnkushMadankar 

I believe this may be a limitation in the ability to edit this to the extent you would like. You may be able to submit a ticket to ESRI support to verify that this would be possible to do, if you do so, please let me know as I'd like to know as well!

Cody

0 Kudos