PDA

View Full Version : Copying and pasting cells from Excel to a fillable PDF file



pincivma
09-23-2012, 09:12 AM
Hi there

I have downloaded a form from Revenue Canada named gst190-fill-11e.pdf. The PDF form is fillable. To make a long story short, I have recreated the form in Excel 2000 and created an Excel program using VBA that automatically populates the cells. The problem is that Revenue Canada will not accept my Excel form and demands that I use their PDF fillable form. I'm tired of copying and pasting data from my Excel form to their gst190-fill-11e.pdf form, since I have hundreds of these to do. It is very time consuming. I tried to record a macro by copying and pasting from my Excel form onto their form but my macro looks something like this.


Range("A11").Select
Selection.Copy
Range("E11").Select
Application.CutCopyMode = False
Selection.Copy
Range("A16").Select
Application.CutCopyMode = False
Selection.Copy
Range("A18").Select
Application.CutCopyMode = False
Selection.Copy
Range("C18").Select
Application.CutCopyMode = False
Selection.Copy
Range("E18").Select
Application.CutCopyMode = False
Selection.Copy
Application.CutCopyMode = False

In other words, the name of the form did not appear in this recorded macro. Is there a way to create a macro that copies and pastes cells from Excel into a fillable PDF file??

If anyone out there has any idea how to do this, I would greatly appreciate it. If you want to look at the form just google it.

Mario

snb
09-23-2012, 12:11 PM
If you want our help just post the sample PDF-file here.

snb
09-23-2012, 01:17 PM
crosspost:

http://forums.techguy.org/business-applications/1069839-copying-pasting-cells-excel-fillable.html

pincivma
09-23-2012, 03:21 PM
Here is the PDF fillable file. See if you can figure something out.

pincivma
09-24-2012, 09:48 AM
I tried uploading the PDF file but I guess that it did not work. I'll try it one more time. If it does not work you can just google it.

Mario

Kenneth Hobs
09-24-2012, 10:06 AM
If you Adobe Acrobat and not just the Reader, you can use Adobe's DLL routines.

Making and FDF file should be acceptable but you would have to check with them. If that interests you see: http://www.vbaexpress.com/forum/showthread.php?t=43290

Larry Dunn
10-02-2012, 09:33 AM
Well, here it is. My best shot at accomplishing the PDF task. All along, I had the feeling that the initials stood for Pretty Darn Frustrating. It was almost as though the format had been designed to thwart the tinkerer.We can let that go, but I will tell you that if you succeed in filling
out an entire file from Excel, you will be as familiar with that file as you are - or would like to be - with your girlfriend's freckles. A word about SendKeys. I have seen it described as not reliable. That's doesn't seem exactly right. It is reliable in the sense that it appears to give
the same result on the same machine. Going from one station to another, you may find differences. And those differences may require that you redefine certain fields. I wouldn't call this "unreliable," more like "skittish,"cantankerous," and so on. I have lived and breathed this
project for several days now, and have tired of it somewhat. What I have here may become a template for a successful solution. And it, in fact, is a successful solution for a less ambitious task. A form in which you wish to insert a handful of responses may yield to this method
without too much trouble.

I will watch to see if others can make use of this method to achieve real results. My condolences to the originator of this thread. I personally find it objectionable that a person who is ambitious enough to re-create a form in Excel should be severely punished for that, by being forced
to re-input masses of data. I resent the dominance of PDF, particularly in light of its irritating weaknesses. Instructions on the Send sheet, you must provide the data path and file name at the top. On the Data sheet, you must create multiple columns of data to go into the form.
Each column will contain all appropriate data for a single client or household. The Next Client button will bring in the data to be sent for the next client in the list. Open File will open the PDF file. You need to wait till the form is stabilized, which sometimes takes quite some time.

If a message comes up, you must of course clear it before sending data. Data transmission will stop when the program comes to a SKIP. You must then enter data manually in the fields that were resistant to input from outside. Then position the cursor in the form in the next cell to be filled,
and press the Continue button. When the form is complete, do any cleanup that may be necessary, sign it, mail it, print it, or whatever your task requires. Then close it and prepare for the next client. If you save the filled-in file, you must change the file name or folder, so you do not overwrite
the original.

Larry Dunn
10-02-2012, 10:52 AM
Why have all my nice paragraphs been turned to garbage?

The content may have been garbage, but the form was nicer!