Skip to Content
0
Former Member
Feb 05, 2009 at 10:53 AM

Eror accessing BO data in VB .Net

71 Views

I am trying to access data from a BO Univers in a VB .NET thick client using Deskatop Intelligence. A code snippet is shown below:

Dim BOApp As busobj.Application

Dim BOUniv As busobj.Universe

Dim BOProv As busobj.DataProvider

Dim BOdoc As busobj.Document

BOApp = New busobj.Application

BOApp.Visible = False

BOApp.Logon("xxxxxxx", "xxxxxxxxx", "XXXXXXXXXXX:6400", "Windows AD", False, False)

' Read BO document and load array

BOdoc = BOApp.Documents.Open(docname)

BOdoc.Refresh()

BOProv = BOdoc.DataProviders(1)

j = 0

cnt = BOProv.Columns(1).Count

For i = 1 To cnt

j = j + 1

cmdbInst(i).AppId = BOProv.Columns(1).Item(i)

cmdbInst(i).AppName = safetext(BOProv.Columns(2).Item(i), 80)

Next i

' close Business Objects

BOdoc.Save()

BOProv.Unload()

BOdoc.Close()

BOApp.Quit()

I am getting the following error on the BOApp.Quit() command:

Buffer overrun detected!

Program: ...ssObjects.Enterprise 11\win32_x86\busobj

A buffer overrun has been detected that has corrupted the program's

internal state. The program cannot safley continue execution and must

now be terminated.

Once this has happened, my VB .NET program continues for awhile until it too develops a meoryerror.

Access is very slow with this code as well.

What am I doing wrong?