HI,
I'am trying to open a Windows From on the CLick of a Button in Sales Order.
It's working fine in the development environment. But when i build it as an addon and deploy it within SAP B1 , the Windows form appears and disappears immediately.
Dim oThread As New System.Threading.Thread(New System.Threading.ThreadStart(AddressOf ThreadStart))
oThread.SetApartmentState(System.Threading.ApartmentState.STA)
oThread.Start()
Private Sub ThreadStart()
Try
Application.Run(New Form1)
Catch ex As Exception
oApplication.MessageBox(ex.Message.ToString)
End Try
End Sub
What could be the reason?
Regards,
Vinoth.