IBO for .NET

I am new to programming the .net IBOs so here is my first challenge connecting to the IMIS database

I created a windows appliction and added a reference to the asi.ibo.dll and write the following code behind a simple button

imports asi.ibo

 Dim i As Integer Dim cn As String

 

Try

cn = "Data Source=myserver;user id=m;password=mypassword;Initial Catalog=IMIS"

iboAdmin.InitializeSystem(cn)

 

Catch

MsgBox(Err.Description, MsgBoxStyle.Critical,

 

"Error")End Try

 

 

WHen I call the initializesystem function I get a message box "There is no source available fro the current location"  anyone knows what this means.

 

 End Sub 

 

 

 

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Hi mfungafat, Try switching

Hi mfungafat,

Try switching the "initial catalog=" in your connection string to "database=".

You can also put your connection strings in the web.config file. iBO.NET is set to use the "DataSource.iMIS.Connection" connection string in your web.config file by default when you use iboAdmin.InitializeSystem() without parameters.

Sean Irish

I Second That

That particular error means that an exception occurrred within Asi.iBO.dll, and there is no source available for that assembly to be able to show you the line on which the error occurred. I would suspect Sean is correct that it is specifically related to the connection string. We usually put ours in the web.config as Sean mentioned. Try the following:

<configuration>
    <connectionStrings>
        <add name="DataSource.iMIS.Connection" connectionString="server=SERVERNAME;uid=USERNAME;pwd=PASSWORD;database=DATABASENAME;"/>
    </connectionStrings>
</configuration>

Justin D. Trout
Development Team Lead
Association Technology Solutions

IBO for .NET

Hi guys, thanks for the advice, only thing is I am not writing a web app, I am trying to connect via a windows application so there is no web config.  There is an app.config file.  Will try the different connection string onfiguration.

IBO for .NET

Hi guys, thanks for the advice, only thing is I am not writing a web app, I am trying to connect via a windows application so there is no web config.  There is an app.config file.  Will try the different connection string onfiguration.

IBO for .NET

Hi guys, thanks for the advice, only thing is I am not writing a web app, I am trying to connect via a windows application so there is no web config.  There is an app.config file.  Will try the different connection string onfiguration.

You will also need to add a

You will also need to add a reference to Asi.dll and Asi.Lexicon.dll (or at least make sure they're in the same folder as your application .exe) if you are using iMIS 15.0.1 or above, just FYI.

Eric Means
System Architect, ASI