Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
3

Display date field in small caps only

Community Beginner ,
Sep 05, 2023 Sep 05, 2023

Hi,

 

I am trying to fix a little issue with a PDF file we use for contracts. I used a personalized format for the date field (dd mmmm yyyy) but unfortunately it keeps capitalizing the month. These documents are in French, and capitalizing the first letter of the month is a grammatical mistake, so I'd like to change it to be displayed in small caps only but I'm falling short on that one. I know I'll probably need some type of script but I'm not well versed in that area, any help would be appreciated!

 

 

TOPICS
How to , PDF , PDF forms
594
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Sep 05, 2023 Sep 05, 2023

Fastoche !

 

util.printd("date(fr){DD MMMM YYYY}", new Date(), true);

 


Acrobate du PDF, InDesigner et Photoshopographe
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Sep 05, 2023 Sep 05, 2023

Hi JR,

 

Not sure if I'm putting it in the wrong spot, I tried both in validation and calculation (in the properties tab of the date field) and it's not working, does it go somewhere else? Merci 🙂

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Sep 05, 2023 Sep 05, 2023
LATEST

Use this script as a Custom Format Script:

 

var d = util.scand("dd/mm/yyyy", event.value); //récupère la date saisie
if (d == null) { // si la date n'est pas valide ou ne correspond pas au format dd/mm/yyy
app.alert("Merci de saisir une date au format JJ/MM/AAAA");
event.rc = false;
}
else {event.value = util.printd("date(fr){D MMMM YYYY}", d, true)}

 

 

 

 

Capture_2309060120.png


Acrobate du PDF, InDesigner et Photoshopographe
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines