|
Let my explain what I want with an example:
I want copmare TextBox's value with column ID in Database then if they were equal, modify Qyt column.
int intPosition_ID;<br />
objDataView.Sort = "ID";<br />
intPosition_ID = objDataView.Find(TextBox.Text);<br />
if (intPosition_ID != -1 )<br />
{<br />
}
|
|
|
|
|
You can try this, if you use SQL server 2005
select name from sys.columns
where object_id = (select object_id from sys.tables where name = 'tablename')
Education is not a way to escape poverty — it is a way of fighting it.
|
|
|
|
|
Yeah, Im using SQL server 2005.
Im beginner in ASP.NET and plz explain it more clearly.
I didnt understand your code and I dont know what am I suppose to do !
|
|
|
|
|
if I understood your requirement correctly, you want to compare the textbox value with a table's all columns. For that you can use that query. Sys.Columns is system table which contains all the table's columns. By referring the object_id you can fetch the required column.
select name from sys.columns
where object_id = (select object_id from sys.tables where name = 'customer')
and name = 'LastName'
If you have AdventureWorksLT database you can try this. Let us know whether it solves your problem.
Education is not a way to escape poverty — it is a way of fighting it.
|
|
|
|
|
What you want explain in brief.
Life Is Beautiful
|
|
|
|
|
Hello I need help on Ajax. I have never used it, what I would like to do is to prevent full page loads on basic commands. (such as dropd filling accorfing to the selected value of another dd)
How could I find Toolkits and a basic demonstration of how it works.
Thanks in advance
|
|
|
|
|
Check this link...
http://www.asp.net/ajax/[^]
CodingRocks
ASP.NET,C#.NET Programmer
BANGALORE
"Winners don't do different things. They do things differently. ...
|
|
|
|
|
in your Toolbox there is a Section for Ajax. There is an updatecontrol panel. take your controls and drop them inside this control. Now onselectedindex change of your dropdown, your page will not do a whole page postback again. Contain only controls that you want to do partial postback on them.
Hope it helps
Vuyiswa Maseko,
Few companies that installed computers to reduce the employment of clerks have realized their expectations.... They now need more and more expensive clerks even though they call them "Developers" or "Programmers."
C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vuyiswamaseko.somee.com
http://www.vuyiswamaseko.tiyaneProperties.co.za
vuyiswa@its.co.za
http://www.itsabacus.co.za/itsabacus/
|
|
|
|
|
Thanks for the answer
I tried this via source page, however when I put dropdownlist under update panel, it says dropdown is not a known element for update panel
|
|
|
|
|
can i see the markup(ASPX page) i will tell you what is wrong
Vuyiswa Maseko,
Few companies that installed computers to reduce the employment of clerks have realized their expectations.... They now need more and more expensive clerks even though they call them "Developers" or "Programmers."
C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vuyiswamaseko.somee.com
http://www.vuyiswamaseko.tiyaneProperties.co.za
vuyiswa@its.co.za
http://www.itsabacus.co.za/itsabacus/
|
|
|
|
|
here is my aspx page, could you please let me know how to put dds under a update panel
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>Üye Kayıt</title>
<link href="style.css" rel="stylesheet" type="text/css" />
<script language="javascript" src="func.js"> </script>
</head>
<body>
<form id="form1" runat="server">
<div id="centrallarge">
<h1><img src="images\digersayfa.jpg" alt="photo" /></h1>
</div>
<div id="central">
<div id="leftsub">
<h1 style="height:200px">
<asp:Image ID="Image1" runat="server" Height="141px" Width="170px"
BorderColor="White" BorderStyle="Ridge" BorderWidth="10px" />
</h1>
<p> <asp:FileUpload ID="FileUpload1" runat="server"/> </p>
<p> </p>
</div>
<div id="rightsub">
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
</asp:UpdatePanel>
<table style="width: 100%;">
<tr>
<td>
<asp:Label ID="Label17" runat="server" Font-Names="tahoma" Text="İl"
Font-Size="Small" Font-Bold="True" ForeColor="#CC3300"></asp:Label>
</td>
<td>
<asp:DropDownList ID="dpIl" runat="server" Height="16px" Width="150px"
AutoPostBack="True" onselectedindexchanged="dpIl_SelectedIndexChanged">
</asp:DropDownList>
</td>
</tr>
<tr>
<td>
<asp:Label ID="Label16" runat="server" Font-Names="tahoma" Text="Semt"
Font-Size="Small" Font-Bold="True" ForeColor="#CC3300"></asp:Label>
</td>
<td>
<asp:DropDownList ID="dpSemt" runat="server" Height="16px" Width="150px">
</asp:DropDownList>
</td>
</tr>
<tr>
<td>
<asp:Label ID="Label1" runat="server" Font-Names="tahoma" Text="Ad"
Font-Size="Small" Font-Bold="True" ForeColor="#CC3300"></asp:Label>
</td>
<td>
<asp:TextBox ID="txtAd" runat="server" Font-Names="taho" Height="18px"
Width="150px" MaxLength="50"></asp:TextBox>
<asp:Label ID="Label7" runat="server" Font-Bold="False" ForeColor="#990000"
Text="*"></asp:Label>
</td>
</tr>
<tr>
<td>
<asp:Label ID="Label2" runat="server" Font-Names="tahoma" Text="Soyad"
Font-Size="Small" Font-Bold="True" ForeColor="#CC3300"></asp:Label>
</td>
<td>
<asp:TextBox ID="txtSoyad" runat="server" Height="18px" Width="150px"
MaxLength="25"></asp:TextBox>
<asp:Label ID="Label8" runat="server" Font-Bold="False" ForeColor="#990000"
Text="*"></asp:Label>
</td>
</tr>
<tr>
<td>
<asp:Label ID="Label3" runat="server" Font-Names="tahoma" Text="Kullanıcı Adı"
Font-Size="Small" Font-Bold="True" ForeColor="#CC3300"></asp:Label>
</td>
<td>
<asp:TextBox ID="txtKullaniciad" runat="server" Height="18px" Width="150px"
MaxLength="20"></asp:TextBox>
<asp:Label ID="Label9" runat="server" Font-Bold="False" ForeColor="#990000"
Text="*"></asp:Label>
</td>
</tr>
<tr>
<td>
<asp:Label ID="Label4" runat="server" Font-Names="tahoma" Text="Şifre"
Font-Size="Small" Font-Bold="True" ForeColor="#CC3300"></asp:Label>
</td>
<td>
<asp:TextBox ID="txtSifre" runat="server" Height="19px" Width="150px"
MaxLength="30" TextMode="Password"></asp:TextBox>
<asp:Label ID="Label10" runat="server" Font-Bold="False" ForeColor="#990000"
Text="*"></asp:Label>
</td>
</tr>
<tr>
<td>
<asp:Label ID="Label12" runat="server" Font-Names="tahoma"
Text="Şifre (Tekrar)" Font-Size="Small" Font-Bold="True"
ForeColor="#CC3300"></asp:Label>
</td>
<td>
<asp:TextBox ID="txtSifre2" runat="server" Height="19px" Width="150px"
MaxLength="30" TextMode="Password"></asp:TextBox>
<asp:Label ID="Label13" runat="server" Font-Bold="False" ForeColor="#990000"
Text="*"></asp:Label>
</td>
</tr>
<tr>
<td>
<asp:Label ID="Label5" runat="server" Font-Names="tahoma" Text="Posta Adresi"
Font-Size="Small" Font-Bold="True" ForeColor="#CC3300"></asp:Label>
</td>
<td>
<asp:TextBox ID="txtEmail" runat="server" Height="18px" Width="150px"
MaxLength="50"></asp:TextBox>
<asp:Label ID="Label11" runat="server" Font-Bold="False" ForeColor="#990000"
Text="*"></asp:Label>
</td>
</tr>
<tr>
<td>
<asp:Label ID="Label6" runat="server" Font-Names="tahoma"
Text="Telefon Numarası" Font-Size="Small" Font-Bold="True"
ForeColor="#CC3300"></asp:Label>
</td>
<td>
<asp:TextBox ID="txtAlankodu" runat="server" Height="18px" Width="26px"
MaxLength="3"></asp:TextBox>
<asp:TextBox ID="txtTelefon" runat="server" Height="18px" Width="114px" MaxLength="7"></asp:TextBox>
<asp:Label ID="Label18" runat="server" Font-Names="tahoma"
Text="(212) 1234567" Font-Size="X-Small"></asp:Label>
</td>
</tr>
<tr>
<td>
<asp:Label ID="Label14" runat="server" Font-Names="tahoma" Text="Cep Telefonu"
Font-Size="Small" Font-Bold="True" ForeColor="#CC3300"></asp:Label>
</td>
<td>
<asp:TextBox ID="txtCepAlan" runat="server" Height="18px" Width="26px"
MaxLength="3"></asp:TextBox>
<asp:TextBox ID="txtCepTelefon" runat="server" Height="18px" Width="114px" MaxLength="7"></asp:TextBox>
<asp:Label ID="Label19" runat="server" Font-Names="tahoma"
Text="(532) 1234567" Font-Size="X-Small"></asp:Label>
<asp:Label ID="Label20" runat="server" Font-Bold="False" ForeColor="#990000"
Text="*"></asp:Label>
</td>
</tr>
<tr>
<td>
<asp:Label ID="Label15" runat="server" Font-Names="tahoma" Text="Adres"
Font-Size="Small" Font-Bold="True" ForeColor="#CC3300"></asp:Label>
</td>
<td>
<asp:TextBox ID="txtAdres" runat="server" Height="54px" MaxLength="150"
TextMode="MultiLine" Width="200px"></asp:TextBox>
</td>
</tr>
<tr>
<td>
</td>
<td>
</td>
</tr>
<tr>
<td>
</td>
<td>
<asp:Button ID="Button1" runat="server" Text="Yükle" BackColor="Silver"
BorderColor="White" Font-Bold="True" Font-Names="Tahoma" ForeColor="#FF6600"
Width="150px" onclick="Button1_Click" /> </td>
</tr>
<tr>
<td>
</td>
<td>
</td>
</tr>
<tr>
<td colspan="2">
<asp:Label ID="lblUyari" runat="server" Font-Bold="True"
Font-Names="Century Gothic" ForeColor="Red" Text="Merhaba"
Font-Size="Small"></asp:Label>
</td>
</tr>
</table>
</div>
<div id="footersub">
<ul>
<li><a href="Default.aspx">Anasayfa</a></li>
</ul>
</div>
</div>
</form>
</body>
</html>
|
|
|
|
|
First take ScriptManager on top of your page.After that put your control in update panel.
Life Is Beautiful
|
|
|
|
|
Which version of IDE are you using ? 2005 or 2008. Did you add the Script Manager as a first control.
Education is not a way to escape poverty — it is a way of fighting it.
|
|
|
|
|
<asp:UpdatePanel ID="UpdatePanel1" runat="server" ChildrenAsTriggers="true" >
<ContentTemplate>
<asp:DropDownList ID="dpSemt" runat="server" Height="16px" Width="150px" AutoPostBack="True"
</asp:DropDownList>
</ContentTemplate>
</asp:UpdatePanel>
|
|
|
|
|
|
|
<asp:UpdatePanel ID="UpdatePanel1" runat="server" ChildrenAsTriggers="true" >
<asp:DropDownList ID="dpSemt" runat="server" Height="16px" Width="150px" AutoPostBack="True"
Your first message I opened was displayed like above on my computer, so I thought you made fun of me..
(putting dd under updatepanel)
|
|
|
|
|
O, lol. It was the first post but i did modified it afterwards.
|
|
|
|
|
I see , thanks for helping
|
|
|
|
|
Try this
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default2.aspx.cs" Inherits="Default2" %>
<%@ Register Assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"
Namespace="System.Web.UI" TagPrefix="asp" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>Untitled Page</title>
</head>
<body>
<form id="form1" runat="server">
<div>
<asp:ScriptManager ID="ScriptManager1" runat="server">
</asp:ScriptManager>
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<ContentTemplate>
<img alt="photo" src="images\digersayfa.jpg" /><br />
<h1 style="height: 200px">
<asp:Image ID="Image1" runat="server" BorderColor="White" BorderStyle="Ridge" BorderWidth="10px"
Height="141px" Width="170px" />
</h1>
</div>
<asp:FileUpload ID="FileUpload1" runat="server" /><br />
<table style="width: 100%">
<tr>
<td>
<asp:Label ID="Label17" runat="server" Font-Bold="True" Font-Names="tahoma" Font-Size="Small"
ForeColor="#CC3300" Text="İl"></asp:Label>
</td>
<td style="font-size: 12pt; font-family: Times New Roman">
<asp:DropDownList ID="dpIl" runat="server" AutoPostBack="True" Height="16px" OnSelectedIndexChanged="dpIl_SelectedIndexChanged"
Width="150px">
</asp:DropDownList>
</td>
</tr>
<tr style="font-size: 12pt; font-family: Times New Roman">
<td>
<asp:Label ID="Label16" runat="server" Font-Bold="True" Font-Names="tahoma" Font-Size="Small"
ForeColor="#CC3300" Text="Semt"></asp:Label>
</td>
</tr>
</table>
</ContentTemplate>
</asp:UpdatePanel>
</form>
</body>
</html><
I will be going out for lunch , bye for now be back in 20 min
This will help
Vuyiswa Maseko,
Few companies that installed computers to reduce the employment of clerks have realized their expectations.... They now need more and more expensive clerks even though they call them "Developers" or "Programmers."
C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vuyiswamaseko.somee.com
http://www.vuyiswamaseko.tiyaneProperties.co.za
vuyiswa@its.co.za
http://www.itsabacus.co.za/itsabacus/
|
|
|
|
|
|
You are Welcome
Vuyiswa Maseko,
Few companies that installed computers to reduce the employment of clerks have realized their expectations.... They now need more and more expensive clerks even though they call them "Developers" or "Programmers."
C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vuyiswamaseko.somee.com
http://www.vuyiswamaseko.tiyaneProperties.co.za
vuyiswa@its.co.za
http://www.itsabacus.co.za/itsabacus/
|
|
|
|
|
please any one can help me how i can implement gif animations in my web application and change them randomly with the other as well
harish
|
|
|
|
|
|
How can I set the paper size before printing using System.Drawing.Printing
|
|
|
|