Click here to Skip to main content
15,892,643 members
Home / Discussions / Visual Basic
   

Visual Basic

 
QuestionProject registration code request? Pin
Andraw Tang14-May-10 4:20
Andraw Tang14-May-10 4:20 
AnswerRe: Project registration code request? Pin
Johnny J.14-May-10 4:29
professionalJohnny J.14-May-10 4:29 
GeneralRe: Project registration code request? Pin
Andraw Tang14-May-10 4:34
Andraw Tang14-May-10 4:34 
Questioninclude libraries inside vb.net executable Pin
b-rad31114-May-10 3:41
b-rad31114-May-10 3:41 
AnswerRe: include libraries inside vb.net executable Pin
Luc Pattyn14-May-10 3:57
sitebuilderLuc Pattyn14-May-10 3:57 
GeneralRe: include libraries inside vb.net executable Pin
b-rad31114-May-10 3:58
b-rad31114-May-10 3:58 
AnswerRe: include libraries inside vb.net executable Pin
Dave Kreskowiak14-May-10 4:00
mveDave Kreskowiak14-May-10 4:00 
QuestionRegarding word application using vb.net Pin
vijaylumar14-May-10 1:14
vijaylumar14-May-10 1:14 
hi all

in my project i have a task with Ms word application
i have to open the already existing word document and
i have to pass the values to the bookmarks in that document

i written the following code

Dim wordapp As New Word.Application
wordapp = Nothing
wordapp = CreateObject("word.application")
Dim olddoc As Word.Document
olddoc = wordapp.Documents.Open(AppPath + "Designs\Gantry2.doc")
'book marks
For i As Integer = 0 To 48
With wordapp.ActiveDocument
.Bookmarks.Item("b" + i.ToString()).Range.Text = DG_GanDict.Item("b" + i.ToString())
End With
Next
wordapp.ActiveDocument.SaveAs("test.doc")
wordapp.Visible = True

the above code works in Ms office 2003
but the same code does not works or executes in ms office 2007
even though i added the refernce

when i run it in ms office 2007

i get Runtime.InteropServices.COMException

This file could not be found.
(C:\//Program%20Files/VCS/...)

and ErrorCode = -2146823114

that to it happens in c:\ drive only
when i copy and paste the application in other drive like D:\
it executes properly

can any one have a idea about this problem

and is there any common code which runs in ms office 2003 and 2007 versions

thanks in advance
vijay kumar d
AnswerRe: Regarding word application using vb.net Pin
The Man from U.N.C.L.E.14-May-10 3:39
The Man from U.N.C.L.E.14-May-10 3:39 
Questiontext box control for only numeric value Pin
faisalali_7813-May-10 21:17
faisalali_7813-May-10 21:17 
AnswerRe: text box control for only numeric value Pin
Johan Hakkesteegt13-May-10 21:21
Johan Hakkesteegt13-May-10 21:21 
AnswerRe: text box control for only numeric value Pin
Dalek Dave13-May-10 22:15
professionalDalek Dave13-May-10 22:15 
AnswerRe: text box control for only numeric value Pin
Dave Kreskowiak14-May-10 2:12
mveDave Kreskowiak14-May-10 2:12 
AnswerRe: text box control for only numeric value Pin
DaveAuld14-May-10 3:45
professionalDaveAuld14-May-10 3:45 
Questionthanks Pin
faisalali_7813-May-10 20:45
faisalali_7813-May-10 20:45 
AnswerRe: thanks Pin
Dave Kreskowiak14-May-10 2:11
mveDave Kreskowiak14-May-10 2:11 
GeneralRe: thanks Pin
JHizzle14-May-10 3:21
JHizzle14-May-10 3:21 
GeneralRe: thanks Pin
Luc Pattyn14-May-10 3:38
sitebuilderLuc Pattyn14-May-10 3:38 
QuestionEnter key pressed event Pin
faisalali_7813-May-10 20:33
faisalali_7813-May-10 20:33 
AnswerRe: Enter key pressed event Pin
DaveAuld13-May-10 20:40
professionalDaveAuld13-May-10 20:40 
Questionneed accurate code Pin
faisalali_7813-May-10 20:32
faisalali_7813-May-10 20:32 
AnswerRe: need accurate code Pin
DaveAuld13-May-10 20:36
professionalDaveAuld13-May-10 20:36 
Questionkey press event in vb.net Pin
faisalali_7813-May-10 20:23
faisalali_7813-May-10 20:23 
AnswerRe: key press event in vb.net Pin
Wayne Gaylard13-May-10 20:29
professionalWayne Gaylard13-May-10 20:29 
GeneralRe: key press event in vb.net Pin
DaveAuld13-May-10 20:31
professionalDaveAuld13-May-10 20:31 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.