|
Prev: VBA prog'ing help
Next: automate form, help needed
From: Bungle on 4 Jul 2008 08:38 I am writing a macro that have to insert RTF text from a database to Word. I use the following instruction "Selection.InsertFile filename:=vstrRTFFile" According to this instruction always appears the following window [URL=http://imageshack.us][IMG]http://img368.imageshack.us/img368/3895/immaginewc6.png[/IMG][/URL] [URL=http://g.imageshack.us/g.php?h=368&i=immaginewc6.png][IMG]http://img368.imageshack.us/img368/3895/immaginewc6.4c76b76dc7.jpg[/IMG][/URL] i press ok and everything go fine... but how can i disable it? on other computer this window doesn't appear Thanks
From: Jonathan West on 4 Jul 2008 08:46 "Bungle" <Bungle(a)discussions.microsoft.com> wrote in message news:A23E03E2-B42D-46EB-937A-5481E278F6D4(a)microsoft.com... >I am writing a macro that have to insert RTF text from a database to Word. > I use the following instruction > "Selection.InsertFile filename:=vstrRTFFile" > According to this instruction always appears the following window > [URL=http://imageshack.us][IMG]http://img368.imageshack.us/img368/3895/immaginewc6.png[/IMG][/URL] > [URL=http://g.imageshack.us/g.php?h=368&i=immaginewc6.png][IMG]http://img368.imageshack.us/img368/3895/immaginewc6.4c76b76dc7.jpg[/IMG][/URL] > > i press ok and everything go fine... but how can i disable it? on other > computer this window doesn't appear > Thanks Options.ConfirmConversions = False Make sure your code is a good neighbor. Read the setting, change it, and then change it back to the original value after you have inserted the file. -- Regards Jonathan West - Word MVP www.intelligentdocuments.co.uk Please reply to the newsgroup
From: Klaus Linke on 6 Jul 2008 14:39 "Jonathan West" <jwest(a)mvps.org> wrote: > > Options.ConfirmConversions = False > > Make sure your code is a good neighbor. Read the setting, change it, and > then change it back to the original value after you have inserted the > file. I recently got bitten by that. I used Selection.InsertFile FileName:=sFileName, ConfirmConversions:=False in a macro that I run a lot. And then I was surprised that the option kept changing to "False". IMO it's a bit of a bug that the code above changes the option globally... Klaus
|
Pages: 1 Prev: VBA prog'ing help Next: automate form, help needed |