Jump to content

Recommended Posts

Posted

I have a column that contains text in different lengths, so I am using the 'Adjust Text to Overflow' function so it will size down text that is too long. This is working great, except when that field is empty, it then gives me this message-

 

OnCopyfit, line 3: warning: Could not copyfit text in flow

 

My quantity is 0ver 24,000 and I have 5 columns where this is happening. Is it possible to acomplish this task with out getting a ton of 'fake' error messages?

Posted

Can you be more specific about your issue? The Copyfit function reports that error when the text it's trying to fit into a text flow will not fit given the defined parameters (max and mins of pointsize and magnification). So with that in mind, it doesn't seem possible that it would be unable to fit an empty field into a text flow.

 

What do you mean when you say that you have a "column that contains text in different lengths?" Is a column a field? Are your empty fields in a table? Are you applying tags to them? It's really difficult to say without a better explanation of the problem. Posting your template and data would help. Even posting the text rule and your copyfit rule would be helpful.

 

Aside from that all I can really suggest is ensuring that the fields are truly empty in your data.

Posted

The Copyfit function isn't expecting to work with an empty text flow. You can avoid the warning message by changing the OnCopyfit rule syntax to this:

if (FusionPro.Composition.CurrentFlow.content && !Copyfit(new MagnifyAttributes("text", 25, 400, 6, 72)))
   ReportWarning("Could not copyfit text in flow " + 
                 FusionPro.Composition.CurrentFlow.name);

Posted

Dan,

 

I copied and pasted the syntax for the OnCopy rule, and I still received the warning message. Is there another way to make the longer text fields fit, without using that rule?

Posted
I copied and pasted the syntax for the OnCopy rule, and I still received the warning message. Is there another way to make the longer text fields fit, without using that rule?

It works for me with an empty frame. I don't know how to reproduce the exact circumstances that are causing the message to appear in your job. Can you collect up the job, or a minimal example which reproduces the issue, and post it here?

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...