« Older Entries Newer Entries » Subscribe to Latest Posts

17 Jan 2013

New Posts Over at my Business Site

Posted by khk. No Comments

Many of you come to this site because of the Adobe Acrobat and PDF related posts. I’ve moved all that to my business site at http://www.khkonsulting.com a while ago, but Google still likes to point searchers here. If you are not keeping up with what’s going on over there, here is some information about my recent posts:

Validating Field Content

A tutorial to validate field content with custom JavaScript validation scripts. 

The Trouble With the XREF Table

Information about how a corrupt XREF table will mess up a PDF file and how to debug XREF table problems. 

The End is Here – of ADM that is

Adobe has ended support for ADM (the Adobe Dialog Manager)  in Acrobat plug-ins. I’ve warned about this before, but now it actually happened. 

17 Mar 2012

Easter Lambs – The Sweet Kind

Posted by khk. 1 Comment

It’s almost Easter, so it’s time to locate my lamb recipe again… I have the same problem every year, so from know on, I’ll just look on my blog for the recipe 🙂
Baking easter lambs is a tradition I brought from Germany to the US. Every year for Easter, I use my mold to make a couple or three lambs – a little herd of sheep, white and sometimes black.
Here is the recipe:
125g (4 1/2 oz) shortening
125g (4 1/2 oz) sugar
1 pkg vanilla suger or 1 tsp vanilla extrace
1 pinch Salt
2-3 eggs
100g (3 1/2 oz) whole wheat pastry flour
Preheat the oven to 350F.
Cream the sugar with the shortening for at least five minutes. Add the vanilla, salt and one egg at a time. If you have smallish eggs, use three, otherwise two. When the eggs are incorporated, slowly add the flour. Cover the mold with backing spray and flour – especially the areas with small details like the ears. Fill the batter into the mold and tap it a few times to get any air bubbles out.
Bake for about 40 minutes – check with a skewer to see if it’s baked all the way through.

Easter Lambs


25 Sep 2011

Worldwide Photo Walk 2011

Posted by khk. No Comments

It’s Worldwide Photo Walk time again – this time it’s not just one day, it’s a weekend of photo walks.


Just in case it’s not clear what I’m talking about, here is a short explanation. For the forth time Scott Kelby has organized a worldwide event: Groups of photographers will gather on the weekend of October 1st and 2nd and take pictures for about two hours. It is very interesting to experience how (up to) 50 people basically looking at the same “things” interpret what they see completely differently.


I’m leading the Rochester, NY walk at High Falls this year (after leading a downtown walk in Rochester two years ago, and a walk in Memmingen, Germany last year).


If you are interested in photography, are in Rochester, NY and have some time, join us for this years Worldwide Photo Walk.


You can find pictures from previous walks on Flickr: Rochester and Memmingen.

Rusty Leaf

Photographer's Breakfast

18 Oct 2010

The X Files: Acrobat Edition

Posted by khk. Comments Off on The X Files: Acrobat Edition

[This blog post appeared first on my professional site at KHKonsulting.com – Please head over there if you want to comment or see any potential comments to this article]

A New Version of Acrobat

Have you noticed that it’s been more than two years since the release of Adobe Acrobat 9? Usually, Adobe releases a new version every 18 to 24 months, so a new version has been overdue. Today they let the cat out of the bag, and announced Acrobat X. There is already a lot of information available about what it is, and to some extend also how it is different from previous releases.

Take a look at the press release to get a quick overview of what’s new, or browse over two Adobe TV and watch the Acrobat X Tips & Tricks episodes. There is a lot of information available to give you a pretty good idea about what’s new and different.

User Interface

If you’ve attended one of my training seminars about Acrobat, you know that one of my pet peeves has always been that Adobe added to the UI clutter with every new release of Acrobat. Yes, every now and then they tried to clean it up, but at the end, it just caused more and more confusion among both novice, but also experienced users.

This time around, they took a completely new approach and ripped out the old menu and toolbar system and replaced it with something completely new. I am still trying to wrap my head around where things are now located, but in general, the new layout is a good idea. It will be much easier for the novice user to explore the UI and find new features that they might want to use, but for users who’ve worked with Acrobat since the early days of the product (in my case since Acrobat 3), it will take a while until we find all the tools that we’ve known by heart. But in the long run, I think it’s a good move, and I am more than willing to go through the learning process to get to know the new UI.


Every time Acrobat changed it’s UI in the past, there were major ripple effects through the plug-in community – things just did not work anymore, or not quite right, and we plug-in developers had some work to do to modify our plug-ins so that users could rely on these 3rd party components again.

If you have not yet tested your own plug-ins on an Acrobat X pre-release, don’t waste any time. Chances are that your code needs to be modified to work seamlessly with Acrobat X. If you need help with that, get in touch with me, I am a seasoned plug-in developer and I can certainly assist you with those efforts.

Favorite Feature

I don’t have a favorite new feature, but I have two favorite updated features:

Number one is what Adobe has done with Portfolios. In my opinion, Portfolios were one of the most underused features in Acrobat 9, and I hope that the updates to the Portfolio system will help to give that feature the necessary exposure so that we see more and more of these compound documents.

My number two updated feature is the much improved export function to other file formats. Whenever I had to create a MS Word document out of a PDF file in the past, it was always a hit-or-miss job – some documents worked reasonably well, others didn’t work at all. But regardless of how well it worked, there was always some editing necessary after the export to make the Word file look like the original PDF document. With the new export in Acrobat X, I get Word documents that look exactly like the PDF file. Great job, Adobe!

23 Sep 2010

Reading PDF Form Fields with VBA

Posted by khk. 26 Comments


Please visit the same post on my business site. The comments are closed here, so if you want to comment, you have to head over to http://khkonsulting.com/2010/09/reading-pdf-form-fields-with-vba/

I’ve written about VBA and Acrobat JavaScript before, and I’ve also mentioned that you can combine VBA and JavaScript to access PDF form fields, but I still owe a sample for that. I had to answer another question today about how to exactly do that, so I whipped up a quick sample program that demonstrates the use of the JavaScript Object (JSO) to read and write AcroForm fields.

We start the same way as in my old VBA sample to create a VBA program that references the Acrobat TLB and to add a button to a document. When we now use the following script as the button handler, we can work with form fields:

Private Sub CommandButton1_Click()
    Dim AcroApp As Acrobat.CAcroApp
    Dim theForm As Acrobat.CAcroPDDoc
    Dim jso As Object
    Dim text1, text2 As String

    Set AcroApp = CreateObject("AcroExch.App")
    Set theForm = CreateObject("AcroExch.PDDoc")
    theForm.Open ("C:\temp\sampleForm.pdf")
    Set jso = theForm.GetJSObject

    ' get the information from the form fields Text1 and Text2
    text1 = jso.getField("Text1").Value
    text2 = jso.getField("Text2").Value

    MsgBox "Values read from PDF: " & text1 & " " & text2

    ' set a text field
    Dim field2 As Object
    Set field2 = jso.getField("Text2")

    field2.Value = 13   ' assign the number 13 to the fields value

    ' get the information from the form fields Text1 and Text2
    text1 = jso.getField("Text1").Value
    text2 = jso.getField("Text2").Value

    MsgBox "Values read from PDF: " & text1 & " " & text2


    Set AcroApp = Nothing
    Set theForm = Nothing

    MsgBox "Done"
End Sub

This program requires a PDF file with text fields called “Text1” and “Text2” to be stored as C:\temp\sampleForm.pdf. With the explanation in the previous two blog posts, it should not be hard to understand what’s going on here. The only new command introduced is the getField() function, which returns a form field. The form field object has a property “value” which contains the actual value that’s assigned to the field. Give it a try and let me know how it works for you. The updated form field is not saved (because the document does not get saved) – I’ll leave that up to the reader to figure out.

Also, this program will not work with XFA forms (the ones you create in Designer). For those, you need to use the XFA DOM to access the form data. For anybody interested in XFA forms, the LifeCycle Designer ES Scripting Reference is a must read.

18 Aug 2010

Multiple Flickr Publishing Services in Lightroom 3

Posted by khk. No Comments

One day you need your Flickr uploads resized to 1000×1000 pixels, the next day you need to allow only friends and family access to your uploads – is there a way to make the Flickr upload more streamlined from within Lightroom?

Since the release of Lightroom 3 there is a convenient Flickr publishing service built right into the application, and with a few mouse-clicks users can upload any selection of images stored in the Lightroom catalog.

Thanks to the foresight of the designers of the application (or the beta testers), it is possible to set up multiple Flickr publishing services with different settings. In the following tutorial I will demonstrate how that is done. At first we’ll look at the long and complicated (no, not really) method – which you need to create your initial Flickr publishing service, but can also be used for the second, third and so on service. Then we’ll use a shortcut to create the “other” publishing services.

It does not matter if you’ve already set up one Flickr publishing service, or if you are starting from scratch, the process is the same. When you look at the left panel in Lightroom, you will see the “Publish Services” category with a little “+” sign to the right of the category title – plus a small triangle that indicates that there is a menu hidden behind the plug sign.


Once you click on that plus sign, the menu will be displayed. Select the “Go to Publishing Manager…” menu item, which will display the …


… “Lightroom Publishing Manager” dialog.


Right below the list of “Publish Services” on the left side is the “Add” button to add new services to the list. Click on that and specify the details for the new service.


That’s it. Now just drag&drop your images on one of the Flickr publishing services, and once you are done, select to actually publish the images by right-clicking on the Photostream (or your custom photo set) and select to “Publish Now”:


So, now that we know the long way, here is a shortcut: Once you have your first Flickr publishing service installed, just right-click on that publishing service and select “Create Another Publish Service via ‘Flickr'”:


After that, just follow the instructions above to setup the service.

18 Aug 2010

Best Way to Learn Acrobat Scripting

Posted by khk. Comments Off on Best Way to Learn Acrobat Scripting


Please visit the same post on my business site. The comments are closed here, so if you want to comment, you have to head over to http://khkonsulting.com/2010/08/best-way-to-learn-acrobat-scripting/

Every now and then I come across the question “What is the best way to learn scripting for Adobe Acrobat? Are there any books or other resources averrable?”. After doing some research, I think I finally found the best resource for beginners and for seasoned Acrobat JavaScript programmers that need a quick tip or a recipe to copy&paste into a project:


The site offers content for both paying members and the general public. If you are new to scripting, and you don’t want to spend the money for a membership (yet), take a look at the free content at http://www.pdfscripting.com/public/department40.cfm – it walks you through creating your first AcroForm script, but also offers a number of videos that explain more complicated concepts. For the really good stuff however, you have to pay.

Ever wondered how to hook up a PDF form with an Excel spread sheet? Wonder no more! The article series “Acrobat, PDF and Excel Spreadsheets” teaches you more than you ever wanted to know about that subject.

You may remember my post about dynamic stamps in Acrobat. The PDFScripting.com site has a lot more information about dynamic forms and provides a number of very interesting samples (video link).

There is a ton more information available for both AcroForm and LiveCycle Designer scripting. This information comes in form of articles, videos, a copy&paste script library and downloadable sample files that illustrate a subject.

To get familiar with the web site, Thom Parker has recorded a video tour that helps to navigate the site, but also gives a pretty good overview about what’s available both for free and for paying members at “Take a tour of the PDFScripting.com website!” (video link).

So, no need to ask me for a good Acrobat scripting resource anymore, just go to PDFScripting.com and sign up for a year – it’s well worth the membership fee (and as Thom says in his tour video, no surprise at the end of the year, the membership does not automatically renew).

7 Jun 2010


Posted by khk. 1 Comment


17 May 2010

The Small Show Is Back!

Posted by khk. Comments Off on The Small Show Is Back!

It’s this time of the year again: The Small show at the High Falls Art Gallery in Rochester, NY Is about to open. Join the artists for the public reception on Sunday, May 23rd from 3 to 6pm.


Here is a link to the PDF version of the invitation.

If you don’t want to download the PDF invitation, here is the important information from the document:

High Falls Art Gallery

Small Works of art no larger than twelve inches

Public Reception Sunday May 23, 2010 3-6pm

Music by Reilly Taylor-Cook and Hershel Mikel Jazz Duo 

7 May 2010

LinkedIn Pet Peeve

Posted by khk. Comments Off on LinkedIn Pet Peeve

Do you let LinkedIn post your tweets automatically as your LinkedIn updates? Here is a reason why that might be a bad idea: If you tweet too much, I may just hide your status updates in LinkedIn completely – not just your tweets, all your status updates!


In my opinion, when LinkedIn tried to get on the Twitter band wagon, they made a big mistake: When you connect a Twitter account to a LinkedIn account, you have a choice of either automatically posting every tweet to your LinkedIn status, or just the ones that are tagged with the #in or #li hash tag:


For the latter case, a Twitter user who tweets something that might be appropriate for LinkedIn can tag the tweet with #in and have it show up on LinkedIn automatically. That’s not a bad idea, and I’m fine with that. It gives the user control over what gets shared, and what not. Twitter and LinkedIn (or in general, all the social media platforms one uses) serve a different purpose, and in general it’s not a good idea to post the same message to all these platforms -but sometimes, there is something that should be shared across all services. The hash tag approach gives the user that control.

The “annoy all my LinkedIn connections with my most trivial Twitter drivel” option however really annoys me. One of the most attractive features of Twitter is that tweets have a limited life time. When they don’t show up in the small window of the Twitter timeline that I’m looking at, they don’t exist – unless I’m using search. I don’t have to read them, I don’t have to deal with them, I can safely ignore them. And I do! When they show up in my LinkedIn status updates however, I can no longer ignore them, and even more annoyingly, they push real status updates off the end of that page.

I wish LinkedIn would give me an option to hide all Tweets (or at least those that don’t have #in or #li in them). Because I don’t have that control, I do the next best thing: If your tweets on LinkedIn annoy me, I will hide your status updates.