problem with Connecting to a SQL Anywhere Studio Database Using ADO.NET

I am trying to connect and read the data from the asademo.db
database that is used in the document "Connecting to a SQL
Anywhere Studio Database Using ADO.NET ".  I am using Sql
Anywhere v7.0 and MS Visual Studio .Net 2003 with C#.  I can
connect to the database but I get a 'Specific cas is not
valid' exception when I try to run the myReader =
myCommand.ExecuteReader() line in the demo course.

Can anyone tell me why it is not working?
0
Robert
1/6/2005 12:41:37 AM
sybase.sqlanywhere.general 32637 articles. 4 followers. Follow

2 Replies
881 Views

Similar Articles

[PageSpeed] 20

I'm getting the same error using V7.0.2.1402. Did you find any  
solution/workaround?
0
Vivek
2/17/2005 1:50:06 PM
You need a more recent version of the ASA oledb provider.  I would recommend 
using the latest 7.0.4 ebf version of the ASAProv.70
dll.
Alternatively, you could use the ADO.Net ODBC bridge provider supplied by 
MS, or if you are considering upgrading, ASA 8.0 and later ships with a 
native ADO.Net provider (iAnywhere.Data.AsaClient).

-- 
Jason Hinsperger
Product Manager
iAnywhere Solutions
************************************************************
For the latest downloads technotes, whitepapers, webcasts and other 
developer
resources, go to: http://www.ianywhere.com/developer/
************************************************************



"Vivek Basu" <bibek.basu@visioncomptech.com> wrote in message 
news:opsmcg61jxmjcmfr@bibek.abs-cal.com...
> I'm getting the same error using V7.0.2.1402. Did you find any 
> solution/workaround? 


0
Jason
2/17/2005 2:51:29 PM
Reply:

Similar Artilces:

can't connect to sql server database with same connection used in visual studio .net 2003
I have the following code that works fine in visual studio .net 2003 but not with VWD.  I have sql server 2000 developer edition installed locally and this connection works fine with visual studio.  With VWD it fails with the exception "System.Data.SqlClient.SqlException: Login failed for user 'DARRELL\ASPNET'".  It fails on the conn.Open line.   any ideas on what the issue is?Dim conn As SqlConnectionDim connstr As Stringconnstr = "Data Source=DARRELL;Initial Catalog=Event;Integrated Security=SSPI;"Dim daEvents As New SqlDataAdapter("select * from events", connstr...

Not able to connect to remote sql anywhere using ado.net
hi, I know this is quite newbie quest. Actuall I am new to Sybase and not having any good database knowledge either , Here is my problem: I want to connect to remote database with ado.net, I am not even to connect to remote server using connection string, It is working fine with local database that is on my PC. Connection string I am using for local database connection is : OleDbConnection myConnection = new OleDbConnection(@"Provider=ASAProv;User id=dba;Password=sql;dbf=C:\database Sybase\hawaii;"); It is working fine. I have tried everything to connect to remo...

Database connectivity using SQL Server and ASP.NET in visual studio
Dear all,I am having trouble connecting my asp.net pages to a sql server database.I have the database running in visual studio and i can query it using the sql pane.My problem is that i don't know where to put the ADO.net query string or what it should look like.Does visual studio provide a wizard for doing this?Also is it possible to use CSS to change ASP.NET tags, i.e. asp:LabelAny help would be appreciated.Cheers for querystrings check connectionstrings.com yes visual studio provides a wizard if you use DataAdapter from the toolbox yes you can change the look of a label using css, in...

connect to MS SQL database using visual studio.net failed
Hi, I'm trying to connect to MS SQL 2000 using visual studio.net in window server 2003. Clicking the server explorer, connect to database icon, and selecting the provider and so on, when i click on the 'test connection', an error appear indicating : "Test connection failed because of an error in initializing provider. Device activation error. The physical name : c:\MCSDWebapps\Chapter05\vbADOsnippers\Contact.MDF may be incorrect " Note : I'm connecting to window server 2003 locally i.e I'm working on the same computer i.e server 2003. I've tried in win XP Pro and it wor...

Cannot connect to SQL Server database using ado.net after IP address has changed
Dear all, I wasn't able to connect to my SQL server 2000 database (which reside in the network in a windows 2003 server) after the IP address of the server has changed and the server is shut down, moved and re-started. I was able to connect to this server by using ADO using VB. I was able to register this server in my EM and was able to create ODBC connection. Just when using ADO.NET, I wasn't able to connect. Any ideas? Will there be any caching within ADO.NET still pointing to the old IP address? Thank you for all the help in advance. There are a lot of variable possibilites her...

Connectivity problem with IIS 6 mode ASPX and SQL Anywhere .NET Data Provider iAnywhere.Data.SQLAnywhere SAConnection
This is a multi-part message in MIME format. ------=_NextPart_000_0013_01CABC4F.394AC480 Content-Type: text/plain; charset="iso-8859-7" Content-Transfer-Encoding: quoted-printable Connectivity problem with IIS 6 mode (Windows 2003) and Sybase = SQLAnywhere Web Edition with SQL Anywhere .NET Data Provider = (iAnywhere.Data.SQLAnywhere iAnywhere.Data.SQLAnywhere.SAConnection() ) using aspx. When I try to connect to Sybase SQLAnywhere Web Edition database from = aspx using SQL Anywhere .NET Data Provider (iAnywhere.Data.SQLAnywhere iAnywhere.Data.SQLAnywhere.SAConn...

ado.net and SQL AnyWhere Connectivity
Hello: Can anyone provide me with a method of connecting to sql anywhere 5.5 pro using odbc via vb.net? I need a good connectstring. Here is a sample of my code: Dim mo_Conn As OleDbConnection Dim o_Adapter As OleDb.OleDbDataAdapter Dim o_DS As New DataSet() mo_Conn = New OleDbConnection(ConfigurationSettings.AppSettings("ProCount_SQLServer")) mo_Conn.Open() o_Adapter = New OleDbDataAdapter() o_Adapter.SelectCommand = New OleDb.OleDbCommand(TextBox1.Text, mo_Conn) o_DS.Clear() o_Adapter.Fill(o_DS) The problem that...

Problem connecting to SQl Anywhere database from executable...
detailed posting ahead. I am using PB 5.0, with the upgrade to 5.02, I believe. I am also running Windows 95 on a P133. I get the following error everytime I try to connect to my SQL Anywhere database using my executable: *** sqlcode = -1 Error Message: SQLState = IM004 [Microsoft] [ODBC Driver Manager] Driver's SQLAllocEnv failed *** I have a user object where I am setting the transaction object parameters. The following is what I am setting in that user object: (example) ** This.sqlca.DBMS = 'ODBC' This.sqlca.dbparm = "ConnectString='DSN=pf...

using oledb with ado.net connection to a database
I have just started using visual studio.net and am trying to do a database example Below is my code Public Class fclsMain Inherits System.Windows.Forms.Form Private m_cnADONetConnection As New OleDb.OleDbConnection Private m_daDataAdapter As New OleDb.OleDbDataAdapter Private m_cbCommandBuilder As OleDb.OleDbCommandBuilder Private m_dtContacts As New DataTable Private m_rowPosition As Integer = 0 #Region " Windows Form Designer generated code " Public Sub New() MyBase.New() 'This call is required by th...

problems connecting to my SQL server database in .NET
I am able to connect and display data in classic asp just fine, but I cannot connect to my database using ASP.NET. I have tried 2 tutorials on here and neither has worked. They both give me the same error: "Login failed for user 'NASHIE\ASPNET'." I am currently working on this tutorial: http://asp.net/webmatrix/tour/section3/binddatagrid.aspx "Display Data with MxDataGrid" [wmx:SqlDataSourceControl id="SqlDataSourceControl1" runat="server" UpdateCommand="" SelectCommand="SELECT * FROM [Orders]" ConnectionString="...

ADO.Net connection problems with SQL Server 2005
Hi. Im try to use ADO.Net for connection to SQL Server 2005. In my developer workstation connection work fine, but in the clients, don�t connect. .Net 2.0 is installed, SQL Client for sql server 2005 is installed Help me please. Hi, In general, if you have registered the following 2 DLLs,ADO will work Sybase.PowerBuilder.Db.dll Sybase.PowerBuilder.DbExt.dll they are located under the folder Disk:\Program Files\Sybase\powerbuilder 11 You can get the folder from registry HKEY_LOCAL_MACHINE\SOFTWARE\Sybase\PowerBuilder\11.0->Location &quo...

Not able to connect to SQL SERVER using ADO.NET
Hi, I am trying to connect to SQL SERVER 2000using VS.Net 2003.I ve configured my LOCAL sql sever to use windows authentication(in enterprise manager) Ths is the connection string i use in ADO.net for connection to the database 'test' in the local server.server=(LOCAL);integrated security = SSPI;database=test;1)This gives the following  error...."Login failed for <user name\ASPNET>"2)Also enteprise manager did not allow me to use sql server authentication.Please helpSat Have you added ASPNET as a user in the database? Hi Satishr23. It is possible that your log-in ac...

Problem trying to connect to SQL Anywhere using executable...
detailed posting ahead. I am using PB 5.0, with the upgrade to 5.02, I believe. I am also running Windows 95 on a P133. I get the following error everytime I try to connect to my SQL Anywhere database using my executable: *** sqlcode = -1 Error Message: SQLState = IM004 [Microsoft] [ODBC Driver Manager] Driver's SQLAllocEnv failed *** I have a user object where I am setting the transaction object parameters. The following is what I am setting in that user object: (example) ** This.sqlca.DBMS = 'ODBC' This.sqlca.dbparm = "ConnectString='DSN=pf...

Problem with Configuring SQL Anywhere Studio using SQLConfigDataSource
Please, I hope someone has some insight into the following. I am trying to put together an installshield installation using odbc 3.51and Sql Anywhere Studio 6.0. NT 4.0, serivce pack 3. VC++6.0. I ran into a big problem with this combination. First of all, it appears that the implementation dbodbc6.dll/odbccp32.dll imposes rules on on order of the string that is used for configuring a new datasource I wrote a simple little problem in VC++ char *svArg1 = "DSN=XYZ\\0"\\ "AutoStop=YES\\0"\\ "DatabaseFile=f...

Web resources about - problem with Connecting to a SQL Anywhere Studio Database Using ADO.NET - sybase.sqlanywhere.general

List of Nebraska Connecting Link, Spur, and Recreation Highways - Wikipedia, the free encyclopedia
Nebraska Connecting Link , Nebraska Spur , and Nebraska Recreation Road highways are a secondary part of the Nebraska highway system . They connect ...

Israeli Hotel U Coral Beach Club Eilat Has a Unique Way of Connecting Guests to Facebook
U Coral Beach Club Eilat, a hotel in Israel , is taking sharing vacation photos and checking in to the next level thanks to a collaboration between ...

Digital Media Wire - connecting people & knowledge —
dmwnews : Anomaly, the ambitious graphic novel by Brittenham and Haberlin, features augmented reality. http://bit.ly/Iwrxjr Already optioned ...

Connecting 100 Million People in Africa
„Facebook for Business“ liefert dir aktuelle Nachrichten, Tipps und Best Practices für den Einsatz von Facebook zur Erreichung deiner Unternehmensziele: ...

What stops users from connecting with an app through Facebook?
... This equals 850 million users who connect with apps using Facebook at a 59 percent conversion rate. About 590 million users back out of connecting ...

Home - WHLT 22 Connecting the Pine Belt Fan
Facebook is a social utility that connects people with friends and others who work, study and live around them. People use Facebook to keep up ...

US IT Staffing Recruiters Group - Connecting Ideas !
US IT Recruiter's Groups: IT Technical Recruitment. Its all about connecting to new Ideas !

Jewel Dots Puzzler - A Cool Connecting Dots Puzzle For Kids on the App Store on iTunes
Get Jewel Dots Puzzler - A Cool Connecting Dots Puzzle For Kids on the App Store. See screenshots and ratings, and read customer reviews.

Connecting the community, my Twitter strategy, and American Airlines at DFW - Flickr - Photo Sharing ...
I thought, to commemorate this entry on connecting people, that I'd include a photo of an airplane from one of the busiest airports in the world ...

Connecting to Community Graduation YouTube 1080p - YouTube
(Sioux Falls, S.D.) Forty-six seniors have graduated from trying to find the power button to now being avid e-mail, Facebook, Pinterest and Tumblr ...

Resources last updated: 11/27/2015 10:03:08 AM