2860 byte By
lew26 at 2007-11-24 19:33:29
hello, I been working on this project for weeks now i can't seem to extract the date from an excel file using ADO.Net here is the code below. What i would like to accomplish is i would like to gather all the values from each row with the excel file and insert them into an array and a listbox. T...
816 byte By
afj at 2007-11-24 19:35:17
I have a problem to read a field from a dbase dbf file. This filed is a text field, but the data stored in this field is a hexadecimal value. To use this data I need to calculate the "asc" of this string. The characters below 128 are calculated correctly. For characters between 128 and 255 I calcula...
I am a beginner in using database and I am using sql2000. I will like to store my .swf file in my database but I found an informtion which is to store my swf file url in database whereby for my .swf file it can keep in other places.Who can tell me more about this because I am still unsure about it....
1576 byte By
pennywise at 2007-11-24 19:44:45
I am running Windows XP Pro with Service Pack 2, Visual Studio 2005, Microsoft SQL Server 2005 and Microsoft SQL Server Express Edition.I have a file called EmployeeDirectoryOle.aspx in which I used a Repeater Control to display all the Employee records within the Employee table of the pfsnicom.mdb...
385 byte By
kalette at 2007-11-24 19:47:37
I am making a call to a store procedure that returns sometimes 1 table, sometimes 2 tables depending on the condition. I am capturing the result set by only using DataTable. Is it safe enough to say that when the store procedure returns 2 tables, .Net DataTable object will always capture the first...
1828 byte By
nectuss at 2007-11-24 19:48:28
Hy!I'm working on some project and i need some help. I developing in VB some application with database. I have two tables in MSAccess, one is "employes" and another is "travel". This two tables are in relational 1-to-many. I have one form where i have some data for employe and his travellings....
When I use the fallowing code:_RecordsetPtr pRs;pRs.CreateInstance(__uuidof(Recordset)); pom.Format(L"UPDATE Member SET Name='%s' where IDClen=%d", m_name,m_id);pRs->Open((LPCTSTR)pom,L"Provider=MSDASQL.1;Data Source=Blue Sky Database;",adOpenDynamic,adLockOptimistic,-1);pRs->Update...
Hey, two questions guys:1. Visio - Database Model Diagram: I have two tables:table 1 (Parent): Group {PK: GroupUIN, Attributes: Name, Desc}table 2 (Child): User {PK: UserUIN, Attributes: ParentGroupUIN, Name, Desc}I connected the two entities with a "Relationship". Under "Miscellaneous" tab, I speci...
180 byte By
KnNeeded at 2007-11-24 20:00:41
Hi Gurus,<br/>I was wondering how to return a list of the tables in the SQL Server like Studio .NET does in the Server Explorer with ADO.NET?<br/>Thanks<br/>KnNeeded
208 byte By
THY02K at 2007-11-24 20:03:06
Hi guys, trying to access Reporting Service:<br/> http://localhost/reports<br/>Ran into this: "The underlying connection was closed: The remote name could not be resolved."<br/>Any idea? Thanks.
121 byte By
THY02K at 2007-11-24 20:06:19
Hi, DataGrid/WinForm - <br/>a. how do I set column width?<br/>b. how do I set column width to "AutoFit"? <br/>Thanks
3621 byte By
Lit at 2007-11-24 20:07:24
I have a table like this:8 field6 of them are VarChar:Polskie,Angielskie, Wymowa1,Uzycie1,Uzycie2,Uzycie3One of them is primary key Nr_Slowaand Nr_Kategorii is a foreign Key.I have to do UpdateCommand for my own. I tried to do this like this, but it didn't work (There was an exception which c...
241 byte By
THY02K at 2007-11-24 20:08:52
Hi, I'm using Visio, used "Reverse Engineering" to generate an ERD diagram from database. I edited the diagram and wanted to generate C# code. For instance, I want table "User" maps to "User.cs" (User entity), how can I do this? Thanks.
Hi, I am using ADO 2.81 with C++ 6.In my program I have a datagrid which is filled with data from adodatacontrol. Whenever i select a different row, my app needs to display information about it. The problem is, I can't find in which row the user clicked...Is there any code that can help me?i am...
HI,I am inserting a number of rows into a table using Data View Object and addnew and endedit methods of dataview. In between addnew and endedit methods, I am supplying values of parameters of insertcommand of data adapter object. The above process is in a loop.After the loop I am opening Sql connec...
206 byte By
btkaruna at 2007-11-24 20:17:33
hi,<br/>how i create a user from windows application to sql server database.I am able to create new database using create database,but am stuck with creating user.<br/>thanks in advance<br/>karuna
474 byte By
yoyosh at 2007-11-24 20:18:50
I have problem while trying to connect to my own database. I created a user martinez, which i supply with a password and all possible rightsI set the HKEY_LOCAL_MACHINE\Software\Microsoft\MSSqlserver\MSSqlServer to a value of 2. and I`m still getting such error: "Login failed for user 'mart...
2477 byte By
jd6string at 2007-11-24 20:19:25
The class listed below uses a CSV file and OdbcDataAdapter object to populate a DataSet using a nested query BUT I keep getting an Access Violation exception when I call OdbcDataAdapter.Fill(). The message is:"Attempted to read or write protected memory. This is often an indication that other memo...
388 byte By
tpadhu at 2007-11-24 20:20:46
Hi,I've an xmlfile which has custname,custid and orders.This xml file is created dynamically.In the form, i've a datagrid ,combobox and one button.if i select >2 in combobox,then grid has to show the customers (like name, id,orders) who have ordered more than twice.how to write a query...
358 byte By
btkaruna at 2007-11-24 20:24:14
hi,i need to store mp3 file into sql server table.any url or sample is of great help to me .As the application runs at client and files and mp3 files are created at client i need to either transfer these files to server system or store these files into database.so i need sample to store the mp3 to...
hi i'm very novice in .net.<br/>can any body tell me how can i read the field of database to make the login page.i have to connect the MYSql with vs.net 2005.<br/>if could then please provide the appropriat code or detail steps.<br/>thanx
when i tried the following code it store null value.......why?? Dim ConnStr As String = "Driver={MySQL ODBC 3.51 Driver};Server=localhost;Database=AgentImg;uid=root;pwd=;option=3" Dim con As OdbcConnection = New OdbcConnection(ConnStr) 'Dim str As String = "insert into...
Dim Titles_TitleAuthor As New DataRelation("", _ dsPubs.Tables("Titles").Columns("title_id"), _ dsPubs.Tables("TitleAuthor").Columns("title_id")) Dim Authors_TitleAuthor As New DataRelation("", _ dsPubs.Tables("Authors").Columns("au_id"), _ dsPu...
1409 byte By
leeza at 2007-11-24 20:34:47
I am working on library database.<br>In database there is one table called "TB_MEMBER"<br>its column are "C_M_FINE" and "C_MEM_ID".C_MEM_ID is our primary key.<br> Similarly the other table is "TB_MEMBER STATUS" and its column is "C_M_S_FINE" .here "C_MEM_ID" and "C_BOOKID " w...
1113 byte By
John63 at 2007-11-24 20:38:18
I'm very new at this and am having a problem I think connecting to a "local" db.When I run my code, I get this exception:System.Data.SqlClient.SqlException: SQL Server does not exist or accessdenied.Here is my code:System.Data.SqlClient.SqlConnection conn;System.Data.SqlClient.SqlCommand comman...
Hi everyone,<br/>I need to know if I can use variables to indicate the different parameters of a sql connection string in ado.net instead of constants. If so could you please provide a code sample?<br/>Thanks
834 byte By
Suzi167 at 2007-11-24 20:58:33
Hello Everyone,I am totally new to ADO so please forgive me if I am asking a question which is too simple.I am trying to get started on a project which uses ADO in VC++I was looking around and I found a few examples. Here are som equestions which came to mind.I want to thank in advance anyone who re...
589 byte By
leeza at 2007-11-24 21:00:31
hi,I'v problem in my database project (visual C#.net, sql server 2000)problem 1:how to remove two namespaces from a single project.because it is creating a lot of problem.when i want to access forms in other forms having different namespace ,it gives error.2nd problemhow to open first form in t...
1574 byte By
John63 at 2007-11-24 21:00:53
Hi.I'm trying to get a string entered in a UI text field and pass it to an Access database. Here is my method:public static void insertCustomer(){ System.Data.OleDb.OleDbConnection conn; System.Data.OleDb.OleDbCommand command; try { conn = new System.Data.OleDb.OleDbConnection(); // se...
1622 byte By
John63 at 2007-11-24 21:01:57
Hi.I get this exception when I run my code:"Index (zero based) must be greater than or equal to zero and less than the size of the argument list"I am trying to read strings entered in text fields in my UI, and store them in a Access database.Here is my code:System.Data.OleDb.OleDbConnection conn;Sys...
1961 byte By
GC8 at 2007-11-24 21:03:15
Help is needed here. Im doing a calculator using only SATCK. I have the stack but im having problem to calculate the expresion.For examplethe user enter 4 / 5 + 7 * 2 - 4it must calculate the expresion to give u a result = 116my problem is that when there is a space it stop (do not read the other n...
1325 byte By
snowman at 2007-11-24 21:08:06
I'm writing a windows Form app with C++ and accessing a SQL database. What I'm getting is, in all the examples are for WIndows Console applications. I'm not writing a windows console application, I'm using windows forms so I cannot use the /CLR:OldSyntax compiler command line (wh...
I have a problem when dealing with identity columns and I request you to provide me a solution. I have described the problem below. (Platform : SQL Server 2000, VS .Net 2003)Problem Description:* I am currently developing an application which includes reading data from an excel file and updating aro...
269 byte By
THY02K at 2007-11-24 21:09:41
We're planning to use SQL 2005 Reporting Services, but first:<br/>1. Is it as buggy as 2000?<br/>2. Formular field and DTS packages: VBScript or C#?<br/>3. Can you deploy reports built for SQL 2000 on SQL 2005?<br/>Thanks in advance.<br/>Norman Fung
439 byte By
John63 at 2007-11-24 21:10:36
Hi.I'm having a problem when I try to update an Access database.Here is my line of code that generates an exception:command.CommandText ="UPDATE CUSTOMERS SET ContactName=@contactName," +"Country=@country, City=@city, Phone=@phone," +"Zip=@zip, Fax=@fax, CompanyName=@companyName" +"WHERE Custom...
15 byte By
THY02K at 2007-11-24 21:10:41
Is UDF slow? =)
1278 byte By
Hp11 at 2007-11-24 21:15:25
Dear IT Gurus ,Himanshu here.i hope u will try to guide me as much as you can with this very tricky Problem... My problem is like this...In VB.net i want to save a Form with some Controls (such as Text boxes,Picture boxes And labels) on them at Runtime.The form should be saved with all it...
Hi,This is an ADO question not ADO.net so I hope you can help. I'm trying to share a connection on a long page with many rowsets and I don't want to open a new connection each time. In the following code I get an error that the "Current Recordset does not support updating. This may be a li...
Hi,I have a process that copies about 2,000,000 records from a non-relational database and inserts them into a relational database. This means I have to generate PK ids for many of the records and therefore cannot do a simple DTS transfer. I am using SQL server.At the beginning of this 15-25 minute...
686 byte By
Shvalb at 2007-11-24 21:19:26
Hi.I created a .NET console application and used the above connection string:m_pOdbcConnection = new OdbcConnection;m_pOdbcConnection->ConnectionString = S"DSN=myDB;";m_pOdbcConnection->Open();this works fine. BUT if I create a new 'ASP Service' project and use the same code it doesn...
1115 byte By
hlmodi at 2007-11-24 21:22:28
I want to pass by reference an ADO Connection which has been already opened in Excel VBA to a C++ DLL, but I get the following error:"Unhandled exception at 0x4dd5230f in EXCEL.EXE: 0xC0000005: Access violation writing location 0x1775238d."What am I doing wrong? The code I am using is:- VBA:Declare...
758 byte By
Suzi167 at 2007-11-24 21:23:04
HEllo all, gurus out thereI am relatively new to SQL Server and I am starting to learn a bit more.Now that I am at the stage where I can run various quiries,etc I want to know how can I interface a C++ application to my SQL server database.can you please give me some general ideas.I have some experi...
430 byte By
livehed at 2007-11-24 21:24:59
Hi, I am working on a .Net application using C#. I am using System.Data.OracleClient and inline sql queries to connect to Oracle database. I need to insert new records from the application in the database.The database tables have autoincrement enabled on their primary keys. Can anyone please help me...
471 byte By
krayzee at 2007-11-24 21:26:04
Hi, and sorry if my question has been posted before :)I need to develop a C# app that supports the synchronization of at least two databases (MS SQL Server Express). Does anyone know a way to do that? Especially the part when the number of the records in a table are different, is there a way to kno...
1940 byte By
johnnh at 2007-11-24 21:27:19
HelloI have a dataform attached to an access database with two tables. I am showing details on 2 text boxes from one table when i press the load button. But need to show details from the second table in the same text boxes when i press a second load button on the same form.Me.OleDbDataAdapter1.Inser...
1230 byte By
phoenix13 at 2007-11-24 21:30:45
A message that is error # 3092 appears when I clicked radio1.I think the sql string about updating must be wrong.Who know how to deal with it,please tell me.Thanks.code:void CMain::OnRadio1() { try { CString sql; sql.Format ("select * from apts where qno = %d", m_qno); m_pRecordset.CreateI...
264 byte By
krutika at 2007-11-24 21:35:54
Hello,<br/>I'm searching for ADO.NET equivalent of SQLSetConnectOption method. I know this method is deprecated and SQLSetAttr has replaced it. <br/>But I need to simulate this method in ADO.NET to set options. Can anyone please help?<br/>Thank you
I had create a dialog(named "add new") class as below:this the .h file:class CAddNewDialog{public: CAddNewDialog(int); virtual ~CAddNewDialog(void);........protected: _ConnectionPtr pCon; _RecordsetPtr pRs; _RecordsetPtr pRsLeixing; HRESULT hr;} and this is the .cpp file:CAddNewDialog::CAddNewDial...
410 byte By
krutika at 2007-11-24 21:47:39
I have a function which accepts Insert / update statements as parameter and updates the database. The function needs to store the affected rows and further work on these rows.Do I need to use the dataset to execute update/ insert statement and then fill dataset with the affected rows?Or Should I use...
Hi,In my VB.NET app, I initialize a connection when the application is loading.Case scenario here:Operation 1- I go into my "Member Management" winform and search for the Membre #2.That creates a BEGIN transaction ...calls a stored proc with (UPDLOCK) to have the record locked to others and fill a d...