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
Solved

Import email text into sql

Posted on 2011-02-15
1
691 Views
Last Modified: 2012-08-13
Hi experts,
    currently i have macro written in my outlook 2007 that will read the current opening email and formatting then export into an excel file. what i want to do next is besides exporting the information in excel, also insert the same information into sql database.
 
Set strConnection = CreateObject("ADODB.Connection")
strConnection.Open ("Provider=SQLOLEDB;DataSource=internal;Database=Vision;Trusted_Connection=Yes;")
Set rsRecord = CreateObject("ADODB.Recordset")
    rsRecord.Open = "Select * from ReportList"
      rsRecord.Addnew
      rsRecord("ReportHeading") = "PriceList - " & strContact
      rsRecord("EmailName") = strContact
      rsRecord("Email") = strEmail
      rsRecord("Frequency") = strFrequency
      rsRecord("Format") = strType
      rsRecord("OffsetDay") = 0
      rsRecord("SendBlank") = False
      rsRecord("ReportType") = "Pricelist"
      rsRecord("CustomerName") = strCustomerNo

Open in new window


i had these codes, but it went broken at '.Open', so i guess my syntax must went wrong here, anyone could help with this?
0
Comment
Question by:miketonny
1 Comment
 
LVL 16

Accepted Solution

by:
Kalpesh Chhatrala earned 500 total points
ID: 34903476
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

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

This process describes the steps required to Import and Export data from and to .pst files using Exchange 2010. We can use these steps to export data from a user to a .pst file, import data back to the same or a different user, or even import data t…
With User Account Control (UAC) enabled in Windows 7, one needs to open an elevated Command Prompt in order to run scripts under administrative privileges. Although the elevated Command Prompt accomplishes the task, the question How to run as script…
To add imagery to an HTML email signature, you have two options available to you. You can either add a logo/image by embedding it directly into the signature or hosting it externally and linking to it. The vast majority of email clients display l…
CodeTwo Sync for iCloud (http://www.codetwo.com/sync-for-icloud?sts=6554) automatically synchronizes your Outlook 2016, 2013, 2010 or 2007 folders with iCloud folders available via iCloud Control Panel. This lets you automatically sync them with…

837 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