I use PDF figures that are output by Excel with excessive whitespace. There are only a few standard sizes, so I would like to define re-usable variable to set in the [trim = ???] option for the \includegraphics[]{} command.
I have tried putting this at the beginning:
\newcommand{\exsff}{trim = {1in 3.5in 1in 3.5in}}
and this when I insert the graphic:
\includegraphics[width=1\linewidth, \exsff]{figure_name}
but I get an error. If I hardcode it in like this, it works:
\includegraphics[width=1\linewidth, trim = {1in 3.5in 1in 3.5in}]{figure_name}
Any suggestions?

\setkeys{Gin}{trim=1in 3.5in 1in 3.5in}should set the default trim setting – David Carlisle Mar 16 '15 at 18:57[trim = \xxx], [trim = \yyy], or [trim = \zzz]
where I can define xxx, yyy, and zzz as a list of the four parameters I need. As in, xxx = {1in 2in 1in 2in} and so on.
– jamesssss Mar 16 '15 at 19:43[scale=\scalefactor]instead of[\scaleconfig]) doesn't work fortrim. This question is rather a duplicate of https://tex.stackexchange.com/questions/222043/how-to-expand-a-macro-into-viewport-argumentsincludegraphics . – jeremie Nov 28 '19 at 13:40