By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,524 Members | 1,475 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,524 IT Pros & Developers. It's quick & easy.

Open an existing Word file?

P: n/a
Hi,

I wrote a VB.net program that import a text file, which I will parse and
place into arrays.
My question is how to open an existing Word file without the Dialog Box that
has a 4x10 table and place the array[] into the table ?

Thank you for any assistance.

CopynPaste
Nov 21 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
* "=?Utf-8?B?Q29weW5QYXN0ZQ==?=" <Co********@discussions.microsoft.com> scripsit:
I wrote a VB.net program that import a text file, which I will parse and
place into arrays.
My question is how to open an existing Word file without the Dialog Box that
has a 4x10 table and place the array[] into the table ?


Without what dialog box?

For office automation using .NET, take a look at
<URL:http://msdn.microsoft.com/office/>.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://dotnet.mvps.org/dotnet/faqs/>
Nov 21 '05 #2

P: n/a
Hi,

Opening the Word file itself is easy; the harder part will be using the
array as input for the table.

Here's what I do: I need to select random accounts and place the current
receivable balances for those accounts into a Word merge letter which
displays each selected account and that account's balances. I use a sql
server sp to zap and then create a table, containing the data I need - name,
account #, 0-30 days, 31-60 days, etc. Then I created the Word doc and
created a macro that loads that table into a table that displays as
necessary, and then of course merges so that each customer has a page. When
I run the routine, I do the sp rebuild as I mentioned above and then I call
the Word doc and macro, thus:
Case "welcome.doc"

macroname_ = "/mwelcome"

longstringname_ = globalmsopath & "\winword.exe " & "f:\imcapps\docs\" &
mergeletterbox.Text & " " & macroname_

Shell(longstringname_, AppWinStyle.NormalFocus, False, -1)

Now this opens the Word doc but not into a dialog box, as you wish. I'm
pretty sure I could do that also, by calling it from the dialog box and
constraining Word and a child of that dialog box (but I haven't tried that).

HTH,

Bernie Yaeger

"CopynPaste" <Co********@discussions.microsoft.com> wrote in message
news:45**********************************@microsof t.com...
Hi,

I wrote a VB.net program that import a text file, which I will parse and
place into arrays.
My question is how to open an existing Word file without the Dialog Box that has a 4x10 table and place the array[] into the table ?

Thank you for any assistance.

CopynPaste

Nov 21 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.