473,385 Members | 1,342 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

OLE Automation

3
Trying to automate the embed of word docs. Using the following code which worked for me in Acess 2k but is not working in 2003. Any suggestions?


Private Sub cmd_Insert_DOC_Click()
On Error GoTo errhand2


Dim arbc As String
Dim iss As String

arbc = Me![Arb_Counter].Value
iss = "c:\FILES\Issue" & arbc & ".DOC"

Debug.Print fname

Decision.SourceDoc = fname
Decision.Action = OLe_Create_embed

errhand2:
Debug.Print Err
Resume Next
End Sub
Aug 8 '07 #1
3 1387
JConsulting
603 Expert 512MB
Trying to automate the embed of word docs. Using the following code which worked for me in Acess 2k but is not working in 2003. Any suggestions?


Private Sub cmd_Insert_DOC_Click()
On Error GoTo errhand2


Dim arbc As String
Dim iss As String

arbc = Me![Arb_Counter].Value
iss = "c:\FILES\Issue" & arbc & ".DOC"

Debug.Print fname

Decision.SourceDoc = fname
Decision.Action = OLe_Create_embed

errhand2:
Debug.Print Err
Resume Next
End Sub

Looks like you're missing fname in this code. Where does it get it's value?
You may also want to test arbc for null, but it doesn't appear to matter...you're not doing anything with it as far as your code shows.
J
Aug 21 '07 #2
Scott Price
1,384 Expert 1GB
Is this the same problem that appeared resolved in this earlier post?

http://www.thescripts.com/forum/thre...-decision.html

Regards,
Scott
Aug 21 '07 #3
Scott Price
1,384 Expert 1GB
Comparing the dates/times of the two posts, this appears to be the first of a double posting. The issue was resolved in the other thread.

Regards,
Scott
Aug 21 '07 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

15
by: qwweeeit | last post by:
Hi all, Elliot Temple on the 1 June wrote: > How do I make Python press a button on a webpage? I looked at > urllib, but I only see how to open a URL with that. I searched > google but no...
25
by: Neil Ginsberg | last post by:
I have a strange situation with my Access 2000 database. I have code in the database which has worked fine for years, and now all of a sudden doesn't work fine on one or two of my client's...
1
by: Jimmer | last post by:
I've got what should be an easy automation problem, but the solution simply isn't coming to me. I've got several public variables set up for automation as follows: Public gappExcel As...
1
by: Lee Seung Hoo | last post by:
hi~ :) I need all information of "Automation" or "Automation Object" what is that ? why is it useful ? How can I use that by C# or .Net Framework ?
6
by: a.theil | last post by:
Please help! I need a simple excel automation, just 2 write some files into excel. I do: Dim oXL As Excel.Application Dim oWB As Excel.Workbook Dim oSheet As Excel.Worksheet Dim oRng As...
0
by: Sharath | last post by:
Quality Globe is Glad to Offer you the Fast Track course on Automation, QTP Basics and Advanced, and Quality Center Starting Date: June 4th, 2007 Timings: 10 AM to 3:30 PM Duration: 50 Hours ...
0
by: Sharath | last post by:
"Inspired" by the huge success of our first two automation fast track batches We are forced to start third fast track automation batch ...
0
by: Sharath | last post by:
We are glad to inform you that "Inspired" by the huge success of our first three automation fast track batches We are forced to start fourth fast track automation batch ...
0
by: Sharath | last post by:
We are glad to inform you that "Inspired" by the huge success of our first four automation fast track batches We are forced to start fifth fast track automation batch ...
0
by: madihamir | last post by:
Iam new to .net and have gotten assignment for make the class library to automate the outlook I have tried to done it but i've to make the Handlers also . Detecting an methods for receiving and...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.