dreimer Posted February 15, 2013 Share Posted February 15, 2013 (edited) I can't seem to get the Register symbol in my data to come across correctly on my MAC. I have tried changing the encoding to everything when defining my data. This file works just fine using Fusion Pro on my PC. Any ideas??? Edited February 15, 2013 by dreimer Quote Link to comment Share on other sites More sharing options...
dreimer Posted February 15, 2013 Author Share Posted February 15, 2013 (edited) I have a feeling the only way to fix it is to edit my data to be tagged text and replace the ® in the data to ® first. Is that my only option? Edited February 15, 2013 by dreimer Quote Link to comment Share on other sites More sharing options...
Dan Korn Posted February 15, 2013 Share Posted February 15, 2013 There are several options. The simplest is to set the encoding of the data file in the Define Data Source Wizard. On the third dialog, change the drop-down from "Default" to "Latin-1". If you want to edit the data to include a ® entity instead, you don't necessarily have to convert the data to tagged text; you can still use flat-file data with entities as long as you check the "Treat field values as tagged text" box in the Data Source Wizard. You could also try converting the file to Unicode (UTF-16). Or, you could write a simple JavaScript rule to replace the character on Mac; something like this: if (FusionPro.isMac) return ReplaceSubstring(Field("YourFieldName"), "®", "®");In FusionPro 8.1, there's also a ConvertWindowsEncodingToNative() function you can call from JavaScript. Quote Link to comment Share on other sites More sharing options...
dreimer Posted February 15, 2013 Author Share Posted February 15, 2013 I tried both of your first two suggestions and they don't work in preview of composition. I always have this problem with special characters, maybe I have something set incorrectly in preferences or something. I will try the .isMac suggestion here in a little bit. I have already manipulated the flat input data do get what I needed, just was wondering if there were easier ways to do it. Quote Link to comment Share on other sites More sharing options...
dreimer Posted February 15, 2013 Author Share Posted February 15, 2013 No matter what I do with the options in the the data definition my field comes over as "VisaÆ & Amex". So the third option doesn't work either. Quote Link to comment Share on other sites More sharing options...
dreimer Posted February 15, 2013 Author Share Posted February 15, 2013 The MAC interprets the amperstand fine, just doesn't like trademarks, register marks and accented characters for me no matter what I do with the encoding settings! Quote Link to comment Share on other sites More sharing options...
step Posted February 15, 2013 Share Posted February 15, 2013 Since the data was created on the Windows side, the easiest solution would be the replace any instance of ® in your data file with "®". Then replace "®" (FusionPro side) with "®" which is common between the two platforms. You might be able to interpret the windows ASC character with JavaScript with something like: return Chr(Asc("Æ")); but I'm not sure about that. Quote Link to comment Share on other sites More sharing options...
dreimer Posted February 15, 2013 Author Share Posted February 15, 2013 I ended up editing the data before bringing it into FP and that will work, was just wondering if I was missing something or if there was a easy way to fix. Quote Link to comment Share on other sites More sharing options...
Dan Korn Posted February 15, 2013 Share Posted February 15, 2013 I can't offer more specific suggestions or try to guess why it's not working unless you post the job, or at least a sample which reproduces the problem. Quote Link to comment Share on other sites More sharing options...
dreimer Posted February 15, 2013 Author Share Posted February 15, 2013 OK, I attached the collected job. I only included one of the color tiffs of the 18 the job will use to make it small enough to upload. The template is now 18 pages because I had to manually create some of the versions (pages) because the way the superscripting limited me. I would have like to keep it one page and have the data switch to create the version. Scratch that, I get a database error trying to upload the 1.6MB collected file???? Quote Link to comment Share on other sites More sharing options...
Dan Korn Posted February 15, 2013 Share Posted February 15, 2013 OK, I attached the collected job. I only included one of the color tiffs of the 18 the job will use to make it small enough to upload. The template is now 18 pages because I had to manually create some of the versions (pages) because the way the superscripting limited me. I would have like to keep it one page and have the data switch to create the version. Scratch that, I get a database error trying to upload the 1.6MB collected file???? Sorry, our IT people are still working on the upload issues. Can you attach just the template PDF and the data file? The TIFF images shouldn't be relevant to the character encoding issue in question. Quote Link to comment Share on other sites More sharing options...
dreimer Posted February 18, 2013 Author Share Posted February 18, 2013 (edited) So I changed just the page 1 and page 6 of the template to black text since the tiffs are not included and the background would be missing. The data comes across fine on my PC but on the MAC no matter what I try in the definition of the data, it will not work as is. Record 43 is where my problem starts. I left page 6 to show me hardcoding the field the way I want and then under that how it comes in from the variable field. This is why I made the template 18 pages so I could make the changes for versions with problems. I guess I could have left it one page and wrote some rules to do the same. Either way, just trying to figure out a way to get the MAC to see the data the same as the PC. Thanks.72694_MAIN_FP.pdf72694_Main.txt Edited February 18, 2013 by dreimer Quote Link to comment Share on other sites More sharing options...
Dan Korn Posted February 18, 2013 Share Posted February 18, 2013 This works for me: if (FusionPro.isMac) return ReplaceSubstring(Field("Category Description"), Chr(174), Chr(168)); //else return Field("Category Description"); Quote Link to comment Share on other sites More sharing options...
dreimer Posted February 18, 2013 Author Share Posted February 18, 2013 OK, I will give it a try. Is there a reason the else is after the "//"? Also, is there a way to incorporate my superscript rule into that same rule? var s = Field("Category Description"); // replace with your field return s.replace(/\®/g,"<superscript>®</superscript>"); Quote Link to comment Share on other sites More sharing options...
dreimer Posted February 18, 2013 Author Share Posted February 18, 2013 Hmmm, it previews the rule correctly, but when I impose it doesn't come out correctly. I tried the treat return strings as tagged text box checked and unchecked, no difference. Quote Link to comment Share on other sites More sharing options...
Dan Korn Posted February 18, 2013 Share Posted February 18, 2013 OK, I will give it a try. Is there a reason the else is after the "//"? After a "return" statement, the "else" statement is moot, since you're exiting the rule anyway. You could uncomment the "else" and it would work exactly the same way. Also, is there a way to incorporate my superscript rule into that same rule? var s = Field("Category Description"); // replace with your field return s.replace(/\®/g,"<superscript>®</superscript>"); Just have the rule doing the superscripting call the other rule. Hmmm, it previews the rule correctly, but when I impose it doesn't come out correctly. I tried the treat return strings as tagged text box checked and unchecked, no difference. You need to be more specific about exactly how it's not coming out correctly. If you post the FPI file, I can try to reproduce what you're seeing. Quote Link to comment Share on other sites More sharing options...
dreimer Posted February 18, 2013 Author Share Posted February 18, 2013 Sorry I didn't phrase that correctly. The data string looks correct when I validate the rule, but when I preview the template or compose it, the data string isn't correct. I haven't even applied the imposition file. Quote Link to comment Share on other sites More sharing options...
Dan Korn Posted February 19, 2013 Share Posted February 19, 2013 Sorry I didn't phrase that correctly. The data string looks correct when I validate the rule, but when I preview the template or compose it, the data string isn't correct. I haven't even applied the imposition file. The output looks correct when I compose your sample job, with that change, in FusionPro 8.2 on my Mac. But I don't have all your fonts. So I would try to output in Helvetica and see it that looks right. If so, then it's a font-specific issue. If not, then the issue would seem to be specific to the version of FusionPro. Also, are you sure you're using the result of the rule in your output? Quote Link to comment Share on other sites More sharing options...
dreimer Posted February 19, 2013 Author Share Posted February 19, 2013 Must be a version problem. I attached the output, the top text is my harcoding the information and the bottom is using the rule with Helvetica for the font.72694_Test.pdf Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.