Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 6963 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

Hello All!

Ok, I have a script that would import a credit report, and parse it's contents into my database. In FM7, I used a substitute function to get rid of specific CR characters in the HTML that would show up as a little box. It worked for a while in FM8, Until I started editing.

I had to make a change in the script, and when I saved it, it changed the little box into a regular CR, no box. I couldn't do anything to get it back. 3 hours on this. ;)

For this issue, I have a work around.

WORKAROUND: Open the database in FM7, and copy the text back the way it was, and never touch the script again!

I would like to know how to fix this issue without my work around. Any help on dealing with this? The work around could be toast if I loose my old backups!

THANKS!!

Posted

Not sure I follow what the problem is. It sounds like you were getting rid of the squares by substituting them out. Now after the script edit the squares are no longer there but you want them back?

What are you importing, HTML?

Posted

Thanks for the reply!

Yes, I'm importing HTML. Before I would have the little boxes show up in the text, I would copy them, and use the text I copied in the Substitute script.

Now, when I save the script, filemaker changes the boxes into regular carriage returns, that are not removed in the HTML when processed. I do want the boxes to stay in the Substitute script step, so that they will get removed from the HTML when processed.

Hope that helped!

Posted

Have you looked at the "squares" with a Hex editor to see what character they respresent? Could be Ascii 11 (Vertical Tab). What you can try is to insert a vertical tab in a global; not by copy/paste but by entering it via the keyboard. In your substitute function reference the global instead of a hard-coded "square"

Posted

That's a pretty good idea! I did look at it with a Hex Editor, to see if there was a difference between what I was putting in, and what it was changing it to.

The squares are Hex 20 I don't know what ascii that translates to though.

Thanks for the tip!!

Brian Hightower

Posted

A few observations:

Hex20 is decimal 32 and as an ASCII code is a space. Little boxes in Windows usually means a non-printing code or a font which does not have a character at that code, not likely with code x20. The fact that this comes from an HTML document is not encouraging. Normal HTML allows ISO encoding which is 8-bit as opposed to ASCII 7-bit. So if the high bit were set in your code it would become a non-breaking space, xA0. HTML4 allows the full Unicode character set to enable pages in various languages. At this point the possibilities multiply dramatically as Unicode uses a 2-byte code. Do you use ftp to pick up your HTML pages? Many ftp applications require you to specify the type of file that you are transferring, mine gives the choice of ASCII, binary, EBDIC, none and auto. Maybe there is a mismatch here.

This topic is 6963 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.