VBAEXCELNew
New Member
- Joined
- Apr 3, 2023
- Messages
- 38
- Office Version
- 365
- 2021
- Platform
- Windows
Hello,
in my vba i would like table border to be black but however after a lot of test trying to add in css it dont work, i have realize that the only style i can use is through excel vba style for tables
I am trying to get my table that i have created in vba to have a border that is black or xlContinuous but so far no luck does anyone know how ?
in my vba i would like table border to be black but however after a lot of test trying to add in css it dont work, i have realize that the only style i can use is through excel vba style for tables
I am trying to get my table that i have created in vba to have a border that is black or xlContinuous but so far no luck does anyone know how ?
VBA Code:
HtmlContent = "<table>"
HtmlContent = "<br><table border='1'><tbody>"
'strQuotation = Trim(ThisWorkbook.Sheets("Master Table").Range("B" & R.Offset(0, 1)).Text)
HtmlContent = HtmlContent & "<tr><th>Quotation / DC No.:</th><td>" & R.Offset(0, 1) & "</td></tr>"
HtmlContent = HtmlContent & "<tr><th>Description:</th><td>" & R.Offset(0, 2) & "</td></tr> "
HtmlContent = HtmlContent & "<tr><th>Status:</th><td>" & R.Offset(0, 0) & "<br>" & R.Offset(0, 5) & "<br>" & "</td></tr>"
HtmlContent = HtmlContent & "<tr><th>Remarks:</th> <td>" & R.Offset(0, 8) & "</td></tr>"
HtmlContent = HtmlContent & "</tbody></table>"