Copy link to clipboard
Copied
I'm not sure if there is a way to do this or not, but here is my situation and question.
I have created a form that auto-fills a user's name, which is pulled from the LMS system (Absorb LMS) so it will give them a "certificate" when they complete a course. The PDF form I have created is the certificate. What I want is for their name (which is uppper and lower case in the system) to come out as all caps on the PDF certificate.
I've tried the other scripts such as
event.value = event.value.toUpperCase(); and
event.value = event.value.toString().toUpperCase() ; and even
if(!event.WillCommit)event.change = event.change.toUpperCase() ;
but I these don't seem to work and I think it could be because they are not typing in their name--it is being autofilled with information that is pulled directly from the system.
So my questions are
1) is there actually a way to make this happen?
2) if so, what is the script? (I don't know anything about writing my own scripts, but am quite adept at copy and paste.
Any direction in this area would be appreciated.
Copy link to clipboard
Copied
The issue is that importing the data is not triggering any events, so your code never gets a chance to work.
If you apply the first code you posted as the calculation script of your field then you just need to force a calculation when the file is opened, and it should work.
To do that embed the following as a doc-level script:
this.calculateNow();