Register

Exporting slide text

Questions regarding the authoring of Viewlets, installation or possible bugs with our products. For urgent issues, please use our support form on our website: http://www.qarbon.com/help/helpme.php
User
Posts: 2
Joined: Thu Mar 19, 2009 4:26 am

Exporting slide text

Postby elygreen » Thu Mar 19, 2009 4:29 am

Hello, trying to make an accessible version of my viewlets - both for people with disabilities and for small printing needs.

I'd like to export the text bubbles on my slides to plain text or something so that I can then offer it as an alternative version.

I can only see to do this via XML export - but then I have all the XML code that I don't want to deal with.

Any tips on just getting the actual content?

Thanks,

Ely

Site Admin
Posts: 1084
Joined: Fri May 26, 2006 3:15 pm
Location: San Jose, CA

Re: Exporting slide text

Postby James » Thu Mar 19, 2009 7:43 am

Ely,

You can print your slides and have it include the text bubbles.

The feature you referenced is for translation to other lanuages so the format need to be strict
for easy importation back into the application to replace all the text.

James

User
Posts: 2
Joined: Thu Mar 19, 2009 4:26 am

Re: Exporting slide text

Postby elygreen » Thu Mar 19, 2009 6:10 pm

Hi James, thanks but I don't just want to print it, I want to also offer it online as an alternative help - people won't want to print the entire slide show, just the steps (all of which are in the text bubbles).

So no other way to do it?

Michelle

Site Admin
Posts: 1084
Joined: Fri May 26, 2006 3:15 pm
Location: San Jose, CA

Re: Exporting slide text

Postby James » Thu Mar 19, 2009 6:18 pm

Michelle,

We used to export to HTML which is better for viewing but wasn't as good as XML for importing back in for
text translation. We talked about bringing that feature back....your application sounds like a good use for it.

I will look into it.

James

Site Admin
User avatar
Posts: 223
Joined: Fri May 26, 2006 1:51 pm
Location: Rochester, NY

Re: Exporting slide text

Postby Andrew » Fri Mar 20, 2009 8:13 am

Right now export to XML is your best option. This is plain text and contains what you're looking for, but also has a lot of additional markup. You could edit the text down manually in notepad, or since XML works great with macro and scripting languages, you could may be able to find a tech head to write a quick script to take care of the manual work for you.

We've had a couple of requests for this recently, so I've also added a feature request to our issue tracking system to allow more flexibility to the export formats.

Case 33846 - More flexibility on Export Text for Translations XML, HTML
Andrew Branch

User
Posts: 5
Joined: Fri Mar 07, 2008 12:51 pm
Location: Eau Claire, WI

Re: Exporting slide text

Postby Al White » Mon May 18, 2009 1:26 pm

What I do to see the text might help you, too.

I export the text to XML for translating, then in Microsoft Word XP (2002) I run this macro. It's got the file name and location hard-coded; you'll have to tailor it for your environment. You will also need to add a reference to MSXML 6.0 to the References part of VBA.

This puts slide numbers at the beginning of the line. I use it to allow Word's grammar checker to find some things that the spelling checker in VB won't catch. Nothing to re-import the info; I alt-tab a lot.

Good luck.

Al

Sub vbcheck()
Dim objD As MSXML2.DOMDocument60
Dim Nod As MSXML2.IXMLDOMNode
Dim A() As String
Dim T As String
Dim N, M As Integer
Set objD = New MSXML2.DOMDocument60
If objD.Load("C:\Documents and Settings\Administrator\Desktop\text.xml") Then
For N = 0 To objD.childNodes.Item(1).childNodes.Length - 1
Set Nod = objD.childNodes.Item(1).childNodes.Item(N)
If Nod.childNodes.Length > 0 Then
A = Split(Nod.Text, ">")
T = ""
For M = 0 To UBound(A)
If InStr(1, A(M), "<") > 1 Then
T = T + " " + Left(A(M), InStr(1, A(M), "<") - 1)
End If
Next M
ActiveDocument.Words.Last.InsertAfter (Nod.Attributes(1).Text + " -" + T + vbCrLf)
End If
Next N
With ActiveDocument.Content.Find ' get rid of double spaces
.Text = " "
.Replacement.Text = " "
.Replacement.ClearFormatting
.Execute Replace:=wdReplaceAll, Forward:=True
' and now the other common thing
.Text = "&Quot;"
.Replacement.Text = ""
.Execute Replace:=wdReplaceAll, Forward:=True
End With
Else
MsgBox "C:\Documents and Settings\Administrator\Desktop\text.xml was not loaded", vbOKOnly, "Oops"
End If
End Sub

Site Admin
User avatar
Posts: 223
Joined: Fri May 26, 2006 1:51 pm
Location: Rochester, NY

Re: Exporting slide text

Postby Andrew » Mon May 18, 2009 3:45 pm

Thanks Al!
Andrew Branch

User
Posts: 5
Joined: Fri Mar 07, 2008 12:51 pm
Location: Eau Claire, WI

Re: Exporting slide text

Postby Al White » Mon Dec 05, 2011 1:59 pm

Changes in the exported XML for VB 7 required a few modifications to that code. I was getting a parse error because MSXML does not habitually load external DTD information.

The XML for V6 has two child nodes at the top level; for VB7, it has three. (one of them being the reference to the DTD)

So if you change this code:
If objD.Load("C:\Documents and Settings\Administrator\Desktop\text.xml") Then
For N = 0 To objD.childNodes.Item(1).childNodes.Length - 1
Set Nod = objD.childNodes.Item(1).childNodes.Item(N)

to this:
objD.resolveExternals = True
objD.setProperty "ProhibitDTD", False

If objD.Load("C:\Documents and Settings\Administrator\Desktop\text.xml") Then
For N = 0 To objD.childNodes.Item(objD.ChildNodes.Length - 1).childNodes.Length - 1
Set Nod = objD.childNodes.Item(objD.ChildNodes.Length - 1).childNodes.Item(N)

Then the remaining code will parse for both VB6 and VB7 formats.

Return to General Discussions

Who is online

Users browsing this forum: No registered users and 1 guest