Skip to main content
Solved

put.. only part of string in text file

  • June 4, 2019
  • 1 reply
  • 54 views

Hi,

I have this code that prints the variables to a text file.

code:
for IndexVariables do
put(IndexVariables);
put // ;
endfor;


This prints only the first 12 characters of each variable.
Why is that?

Thanks, WM

Best answer by deannezhang

The default column width of put statement is 12. You can change it by :m, where m is the new width. for example

for IndexVariables do
put IndexVariables:15;
put // ;
endfor;

1 reply

deannezhang
AIMMS Champ
Forum|alt.badge.img+3
  • AIMMS Champ
  • 61 replies
  • Answer
  • June 5, 2019
The default column width of put statement is 12. You can change it by :m, where m is the new width. for example

for IndexVariables do
put IndexVariables:15;
put // ;
endfor;


Didn't find what you were looking for? Try searching on our documentation pages:

AIMMS Developer & PRO | AIMMS How-To | AIMMS SC Navigator