.net query

forum.centura.web.developer (2000-2005) & forum.td.web (2005-2010)
FRBhote
India
Posts: 1233
Joined: 09 Mar 2017, 05:32
Location: Hyderabad, India

.net query

Post by FRBhote » 23 Jan 2004, 07:42

 Posted by:  F R Bhote 


We have

1. Evaluation version of Gupta Sql Base 8.5 Server and SQL Base 8.5 Driver
Pack installed on the machine.

2. Written following program to fetch data from sample data base ISLAND.

3. we are tying to develope .Net web application using .NET version 1.0.3705

a. Opend new asp.net web project using c#.net
b. Added following referrences in project.

Gupta.SQLBase.Data (from .net reference)
SQLBASEOLEDBLib (from COM reference)

using System;
using System.Collections;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Web;
using System.Web.SessionState;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.HtmlControls;
using Gupta.SQLBase.Data;
using SQLBASEOLEDBLib;

namespace GuptaToNetCS
{
///
/// Summary description for WebForm1.
///
public class WebForm1 : System.Web.UI.Page
{
private void Page_Load(object sender, System.EventArgs e)
{
SQLBaseConnection conn = new
SQLBaseConnection("Provider=SQLBASEOLEDB;Data Source=island;persist

security info=false;user id=SYSADM;password=SYSADM;");

try
{ // Setup the Adapter's select command
adapter.SelectCommand = new SQLBaseCommand("SELECT EMPLOYEE_ID,
LAST_NAME, FIRST_NAME, EMAIL,"+"CURRENT_SALARY FROM EMPLOYEE", conn);

// Fill the DataSet with the Adapter
adapter.Fill(ds, "EMPLOYEE");
}
catch (SQLBaseException se)
{
MessageBox.Show(se.ErrorMessage);
}

// Close the database connection
conn.Close();

}

}
}

3. During Compilation it is giving error
System.io.Filenotfound exception
or
Can not access Gupta.SQLBase.Data because it is being used by another
process.
(Screen shots are attached)

Please throw light on it we have successfully connected throgh oledb
provider and using ado.net oledb classes. But if we try to use .net classes
from Gupta.SQLBase.Data eg. SQLBaseConnection, SQLBaseDataAdapter then we
are getting above errors.

If it is of interop issue and try find String name and public key token it
is giving error not valid string name.

Attachment: GuptaError2GIF.gif
Attachment: GuptaError1GIF.gif

Return to “td.web”

Who is online

Users browsing this forum: [Ccbot] and 0 guests