Forum Discussion
EverettPatterso
5 years agoQrew Captain
Close, but string literal was missing the single quotes to enclose the text variable
------------------------------
Everett Patterson
------------------------------
var text message = "My Test Message";
var text Danger = "<a style=\" text-decoration: none; background: #FF0000; border-radius: 5px; color: #fff; display: inline-block; width: 220px; text-align: center; padding: 8px 20px; font: normal 700 14px/1 \"Calibri\", sans-serif; text-shadow: none; \" href=\"javascript:alert('" & $message & "')\">MS Readiness</a>";
$danger​
------------------------------
Everett Patterson
------------------------------
- PaulPeterson15 years agoQrew Assistant CaptainEvan,
Your approach handles part of the desired results. This will work for form view, but I would like the same functionality from the reports. Perhaps I could use SW and create a modal.
Everett,
I tried your change and have the same result.
------------------------------
Paul Peterson
------------------------------- BradLemke5 years agoQrew Assistant CaptainJust for kicks, give this one a shot: javascript:alert(\"" & $message & "\")
It's not always the case, but there are times when using the \" in place of a single ' will make an otherwise perfect code actually function with Javascript. They're both effectively accomplishing the same task, but the single ' can be inconsistent from time to time.
------------------------------
Brad Lemke
------------------------------- PaulPeterson15 years agoQrew Assistant CaptainYep, that was one of the things I tried too. same result
------------------------------
Paul Peterson
------------------------------