9,022 Topics
here below is the code for saving the form [CODE]Protected Sub save_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles save.Click Dim ConnStr As String Dim visitors_name, officer_to_visit, purpose, date_of_visit, time_in, time_out As String Dim serial_no, year, floor As String Dim photo As Byte ConnStr = ConfigurationManager.ConnectionStrings("gate").ConnectionString() Dim conn As …
Hi, can anyone help me in storing a text file data to database using C# coding. I'm not sure of the below code can anyone correct me. Thanks in advance. Note: [U]TextFile1.txt[/U] 124 Keer 22 14000.000000 125 gjh 45 12103.000000 126 sg 48 63230.000000 129 fdgd 21 65620.000000 [CODE] con …
I have a database created in Microsoft SQL 2000 Enterprise Manager. I need to change the datatype for a column name EngrMultiplier in the table ProjectReCapParameter. The current datatype is INT and I would like to replace it to FLOAT. What should I do? Write a query or change the …
This code demonstrates how age might be calculated and filtered using the DateDiff method in SQL. Also, note that both the parameters are set to NULL by default, hence making them 'optional' to a certain limit.
I have a users table that has a table titled 'DOB', of format DateTime in MSSQL. Now, I would like to filter rows for all users who are over 30. till now i used this code: [CODE=SQL] SELECT * FROM [User] WHERE [User].DOB > = DATEADD(YEAR, @ageFrom, GetDate()) [/CODE] this …
hi frnds, when iam accessing the date ,,,it willshow both date and aswell as default time. iam only accessing the date,,,,, here my coding is given below........ [code] <asp:GridView ID="GridView1" runat="server" BackColor="White" BorderColor="#CC9966" BorderStyle="None" BorderWidth="1px" CellPadding="4" DataSourceID="SqlDataSource1" Style="z-index: 103; left: 288px; position: absolute; top: 256px" AutoGenerateColumns="False"> <RowStyle BackColor="White" ForeColor="#330099" /> …
hello ppl, I need your small help regarding my approach.. Coding in :- VB.net database:- Mssql2005 I have an web application(Changepoint a tool for project management) whose database is in mssql they have provided us the web service API's by which we can load the data into their database. e.x. …
Dear Experts I use following codes to diplay data in combobox str = "SELECT sno,name,city FROM employees" cmd = New SqlClient.SqlCommand(str, con) da = New SqlClient.SqlDataAdapter(cmd) dt = New DataTable da.Fill(dt) With ComboBox1 .DataSource = dt .DisplayMember = "name" .ValueMember = "sno" .SelectedIndex = 0 End With Table has three …
hi.. How can i add a database in my website using asp.net. its a student project and i hav to create an online flight reservation system. in which i am using SQL Database? Kindly tell me by some example that how can i add record using some form ? but …
Hello, can anyone help me find a document explaining a general way to design "Live" tables in SQL? i have an application linked to a db that contains live tables in it (tables that have records always updated, inserted, deleted and many applications read/write in it) my biggest worry is …
Hello, I'm using an asp.net [COLOR="Red"][B]Login control [/B][/COLOR]via visual studio 2008 and it is working fine locally. I tried to upload my project files to a web server and trying to login through login control I've been created. I'm facing the following problem: ---------------------------------------------- Server Error in '/test2' Application. -------------------------------------------------------------------------------- …
OK before I fumble around any more and end up needing to change everything again...I was wondering if someone would be kind enough to have a discussion with me about a networked solution. Right now what I have is an Access database with forms that manage the data...this is great, …
File under FAIL: social network widget maker RockYou has fallen victim to a SQL injection flaw and as a result some 32.6 million users are being urged to change their passwords as a matter of urgency. Security specialists Imperva discovered the problem at social networking development site Rockyou.com and issued …
What I'm designing is a user control who's purpose is to gather a list of records from a SQL database based on criteria selected on the control and then transmit this list to various other systems or devices. To accomplish this I've defined a .Net interface which each endpoint having …
Hey guys! I seem to be posting here a lot the past few days but as I am new to SQL Server I am finding to quite a pain to get used to! I am having a problem referencing foreign keys. I did post another thread about this but this …
The scenario is: i have a textbox, a button and a grid view that make up a simple webpage where you can search and edit/delete an entry. the grid view's datasource ID is set to NONE. And this is the code for populating the grid view that is found in …
here, i got a problem which i could not find solution, here in this form i need to search the data from the sql database and show it in the formview, below is the code [CODE]Protected Sub searchn_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles searchn.Click Dim a As …
hi i had got a problem that i want to display the difference between two dates to be displayed in a grid view ,here the first date can be taken from a textbox. when the button is clicked the difference between dates to be displyed in days, here iam using …
hi frnd this is raghuram i had got a problem when iam working with a form ,,,,in a textbox it will automatically increment a serial number and it will be stored in sqlaerver2005 database at evey time when form is loaded..... pls give me reply as early as possible.....
Hi am working on a project and am using sql server 2005 express as my database server, the problem is i can;t connect to the sql server from any machine on my local network (windows). Below is my connection string [CODE]con.ConnectionString = "Data Source=webserver1\SQLEXPRESS;AttachDbFilename='C:\POSM_DB.mdf';Integrated Security=True;Connect Timeout=30;User Instance=True;" [/CODE] It works …
Hi i m new user in vb.net so i want plz u people help mee, i just want to conect my project to sql server database.
Hi all, I'm trying to write query in MSSQL which will return a single value, but the problem is, I want to get the result by a position in results, e.g. [code=sql]SELECT [ID] FROM dbo.Users WHERE Status = 1[/code] -- and then some code to get let's say fifth record …
hi all, i am currently writing a program as my school homework. it used to work and when i changed the column name in my database, it won't save data to the database. i am currently using sql server 2005 and visual studio 2008 and c# language. here is my …
my project needs an implementation of supertype-subtype, however, we haven't tackled that topic yet at school. i know the concept of supertype-subtype, but i don't know how to write it out on mssql. i even don't know how to insert data using supertype-subtype. here's the reqs's: * there is a …
str = "select sno,name,city from employees" dt = GetTable(str) Public Function GetTable(ByVal mstr As String) cmd = New SqlClient.SqlCommand(mstr, con) da = New SqlClient.SqlDataAdapter(cmd) dt = New DataTable da.Fill(dt) Return (dt) End Function How to display three columns sno,name and city in combobox Please help
Dear members I have a challange. I want to update my CRM database (MSSQL) with turnover numbers from our ERP database. I can retreive the data in different file types from my ERP database so they can be importet as a flat file. But does anybody have a good idea …
I'm a beginner in .net programming environment.I am using c#. i have a text box(txtSearchKey) for user to enter the text key. i have a combo box(cmbSearchBy) to specify in which field of employee table ,search key should be used to retrieve data. when i use the above code i …
Someone please help! I'm writing a program that enable a user to search for a patient Info when patient number is given. here is the search code snippet [code] public ArrayList searchPatient(String patientNum) { try { String sql = "SELECT fname, sname, location, dob, dor, race, gender, status, initials, idnum …
So I didn't know where to put this but I had somewhat of a newbie question. I am trying to create a blog for my friend. Its going to be a full fledged site and I want to store the blogs and be able to search on them later. I …
hii.. I am working on an asp.net site.. Now My Client wants to copy content from any article(may include images) and show that in the website as a static page.. Now i have to provide him with interface.. i used simple multiline textbox in which he can paste the whole …
Basically I have a website designed in Netbeans as an IDE and created in Java using Servlets and jsp pages for interaction. I now wish to put this website online using a server, currently the website does interact with an SQL database but I have removed this functionality so just …
I have two databases with the same table name and identical schemas and no duplicate entries. How would I merge the information? SQL 2008
Hi, Since I am a newBee in asp.net, I need the assistance from all of you who are experience in this field of ASP.NET. I am creating a web page, where the user gives comment and star rating. The rating function is created in JavaScript. Please note that I am …
here i have a problem in saving thing. i have a form and a table connected to two different sql tables gate_outgoing and gateout_item.the form should go into the gate_outgoing and the table should go into the gateout_item table. i need to save this form along with the table and …
I want to get data sales item, its with compare table item with table sale although item in table sale nothing, data will show according with data item i have SQL like this [code] select i.code,s.date_sale from Item i left join(select * from Sale where date_sale <='2009-01-31') s on i.code=s.code; …
Please Help me, We had a Software application Developed using VB6 with MSSQL SERVER2005 as Database(Remote) in [url]www.znetindia.com[/url] our web space provider , the application was working properly until they upgraded the Server configuration, Now we are not able to connect with the database using the normal OLEDB connection String …
this is my code [code] MSFlexGrid1.Clear On Error Resume Next Set rs = cn.Execute("SELECT count(*) FROM ENTRY_GAJI_BAGIAN") If Err.Number <> 0 Then MsgBox "Cannot open recordset due to this error: " & Err.Description MousePointer = vbDefault Exit Sub End If If rs(0) > 0 Then MSFlexGrid1.Rows = rs(0) + 1 …
Currently our database is set to case-insensitive so when I search for the word "Math" I can get "MATH" or "Math" and even "math". Now I would like to run a script that searches for any word that is the lower case form such as "math" or "science". Since the …
Ive got some information that i want to be sent to the database, first the information is taken from the database to the textboxes which works, i will then be able to edit the text, and send back to the database, ive got the Command all coded but when i …
Hello all. I am new to .net development. I am inserting the data and i want the data to get displayed in the grid view as i enter the data.But it doesn't get displayed immediately. If i refresh the page,the data gets inserted twice. I tried to solve this using …
Hi, I need help with the following; Table 1 --------- Col A 1 2 3 4 5 Table 2 --------- Col A ColB 1 AA 2 BB 3 CC 4 DD 5 EE I need to look up say Table 1 Row 3, reference that to 'Table 2' but instead …
What I need is the SQL code to display the last business day - usually will be one day prior, but I want that if I run this code on Monday that, instead of Sunday's date, I get Friday's date. This is what I started with [CODE] - Automatically generate …
hi i asp.net developer i need to upload the multiple image single time and retrieve the image in table format.. any give reference site and code..
It's been a while since I have had to create a search box to search and display data from sql data base. Just need a little push to refresh my memory. Thanks
what up Gurus, My name is Rick Pace and Im a recent IT grad who has been working on a sales lead management system using ASP.net and SQL server. This is a highly functional web app that ive been working on for longer then I care to admit. I had …
Hello, I need to make a cursor, which would call a stored procedure to do something for me... but the procedure needs dynamic parameters. first one, it has to retrieve existing ID number from a table and the second parameter will be new value updated... so, for every row, I …
I used below code to display some data using crystal report.i used separate dataSet() object and connected it to the crystal report setDataSourse. There are no compile errors,but after running it gives me the error [B]"Load report failed". [/B] plz help.. The code. [CODE] String ConnectionString = ConfigurationManager.ConnectionStrings[0].ConnectionString; SqlConnection con …
Hi to all, I use c#.net 2005 application with sql server 2005, and I hope to make crystal report, So I read many tutorial about crystal reports... But when I create new crystal report, I have this dialog in wizard steps: [URL="http://img102.herosh.com/2009/12/11/110248000.gif"][B]Please Click Here..[/B][/URL] The previous dialog difference tutorials dialog …
i have create a simple aplication to insesrt some details to a database. and now i need to update the details. it means (PK IS ITEM NUMBER) WHEN I fill the update form with an existing ITEM NUMBER the table is successfully updating, but when i enter a NOT EXISTING …
Please see and find out what was the problem. It's seem OK on me but it doesn't work on vb code using SQL Server 2000 [code=sql]"SELECT qry_close_month.Item_code, T_ITEM.item_name, " & _ "Sum(IIf(qry_close_month.Bulan='January',qry_close_month.Stock,0)) AS Jan, " & _ "Sum(IIf(qry_close_month.Bulan='February',qry_close_month.Stock,0)) AS Feb, " & _ "Sum(IIf(qry_close_month.Bulan='March',qry_close_month.Stock,0)) AS Mar, " & _ "Sum(IIf(qry_close_month.Bulan='April',qry_close_month.Stock,0)) …
The End.