Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

XML import of chemical formula

Featured Replies

  • Newbies

All I want to be able to do is to import/export simple chemical formula - which involves the use of super/subscripts. Filemaker appears to not be in the mood to play nice.

If I take a set of test formula and export using the xml option, all super/subscript information is lost.

Then again, I already have a field where the formula are formatted using HTML (useful when generating web pages). I can export them, convert the &lt; and &gt; to < and > so that the tags are proper but FM refuses to import them - it knows nothing about <sub> or <sup> from what I can tell.

Clearly, it should be possible to import/export formatted text but I've yet to find it - even after the purchase of a couple of books that claim to be helpful.

Any suggestions would be appreciated.

For exporting,

  • Author
  • Newbies

Thanks. I'll give them a try. What about importing html formatted text?

I have an example on my website:

http://www.spf-15.com/

"Style Manipulation Example" that takes CSS text back to formatted text with several custom functions, but I see you don't have Dev7, so that probably won't be very helpful.

I've attached a simple example showing this working with custom functions, (subscripter() and superscripter() ) - as well as a script that subscripts / superscripts a piece of text (in scriptText) when you hit the "Format Text" button (with no custom functions needed).

  • Author
  • Newbies

Again, thanks.

  • Author
  • Newbies

Just gave it a try and it is perfect. Thank you.

  • 2 weeks later...

Time has passed on this thread, but I'll follow up here anyway: Can we GetAsCSS so that multiple records' styled data get consolidated into one page?

I'm able to GetAsCSS(citation) and generate an html/css file out of that citation field, which then can display in a web browser, from which system clipboard will copy so as to transfer into word processing with styles intact. (what a runaround!) This works for one record at a time, and <body> tags can be built in...

Suppose I have 20 citations in found set (the citation field from each of 20 biblio records), each with intermittent italics. Suppose I have a global field where I store what should be the header INFO ("Biblio for XYZ"). Can I get something to export a css/html file that has the header info from the global, just one set of <body> tags at header and footer, and the data from the records neatly stacked into html paragraphs in the same body?

That would be much more convenient that doing an export, then having to open the resulting file and add <body> and </body> tags, title info, etc., before opening in browser.

(I tried using an option-copy from a layout with just the GetAsCSS(text) field, but the resulting clipboard string "breaks" the quiet carriage returns that mark style transitions (the ones intended for code clarity in web design) and turns them into box-characters. (Copying an individual record's field does not result in this problem: I paste into Dreamweaver and the CSS code looks nice, doesn't confuse the line breaks in code for end-result characters.))

You already have the header in a global field. Now loop through your records and append each one to the global, then append the footer. Now isolate a single record and export that one field.

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.