<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Error when i import doc file into sas.. in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Error-when-i-import-doc-file-into-sas/m-p/89148#M18946</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks &lt;A __default_attr="63295" __jive_macro_name="user" class="jive_macro jive_macro_user" data-objecttype="3" href="https://communities.sas.com/"&gt;&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 25 Sep 2013 10:04:43 GMT</pubDate>
    <dc:creator>yaswanthj</dc:creator>
    <dc:date>2013-09-25T10:04:43Z</dc:date>
    <item>
      <title>Error when i import doc file into sas..</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Error-when-i-import-doc-file-into-sas/m-p/89146#M18944</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a word doc file(.doc) in my PC. i want to get that file into sas. this should be automated using macro.. i have below problem to get the file .DOC file to generate the datset in sas automatically. but im getting an issue while generating the .doc file to sas dataset..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;in the below program everything is good, but while generating the dataset from .xls it is giving an error like ;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ERROR: Connect: External table is not in the expected format.&lt;/P&gt;&lt;P&gt;ERROR: Error in the LIBNAME statement.&lt;/P&gt;&lt;P&gt;Connection Failed.&amp;nbsp; See log for details.&lt;/P&gt;&lt;P&gt;NOTE: The SAS System stopped processing this step because of errors.&lt;/P&gt;&lt;P&gt;NOTE: PROCEDURE IMPORT used (Total process time):&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; real time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2.29 seconds&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; cpu time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1.04 seconds&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Im using SAS V9.1 and windows environment..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; my code..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="color: navy; background: white; font-size: 12.0pt; font-family: Consolas;"&gt;%macro&lt;/STRONG&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt; word2sas(in=, out=temp);&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;options noxwait noxsync;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: blue; background: white;"&gt;%let&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt; rc=&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: blue; background: white;"&gt;%sysfunc&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;(system(start winword));&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;data test;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; x=sleep(&lt;/SPAN&gt;&lt;STRONG style="color: teal; background: white; font-size: 12.0pt; font-family: Consolas;"&gt;3&lt;/STRONG&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;);&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp; run;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;filename word DDE &lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: purple; background: white;"&gt;'winword|System'&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;data _null_;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;file word;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;put &lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: purple; background: white;"&gt;'[FileOpen.Name = "'&lt;/SPAN&gt; &lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: purple; background: white;"&gt;"C:\Documents and Settings\yaswanth.j\Desktop\test\example2.doc"&lt;/SPAN&gt; &lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: purple; background: white;"&gt;'"]'&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;put &lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: purple; background: white;"&gt;"[EditSelectAll]"&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;put &lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: purple; background: white;"&gt;"[EditCopy]"&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;put &lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: purple; background: white;"&gt;'[FileClose]'&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;put &lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: purple; background: white;"&gt;'[AppMinimize]'&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;run;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: blue; background: white;"&gt;%let&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt; rc=&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: blue; background: white;"&gt;%sysfunc&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;(system(start excel));&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;data test;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; x=sleep(&lt;/SPAN&gt;&lt;STRONG style="color: teal; background: white; font-size: 12.0pt; font-family: Consolas;"&gt;3&lt;/STRONG&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;);&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;&amp;nbsp;&amp;nbsp; run;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;filename excel dde &lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: purple; background: white;"&gt;'excel|system'&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;data _null_;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;file excel;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;put &lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: purple; background: white;"&gt;'[error(false)]'&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;put &lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: purple; background: white;"&gt;'[paste]'&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;put &lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: purple; background: white;"&gt;'[SAVE.AS("C:\Documents and Settings\yaswanth.j\Desktop\test\Example2.xls")]'&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;put &lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: purple; background: white;"&gt;'[Select.Last.Cell()]'&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;put &lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: purple; background: white;"&gt;'[Copy]'&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;put &lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: purple; background: white;"&gt;'[quit]'&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;run;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;proc import out=temp datafile= &lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: purple; background: white;"&gt;"C:\Documents and Settings\yaswanth.j\Desktop\test\Example2.xls"&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt; DBMS=excel replace;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;getnames=yes;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;mixed=yes;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;run;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;filename fd &lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: purple; background: white;"&gt;"C:\Documents and Settings\yaswanth.j\Desktop\test\Example2.xls"&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: blue; background: white;"&gt;%let&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt; rc=&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: blue; background: white;"&gt;%sysfunc&lt;/SPAN&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;(fdelete(fd));&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;filename _all_ clear;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="color: navy; background: white; font-size: 12.0pt; font-family: Consolas;"&gt;%mend&lt;/STRONG&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt; word2sas;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt;%&lt;STRONG&gt;&lt;EM&gt;word2sas&lt;/EM&gt;&lt;/STRONG&gt;(in = C:\Documents and Settings\yaswanth.j\Desktop\test\example2.doc, out=temp);&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 12.0pt; font-family: Consolas; color: black; background: white;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Please help me where can i change the code.. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Yash..&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 Sep 2013 11:25:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Error-when-i-import-doc-file-into-sas/m-p/89146#M18944</guid>
      <dc:creator>yaswanthj</dc:creator>
      <dc:date>2013-09-20T11:25:02Z</dc:date>
    </item>
    <item>
      <title>Re: Error when i import doc file into sas..</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Error-when-i-import-doc-file-into-sas/m-p/89147#M18945</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi:&lt;/P&gt;&lt;P&gt;&amp;nbsp; Are you referencing the %WORD2SAS macro program that was described in this 2009 paper? &lt;A href="http://www.pharmasug.org/download/papers/CC18.pdf" title="http://www.pharmasug.org/download/papers/CC18.pdf"&gt;http://www.pharmasug.org/download/papers/CC18.pdf&lt;/A&gt; If so, perhaps the paper author could help you. I believe there is contact information at the end of the paper.&lt;/P&gt;&lt;P&gt;cynthia&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 21 Sep 2013 01:24:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Error-when-i-import-doc-file-into-sas/m-p/89147#M18945</guid>
      <dc:creator>Cynthia_sas</dc:creator>
      <dc:date>2013-09-21T01:24:40Z</dc:date>
    </item>
    <item>
      <title>Re: Error when i import doc file into sas..</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Error-when-i-import-doc-file-into-sas/m-p/89148#M18946</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks &lt;A __default_attr="63295" __jive_macro_name="user" class="jive_macro jive_macro_user" data-objecttype="3" href="https://communities.sas.com/"&gt;&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Sep 2013 10:04:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Error-when-i-import-doc-file-into-sas/m-p/89148#M18946</guid>
      <dc:creator>yaswanthj</dc:creator>
      <dc:date>2013-09-25T10:04:43Z</dc:date>
    </item>
    <item>
      <title>Re: Error when i import doc file into sas..</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Error-when-i-import-doc-file-into-sas/m-p/89149#M18947</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="color: #333333;"&gt;Hi, Yash.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333;"&gt;I wonder have you ever found your way out? Whether you have used some &lt;A href="http://www.yiigo.com/guides/vbnet/how-to-process-word.shtml"&gt;&lt;SPAN style="color: #333333;"&gt;Word Doc SDK&lt;/SPAN&gt;&lt;/A&gt; to help you with the related projects? Even though I am not so sure about whether it is the best way to slove your problem, I hope you can google it and select a fine &lt;A href="http://www.yiigo.com/guides/vbnet/how-to-start-word.shtml"&gt;&lt;SPAN style="color: #333333;"&gt;Word Doc Toolkit&lt;/SPAN&gt;&lt;/A&gt; whose way of processing is simple and fast to help you with the related work. It will be better if it is totally manual and can be customized by users according to our own favors. Remember to check its free trial package first if possible. And I hope you success. Good luck.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333;"&gt;Best regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333;"&gt;Arron&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 May 2014 07:22:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Error-when-i-import-doc-file-into-sas/m-p/89149#M18947</guid>
      <dc:creator>arronlee</dc:creator>
      <dc:date>2014-05-06T07:22:42Z</dc:date>
    </item>
    <item>
      <title>Re: Error when i import doc file into sas..</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Error-when-i-import-doc-file-into-sas/m-p/89150#M18948</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;try &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Consolas; font-size: 16px; background-color: #ffffff;"&gt;DBMS=xls&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-size: 16px; background-color: #ffffff; font-family: Consolas;"&gt;DBMS=excelcs&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 May 2014 12:44:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Error-when-i-import-doc-file-into-sas/m-p/89150#M18948</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2014-05-06T12:44:06Z</dc:date>
    </item>
    <item>
      <title>Re: Error when i import doc file into sas..</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Error-when-i-import-doc-file-into-sas/m-p/89151#M18949</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I do not believe that DBMS=xls or DBMS=excelcs will help with trying to read a WORD doc into SAS.&lt;/P&gt;&lt;P&gt;cynthia&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 May 2014 21:10:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Error-when-i-import-doc-file-into-sas/m-p/89151#M18949</guid>
      <dc:creator>Cynthia_sas</dc:creator>
      <dc:date>2014-05-06T21:10:49Z</dc:date>
    </item>
    <item>
      <title>Re: Error when i import doc file into sas..</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Error-when-i-import-doc-file-into-sas/m-p/89152#M18950</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Cynthia,&lt;/P&gt;&lt;P&gt;From the OP's log, it is obviously the error is coming from PROC IMPORT which is used to import an excel file .&lt;/P&gt;&lt;P&gt;Right ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Xia Keshan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 07 May 2014 16:24:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Error-when-i-import-doc-file-into-sas/m-p/89152#M18950</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2014-05-07T16:24:08Z</dc:date>
    </item>
    <item>
      <title>Re: Error when i import doc file into sas..</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Error-when-i-import-doc-file-into-sas/m-p/89153#M18951</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Well, sort of. It seems to me that the %WORD2SAS macro program is copying something from a DOC file and trying to paste it into Excel using DDE and then doing a Save As with DDE commands. And, the %WORD2SAS macro program was written by someone else. If the OP has issues with the macro program and how it works, he/she needs to work with the author of the macro program. And, while changing the macro program's PROC IMPORT step might work, by changing the DBMS= option -- it still seems to me that recommending DMBS=EXCELCS is dependent on the whole bitness issues, and having the PC File server -- which may not have become an issue until SAS 9.2 or 9.3 and the OP said he had 9.1 (but didn't mention his version or bitness of Office).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; And, in addition, the OP might have found this Tech Support note &lt;A href="http://support.sas.com/kb/9/554.html" title="http://support.sas.com/kb/9/554.html"&gt;9554 - "External table is not in the expected format" returned when reading Excel file with PROC IMPORT or the Import Wizard&lt;/A&gt; if searched on the support.sas.com site. To me the error message implied that the COPY from the Word doc got pasted as some other format of Excel file. So the SAVE with the DDE did not save in the right format needed for PROC IMPORT. So, to me that implies that the SAVE step in the DDE code needs to be changed instead of changing the DBMS= option.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; At any rate, since nobody knows what's actually in the Word doc (from the September 2013 post), the other issue could be that the Word doc has more in it than just a simple table, and what's being pasted into Excel is not really of a form to be turned into a sheet in Excel. And, since the whole post took place originally in September last year, and the posting in May 2014 was from somebody entirely different, I wasn't sure that how the May post was even related to the original question. And now, on rereading the May 6th post, it really doesn't add anything to the solution to the original problem from September, except to suggest something about the OP getting a Word SDK -- which wouldn't really help, either, with the %WORD2SAS macro program. But since the original posting seems very over, now on rereading everything, I think that all of our May posts are probably irrelevant and/or moot.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So signing off, without further comment.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;cynthia&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 07 May 2014 17:36:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Error-when-i-import-doc-file-into-sas/m-p/89153#M18951</guid>
      <dc:creator>Cynthia_sas</dc:creator>
      <dc:date>2014-05-07T17:36:19Z</dc:date>
    </item>
  </channel>
</rss>

