pranita shaha

pranita shaha

  • NA
  • 15
  • 2.7k

Open word in panel vb.net

Nov 15 2018 1:16 AM
please, I only want to open any office app into the panel using vb.net
 
please help
thanks
 
my code not work
 
Dim pathword As String = "C:\Users\Sixsigma\Desktop\Shareproject_code\Pathfile\test.docx"
oWord = New Word.Application
oWord.Application.DisplayAlerts = False
oWord = CreateObject("Word.Application") '
oWord.WindowState = Word.WdWindowState.wdWindowStateMaximize
oDoc = oWord.Documents.Open(pathword)
SetParent(oWord.hwnd, Panel1.Handle)
SendMessage(oWord.Hwnd, WM_SYSCOMMAND, SC_MAXIMIZE, 0)
oWord.Visible = True

Answers (1)