There are a number of threads around where a group of us have been supplying CSS to modify the built-in style of the WebListBox. Here’s a few, but a search of the forums should be enlightening.
In CSS:
.XojoListBox .DTFC_ScrollWrapper,
.XojoListBox .table,
.XojoListBox .dataTables_wrapper tr.buffer {
background-color: #f00 !important;
}
[image]
You can swap the #f00 bit for transparent or any valid color value.
Here’s my solution to preserve all of the previous styling and apply a disabled state to the header (and set the table’s Enabled property).
Add the following method to a module (as I assume you’ll be using this in multiple places, it makes the most sense to create an extension method):
Public Sub setEnabled(extends l as WebListBox, value as Boolean)
l.Enabled = value
l.ExecuteJavaScript( "$('#" + l.ControlID + "')." + if( l.Enabled, "remove", "add" ) + "Class('disabledTable');" )
End Sub
M…
Using what I provided above, replace the App.HTMLHeader content with this to combine everything and remove all borders and backgrounds:
<style>
.borderlessTable,
.borderlessTable table,
.borderlessTable table td,
.borderlessTable table th,
.borderlessTable table tr,
.borderlessTable .dataTables_scrollHead,
.borderlessTable .dataTables_scrollBody {
border-color: transparent !important;
background-color: transparent !important;
background-image: none !important;
}
</st…
1 Like