Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Microsoft Office > Access and Access VBA > Access
Password Reminder
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
Access Discussion of Microsoft Access database design and programming. See also the forums for Access ASP and Access VBA.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Access section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old April 4th, 2005, 09:23 AM
Registered User
Join Date: Apr 2005
Location: , , .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Import Data from a form to a word package


I am trying to import an address from a customer details form to an invoice in word, but it seems to not work. I have below shown two different types of codes that I have tried to use, but they both do not seem to work.

Can you please help!


Dim frmCustomerDetails As Form
    Set frmCustomerDetails = Screen.ActiveForm

    oApp.Selection.GoTo Name:="Address"

    Dim txtContact As Control
    Set txtContact = Forms!frmCustomerDetails![CustomerID]
    txtContact.Value = [Address1]

    TextToWrite = " " & frmCustomerDetails.Table![Address1]
    TextToWrite = TextToWrite
    If Replace(TextToWrite, " ", "") <> "" Then oApp.Selection.TypeText Text:=TextToWrite & ""

Reply With Quote

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
package and import problem Prince Java Basics 0 May 29th, 2006 06:49 AM
How to import word file in Data report in vb Subuana Beginning VB 6 0 April 3rd, 2006 06:20 AM
CH7 - import package kizmit JSP Basics 4 June 16th, 2004 08:00 AM
import data from web form Mitch Access VBA 8 September 4th, 2003 04:26 PM

All times are GMT -4. The time now is 07:45 AM.

Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.