Solved

How to import XML data from Memo field or String expression into Access.

Posted on 2006-11-29
3
223 Views
Last Modified: 2011-10-03
How do I  transform XML data from a memo field (or string expression) to corresponding fields in my access table?

Sample XML Data from memo field:

<?xml version="1.0" encoding="utf-16"?>
<AddressBook>
   <Address>
      <ID>-1</ID>
      <FirstName>Jim</FirstName>
      <LastName>Anderson</LastName>
      <CompanyName>Acme Corp</CompanyName>
      <StreeLine1>123 1st Ave</StreeLine1>
      <StreetLine2>suite 100</StreetLine2>
      <City>Edina</City>
      <StateName>Minnesota</StateName>
   </Address>
</AddressBook>

0
Comment
Question by:caramelcooker
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 44

Accepted Solution

by:
Leigh Purvis earned 125 total points
ID: 18036634
You could save the text in your field as a file - and use the inbuilt import method to grab the data.
(If in Access 2002/2003/2007).

Or you could load the text in code and use the MSXML object library to do it the more controlled way.
A pretty generic example of which is here
http://www.experts-exchange.com/Q_21990088.html
0
 
LVL 44

Expert Comment

by:Leigh Purvis
ID: 18040078
Need anything further or is that enough to be going on with?

Want an example of the first method - or have you gone with door number 2? :-)
0
 

Author Comment

by:caramelcooker
ID: 18040193
2nd option is the cleanest.  

I will build a table with the field names necessary and enumerate through their names having the results go to the sample code at the link you provided which will ultimately end up as the data for those fields.  MSXML6.0 it is!  Thank You for a timely response.
0

Featured Post

U.S. Department of Agriculture and Acronis Access

With the new era of mobile computing, smartphones and tablets, wireless communications and cloud services, the USDA sought to take advantage of a mobilized workforce and the blurring lines between personal and corporate computing resources.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

In a multiple monitor setup, if you don't want to use AutoCenter to position your popup forms, you have a problem: where will they appear?  Sometimes you may have an additional problem: where the devil did they go?  If you last had a popup form open…
This article describes a method of delivering Word templates for use in merging Access data to Word documents, that requires no computer knowledge on the part of the recipient -- the templates are saved in table fields, and are extracted and install…
Familiarize people with the process of utilizing SQL Server functions from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Ac…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

740 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question