[AccessD] What is this?

rusty.hammond at cpiqpc.com rusty.hammond at cpiqpc.com
Tue Jun 23 09:28:45 CDT 2009


John,

DDE has been around for years and as far as I know, isn't used much anymore.
Notice at the bottom of the article, it applies to VB 4.0 and VB 3.0 and is
listed as Retired KB content, and the last review of the article was in
January 2003.

Rusty 

-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of jwcolby
Sent: Tuesday, June 23, 2009 9:15 AM
To: Access Developers discussion and problem solving
Subject: [AccessD] What is this?

I just found code that does the TransferText in a completely different way.
I have never seen a text control use these properties and methods.  Is this
something new in 2007 or does this go back to some previous version?  What
is the advantage of this over the normal TransferText?

http://support.microsoft.com/kb/113905

    Sub Command1_Click ()
       Dim cmd As String      ' Holds DDEExecute command.
       On Error GoTo DDEerr   ' Error trap.

       ' Make sure there isn't an existing DDE conversation:
       text1.LinkMode = 0

       ' Set up the DDE link:
       text1.LinkTopic = "MSACCESS|C:\ACCESS\NWIND.MDB"
       text1.LinkItem = "All"
       text1.LinkMode = 2

       ' DDEExecute command to import text file into Microsoft Access Table:
       cmd = "[TransferText ,,'Shippers','C:\ACCESS\SHIPPERS.TXT']"

       ' Execute the TransferText command and close the DDE link:
       text1.LinkExecute cmd
       text1.LinkMode = 0
       MsgBox "Transfer OK"
       Exit Sub

    DDEerr:
       ' An error has occurred.
       MsgBox Error
       MsgBox "Error in transfer."
       Exit Sub
    End Sub


--
John W. Colby
www.ColbyConsulting.com
--
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com

**********************************************************************
WARNING: All e-mail sent to and from this address will be received,
scanned or otherwise recorded by the CPI Qualified Plan Consultants, Inc.
corporate e-mail system and is subject to archival, monitoring or review 
by, and/or disclosure to, someone other than the recipient.
**********************************************************************



More information about the AccessD mailing list