473,769 Members | 2,402 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

passing a value to an event handler from dropdownlist

I've got a command button to submit a value from a dropdown list that should
then filter a SELECT query. I'm simply appending a WHERE colx =
<variableSelect edFromDropdownL ist>. How do I pass this value into the event
handler?

-- MY EVENT HANDLER

Sub RunReport_OnCli ck(sender As Object, e As System.EventArg s)

_sqlStmt = _sqlStmt & " AND colx = '<variableSelec tedFromDropdown List>'"
BindData()
End Sub

-- ON MY WEB FORM
<ASP:Button id="cmdRunRepor t" Text="Run Report" runat="server"
onclick="RunRep ort_OnClick" />

<ASP:dropdownli st id="Provinces" runat="server" Font-Size="8pt"
Width="100px"></ASP:dropdownlis t>
-- MY DATA ACCESS CODE

Sub BindData()
Dim conString As String = "server=server; database=db;uid =un;pwd=pwd;"
Dim myDataSet1 As New DataSet
Dim myDataAdapter1 As New SqlDataAdapter( _sqlStmt, conString)
myDataAdapter1. Fill(myDataSet1 , "Communitie s")
DataGrid2.DataS ource = myDataSet1.Tabl es("Communities ")

Dim myDataSet2 As New DataSet
Dim myDataAdapter2 As New SqlDataAdapter( _sqlStmt2, conString)
myDataAdapter2. Fill(myDataSet2 , "ProvincesT ")
Provinces.Datas ource = myDataSet2.Tabl es("ProvincesT" )
Provinces.DataM ember = "ProvincesT "
Provinces.DataT extField = "clnName"
Provinces.DataV alueField = "clnGUID"
DataGrid2.DataB ind()
Provinces.DataB ind()

End Sub
_____
DC G
Nov 18 '05 #1
5 1805
Change the following
_sqlStmt = _sqlStmt & " AND colx = '<variableSelec tedFromDropdown List>'
t
_sqlStmt = _sqlStmt & " AND colx = '" & mydropdownlist. SelectedItem.Va lue & "'
'your data access code will go her
BindData(

HTH
Suresh

p.s. Sorry i couldn't help you with "Datagrid won't sort" problem. If you still haven't figured it out please create another message for your problem on this NG
----- DC Gringo wrote: ----

I've got a command button to submit a value from a dropdown list that shoul
then filter a SELECT query. I'm simply appending a WHERE colx
<variableSelect edFromDropdownL ist>. How do I pass this value into the even
handler

-- MY EVENT HANDLE

Sub RunReport_OnCli ck(sender As Object, e As System.EventArg s

_sqlStmt = _sqlStmt & " AND colx = '<variableSelec tedFromDropdown List>'
BindData(
End Su

-- ON MY WEB FOR
<ASP:Button id="cmdRunRepor t" Text="Run Report" runat="server
onclick="RunRep ort_OnClick" /><ASP:dropdownl ist id="Provinces" runat="server" Font-Size="8pt
Width="100px"></ASP:dropdownlis t
-- MY DATA ACCESS COD

Sub BindData(
Dim conString As String = "server=server; database=db;uid =un;pwd=pwd;
Dim myDataSet1 As New DataSe
Dim myDataAdapter1 As New SqlDataAdapter( _sqlStmt, conString
myDataAdapter1. Fill(myDataSet1 , "Communitie s"
DataGrid2.DataS ource = myDataSet1.Tabl es("Communities "

Dim myDataSet2 As New DataSe
Dim myDataAdapter2 As New SqlDataAdapter( _sqlStmt2, conString
myDataAdapter2. Fill(myDataSet2 , "ProvincesT "
Provinces.Datas ource = myDataSet2.Tabl es("ProvincesT "
Provinces.DataM ember = "ProvincesT
Provinces.DataT extField = "clnName
Provinces.DataV alueField = "clnGUID
DataGrid2.DataB ind(
Provinces.DataB ind(

End Su
____
DC

Nov 18 '05 #2
Yes, that got rid of my error...but the results are only the first record in
the table everytime...and doesn't match the filter criteria....

_____
DC G
"Suresh" <an*******@disc ussions.microso ft.com> wrote in message
news:12******** *************** ***********@mic rosoft.com...
Change the following
_sqlStmt = _sqlStmt & " AND colx = '<variableSelec tedFromDropdown List>'"
to
_sqlStmt = _sqlStmt & " AND colx = '" & mydropdownlist. SelectedItem.Va lue & "'" 'your data access code will go here
BindData()

HTH,
Suresh.

p.s. Sorry i couldn't help you with "Datagrid won't sort" problem. If you still haven't figured it out please create another message for your problem
on this NG.

----- DC Gringo wrote: -----

I've got a command button to submit a value from a dropdown list that should then filter a SELECT query. I'm simply appending a WHERE colx =
<variableSelect edFromDropdownL ist>. How do I pass this value into the event handler?

-- MY EVENT HANDLER

Sub RunReport_OnCli ck(sender As Object, e As System.EventArg s)

_sqlStmt = _sqlStmt & " AND colx = '<variableSelec tedFromDropdown List>'" BindData()
End Sub

-- ON MY WEB FORM
<ASP:Button id="cmdRunRepor t" Text="Run Report" runat="server"
onclick="RunRep ort_OnClick" /><ASP:dropdownl ist id="Provinces" runat="server" Font-Size="8pt" Width="100px"></ASP:dropdownlis t>
-- MY DATA ACCESS CODE

Sub BindData()
Dim conString As String = "server=server; database=db;uid =un;pwd=pwd;" Dim myDataSet1 As New DataSet
Dim myDataAdapter1 As New SqlDataAdapter( _sqlStmt, conString)
myDataAdapter1. Fill(myDataSet1 , "Communitie s")
DataGrid2.DataS ource = myDataSet1.Tabl es("Communities ")

Dim myDataSet2 As New DataSet
Dim myDataAdapter2 As New SqlDataAdapter( _sqlStmt2, conString) myDataAdapter2. Fill(myDataSet2 , "ProvincesT ")
Provinces.Datas ource = myDataSet2.Tabl es("ProvincesT" )
Provinces.DataM ember = "ProvincesT "
Provinces.DataT extField = "clnName"
Provinces.DataV alueField = "clnGUID"
DataGrid2.DataB ind()
Provinces.DataB ind()

End Sub
_____
DC G

Nov 18 '05 #3
What's your _sqlStmt

Can you also post your Data access code

Suresh

----- DC Gringo wrote: ----

Yes, that got rid of my error...but the results are only the first record i
the table everytime...and doesn't match the filter criteria...

____
DC
"Suresh" <an*******@disc ussions.microso ft.com> wrote in messag
news:12******** *************** ***********@mic rosoft.com..
Change the followin
_sqlStmt = _sqlStmt & " AND colx = '<variableSelec tedFromDropdown List>'
t
_sqlStmt = _sqlStmt & " AND colx = '" & mydropdownlist. SelectedItem.Va lu & "' 'your data access code will go her
BindData(
HTH Suresh
p.s. Sorry i couldn't help you with "Datagrid won't sort" problem. If yo still haven't figured it out please create another message for your proble
on this NG
----- DC Gringo wrote: ----

I've got a command button to submit a value from a dropdown list tha shoul then filter a SELECT query. I'm simply appending a WHERE colx
<variableSelec tedFromDropdown List>. How do I pass this value int the even handler
-- MY EVENT HANDLE
Sub RunReport_OnCli ck(sender As Object, e As System.EventArg s
_sqlStmt = _sqlStmt & " AND colx
'<variableSelec tedFromDropdown List>' BindData( End Su -- ON MY WEB FOR

<ASP:Button id="cmdRunRepor t" Text="Run Report" runat="server
onclick="RunRep ort_OnClick" /><ASP:dropdownl ist id="Provinces

runat="server" Font-Size="8pt Width="100px"></ASP:dropdownlis t>>>> -- MY DATA ACCESS COD
Sub BindData( Dim conString As String

"server=server; database=db;uid =un;pwd=pwd; Dim myDataSet1 As New DataSe
Dim myDataAdapter1 As New SqlDataAdapter( _sqlStmt, conString
myDataAdapter1. Fill(myDataSet1 , "Communitie s"
DataGrid2.DataS ource = myDataSet1.Tabl es("Communities "
Dim myDataSet2 As New DataSe Dim myDataAdapter2 As New SqlDataAdapter( _sqlStmt2

conString myDataAdapter2. Fill(myDataSet2 , "ProvincesT "
Provinces.Datas ource = myDataSet2.Tabl es("ProvincesT "
Provinces.DataM ember = "ProvincesT
Provinces.DataT extField = "clnName
Provinces.DataV alueField = "clnGUID
DataGrid2.DataB ind( Provinces.DataB ind(
End Su
____

DC

Nov 18 '05 #4
Suresh, here's the whole thing:

<%@ Import Namespace="Syst em.Data" %>
<%@ Import Namespace="Syst em.Data.SqlClie nt" %>
<%@ Import Namespace="Syst em.Web.UI.WebCo ntrols" %>
<%@ Import Namespace="Syst em.Web.UI.WebCo ntrols.DropDown List" %>

<%@ Page Language="VB" Debug="true" %>
<script runat="server" language="VB">

Protected _sqlStmt As String = _
"SELECT c1.clnName as Community, s1.clnGUID, s1.clnPriorityC orrectedTC as
Impact, PopulationKeyIn fo = ISNULL(s1.clnPo pulationKeyInfo ,0),
MinedAreaVictim Count = ISNULL(mavc1.Mi nedAreaVictimCo unt,0), nonRecentVictim
= ISNULL(s1.clnVi ctimOldKilled + s1.clnVictimOld Injured, 0), SHACount =
ISNULL(mavc1.SH ACount,0), clnEconomicBase TC =
ISNULL(s1.clnEc onomicBaseTC,'N one specified'), MinDistance =
ISNULL(sha1.Min Distance, 0), VictimAssist = ISNULL(mavc1.Vi ctimAssist,
'No'), clnMADoneTC = ISNULL(s1.clnMA DoneTC,'Unknown ') FROM tblSurvey1 s1
INNER JOIN tblCity c1 ON s1.clnNearestCi tyGUID = c1.clnGUID INNER JOIN
vwMinDistancesT oNearestSHA sha1 ON s1.clnGUID = sha1.clnSurveyG UID LEFT
OUTER JOIN vwMinedAreaVict imCount mavc1 ON s1.clnGUID = mavc1.clnGUID WHERE
s1.clnPriorityC orrectedTC <> 'None'"

Protected _sqlStmt5 As String = _
"SELECT c1.clnName, s1.clnGUID FROM tblSurvey1 s1 INNER JOIN tblCity c1 ON
s1.clnNearestCi tyGUID = c1.clnGUID ORDER BY c1.clnName"
'Protected WithEvents ddlCommunities As
System.Web.UI.W ebControls.Drop DownList

Sub Page_Load(Sourc e As Object, E As EventArgs)
'If Not Page.IsPostBack Then
BindData()
'End If
End Sub

Sub BindData()
Dim conString As String = "server=server; database=db;uid =user;pwd=pwd;"
Dim myDataSet1 As New DataSet
Dim myDataAdapter1 As New SqlDataAdapter( _sqlStmt, conString)
myDataAdapter1. Fill(myDataSet1 , "CommunitiesT1" )
DataGrid2.DataS ource = myDataSet1.Tabl es("Communities T1")


Dim myDataSet5 As New DataSet
Dim myDataAdapter5 As New SqlDataAdapter( _sqlStmt5, conString)
myDataAdapter5. Fill(myDataSet5 , "CommunitiesT2" )
ddlCommunities. DataSource = myDataSet5.Tabl es("Communities T2")
ddlCommunities. DataMember = "Communitie sT2"
ddlCommunities. DataTextField = "clnName"
ddlCommunities. DataValueField = "clnGUID"

DataGrid2.DataB ind()
ddlCommunities. DataBind()

End Sub

Sub SortCommand_OnC lick(Source As Object, E As
DataGridSortCom mandEventArgs)
_sqlStmt = _sqlStmt & " ORDER BY " & E.SortExpressio n
BindData()
End Sub

Sub PageIndexChange d_OnClick(Sourc e As Object, E As
DataGridPageCha ngedEventArgs)
DataGrid2.Curre ntPageIndex = E.NewPageIndex
BindData()
End Sub

Sub RunReport_OnCli ck(sender As Object, e As System.EventArg s)

_sqlStmt = _sqlStmt & " AND s1.clnGUID =
'"+ddlCommuniti es.SelectedItem .Value+"'"

BindData()

End Sub

</script>

<html>
<head>
<title></title>

<style>
.DataGrid {font:x-small Verdana, Arial, sans-serif}
</style>
<LINK rel="stylesheet " href="../Styles.css" type="text/css">
</head>
<body>


<asp:dropdownli st Font-Size="8" id="ddlCommunit ies" runat="server"
Width="100"></asp:dropdownlis t></td>

<ASP:Button id="cmdRunRepor t" Text="Run Report" runat="server"
onclick="RunRep ort_OnClick" />

<asp:DataGrid
AllowCustomPagi ng="false"
AllowPaging="tr ue"
AllowSorting="t rue"
AlternatingItem Style-BackColor="#EFE FEF"
AutoGenerateCol umns="false"
Border="0"
Cellpadding="4"
Cellspacing="0"
CssClass="DataG rid"
DataKeyField="c lnGUID"
Enabled="true"
EnableViewState ="true"
HeaderStyle-BackColor="Blac k"
HeaderStyle-Font-Bold="True"
HeaderStyle-ForeColor="Whit e" id="DataGrid2" runat="server"
ShowFooter="fal se"
OnSortCommand=" SortCommand_OnC lick"
OnPageIndexChan ged="PageIndexC hanged_OnClick"
PageSize="50"
PagerStyle-Mode="NumericPa ges"
PagerStyle-HorizontalAlign ="Right"
ShowHeader="tru e"

<SelectedItemSt yle Font-Bold="True" ForeColor="#663 399"
BackColor="#FFC C66"></SelectedItemSty le>
<ItemStyle Font-Size="8pt" Font-Names="Verdana" ForeColor="#330 099"
BackColor="Whit e"></ItemStyle>
<HeaderStyle Font-Size="8pt" Font-Names="Verdana" Font-Bold="True"
HorizontalAlign ="Center" ForeColor="#FFF FCC"
BackColor="#990 000"></HeaderStyle>
<FooterStyle ForeColor="#330 099" BackColor="#FFF FCC"></FooterStyle>

<Columns>
<asp:HyperLinkC olumn DataNavigateUrl Field="Communit y"
DataNavigateUrl FormatString="c lnGUID" DataTextField=" Community"
Visible="true" NavigateUrl="ht tp://{cgi.server_nam e}/c={clnGUID}"
SortExpression= "Community"
HeaderText="Com munity" text="Community " runat="server">
<HeaderStyle HorizontalAlign ="Left"></HeaderStyle>
<ItemStyle HorizontalAlign ="Left"></ItemStyle>
</asp:HyperLinkCo lumn>
<asp:BoundColum n DataField="Impa ct" SortExpression= "Impact"
HeaderText="Imp act"></asp:BoundColumn >
<asp:BoundColum n DataField="Popu lationKeyInfo"
SortExpression= "PopulationKeyI nfo" HeaderText="Pop ulation<br>Key
Info"></asp:BoundColumn >
<asp:BoundColum n DataField="Mine dAreaVictimCoun t"
SortExpression= "MinedAreaVicti mCount"
HeaderText="Rec ent<br>Victims" ></asp:BoundColumn >
<asp:BoundColum n DataField="SHAC ount" SortExpression= "SHACount"
HeaderText="No. of<br>SHA's"></asp:BoundColumn >
<asp:BoundColum n DataField="clnE conomicBaseTC"
SortExpression= "clnEconomicBas eTC"
HeaderText="Eco nomic<br>Base"> </asp:BoundColumn >
<asp:BoundColum n DataField="clnM ADoneTC" SortExpression= "clnMADoneT C"
HeaderText="Min e Risk<br>Educati on"></asp:BoundColumn >
<asp:BoundColum n DataField="Vict imAssist" SortExpression= "VictimAssi st"
HeaderText="Vic tim<br>Assist"> </asp:BoundColumn >
<asp:BoundColum n DataField="MinD istance" SortExpression= "MinDistanc e"
HeaderText="Min Distance<br>to SHA"></asp:BoundColumn >
</columns>
<PagerStyle HorizontalAlign ="Center" ForeColor="#330 099"
Position="TopAn dBottom" BackColor="#FFF FCC"
Mode="NumericPa ges"></PagerStyle>
</asp:DataGrid>

</form>
</body>
</html>
"Suresh" <an*******@disc ussions.microso ft.com> wrote in message
news:6E******** *************** ***********@mic rosoft.com... What's your _sqlStmt?

Can you also post your Data access code?

Suresh.

----- DC Gringo wrote: -----

Yes, that got rid of my error...but the results are only the first record in the table everytime...and doesn't match the filter criteria....

_____
DC G
"Suresh" <an*******@disc ussions.microso ft.com> wrote in message
news:12******** *************** ***********@mic rosoft.com...
> Change the following
> _sqlStmt = _sqlStmt & " AND colx = '<variableSelec tedFromDropdown List>'"
> to
> _sqlStmt = _sqlStmt & " AND colx = '" & mydropdownlist. SelectedItem.Va lue
& "'"
> 'your data access code will go here
> BindData()
>> HTH, > Suresh.
>> p.s. Sorry i couldn't help you with "Datagrid won't sort" problem. If you still haven't figured it out please create another message for your problem on this NG. >>> ----- DC Gringo wrote: -----
>> I've got a command button to submit a value from a dropdown
list that
should
> then filter a SELECT query. I'm simply appending a WHERE colx

= ><variableSelec tedFromDropdown List>. How do I pass this value into

the event
> handler?
>> -- MY EVENT HANDLER
>> Sub RunReport_OnCli ck(sender As Object, e As
System.EventArg s) >> _sqlStmt = _sqlStmt & " AND colx =

'<variableSelec tedFromDropdown List>'"
> BindData()
>>> End Sub
>> -- ON MY WEB FORM

><ASP:Button id="cmdRunRepor t" Text="Run Report" runat="server"
> onclick="RunRep ort_OnClick" /><ASP:dropdownl ist id="Provinces"

runat="server" Font-Size="8pt"
> Width="100px"></ASP:dropdownlis t>>>> -- MY DATA ACCESS

CODE
>> Sub BindData()

> Dim conString As String =

"server=server; database=db;uid =un;pwd=pwd;"
> Dim myDataSet1 As New DataSet
> Dim myDataAdapter1 As New SqlDataAdapter( _sqlStmt,

conString) > myDataAdapter1. Fill(myDataSet1 , "Communitie s")
> DataGrid2.DataS ource = myDataSet1.Tabl es("Communities ")
>> Dim myDataSet2 As New DataSet

> Dim myDataAdapter2 As New SqlDataAdapter( _sqlStmt2,

conString)
> myDataAdapter2. Fill(myDataSet2 , "ProvincesT ")
> Provinces.Datas ource = myDataSet2.Tabl es("ProvincesT" )
> Provinces.DataM ember = "ProvincesT "
> Provinces.DataT extField = "clnName"
> Provinces.DataV alueField = "clnGUID"
>>> DataGrid2.DataB ind()

> Provinces.DataB ind()
>> End Sub
>>> _____

> DC G
>>>

Nov 18 '05 #5
Everything looks ok. The query maybe returning the wrong data

Put a break point on the following line
Dim myDataAdapter1 As New SqlDataAdapter( _sqlStmt, conString

After the report button click event retrieve what's in the _sqlStmt string variable. You should be able to get that text from Immediate Window. Copy it over to SQL query analyzer, execute it and see what you get

Suresh

----- DC Gringo wrote: ----

Suresh, here's the whole thing

<%@ Import Namespace="Syst em.Data" %><%@ Import Namespace="Syst em.Data.SqlClie nt" %><%@ Import Namespace="Syst em.Web.UI.WebCo ntrols" %><%@ Import Namespace="Syst em.Web.UI.WebCo ntrols.DropDown List" %><%@ Page Language="VB" Debug="true" %><script runat="server" language="VB"

Protected _sqlStmt As String =
"SELECT c1.clnName as Community, s1.clnGUID, s1.clnPriorityC orrectedTC a
Impact, PopulationKeyIn fo = ISNULL(s1.clnPo pulationKeyInfo ,0)
MinedAreaVictim Count = ISNULL(mavc1.Mi nedAreaVictimCo unt,0), nonRecentVicti
= ISNULL(s1.clnVi ctimOldKilled + s1.clnVictimOld Injured, 0), SHACount
ISNULL(mavc1.SH ACount,0), clnEconomicBase TC
ISNULL(s1.clnEc onomicBaseTC,'N one specified'), MinDistance
ISNULL(sha1.Min Distance, 0), VictimAssist = ISNULL(mavc1.Vi ctimAssist
'No'), clnMADoneTC = ISNULL(s1.clnMA DoneTC,'Unknown ') FROM tblSurvey1 s
INNER JOIN tblCity c1 ON s1.clnNearestCi tyGUID = c1.clnGUID INNER JOI
vwMinDistancesT oNearestSHA sha1 ON s1.clnGUID = sha1.clnSurveyG UID LEF
OUTER JOIN vwMinedAreaVict imCount mavc1 ON s1.clnGUID = mavc1.clnGUID WHER
s1.clnPriorityC orrectedTC <> 'None'

Protected _sqlStmt5 As String =
"SELECT c1.clnName, s1.clnGUID FROM tblSurvey1 s1 INNER JOIN tblCity c1 O
s1.clnNearestCi tyGUID = c1.clnGUID ORDER BY c1.clnName
'Protected WithEvents ddlCommunities A
System.Web.UI.W ebControls.Drop DownLis

Sub Page_Load(Sourc e As Object, E As EventArgs
'If Not Page.IsPostBack The
BindData(
'End I
End Su

Sub BindData(
Dim conString As String = "server=server; database=db;uid =user;pwd=pwd;
Dim myDataSet1 As New DataSe
Dim myDataAdapter1 As New SqlDataAdapter( _sqlStmt, conString
myDataAdapter1. Fill(myDataSet1 , "Communitie sT1"
DataGrid2.DataS ource = myDataSet1.Tabl es("Communities T1"


Dim myDataSet5 As New DataSe
Dim myDataAdapter5 As New SqlDataAdapter( _sqlStmt5, conString
myDataAdapter5. Fill(myDataSet5 , "Communitie sT2"
ddlCommunities. DataSource = myDataSet5.Tabl es("Communities T2"
ddlCommunities. DataMember = "Communitie sT2
ddlCommunities. DataTextField = "clnName
ddlCommunities. DataValueField = "clnGUID

DataGrid2.DataB ind(
ddlCommunities. DataBind(

End Su

Sub SortCommand_OnC lick(Source As Object, E A
DataGridSortCom mandEventArgs
_sqlStmt = _sqlStmt & " ORDER BY " & E.SortExpressio
BindData(
End Su

Sub PageIndexChange d_OnClick(Sourc e As Object, E A
DataGridPageCha ngedEventArgs
DataGrid2.Curre ntPageIndex = E.NewPageInde
BindData(
End Su

Sub RunReport_OnCli ck(sender As Object, e As System.EventArg s

_sqlStmt = _sqlStmt & " AND s1.clnGUID
'"+ddlCommuniti es.SelectedItem .Value+"'

BindData(

End Su

</script><html><h ead><title></title><style
.DataGrid {font:x-small Verdana, Arial, sans-serif
</style><LINK rel="stylesheet " href="../Styles.css" type="text/css"></head><body><asp :dropdownlist Font-Size="8" id="ddlCommunit ies" runat="server
Width="100"></asp:dropdownlis t></td><ASP:Button id="cmdRunRepor t" Text="Run Report" runat="server
onclick="RunRep ort_OnClick" /><asp:DataGri
AllowCustomPagi ng="false
AllowPaging="tr ue
AllowSorting="t rue
AlternatingItem Style-BackColor="#EFE FEF
AutoGenerateCol umns="false"
Border="0"
Cellpadding="4"
Cellspacing="0"
CssClass="DataG rid"
DataKeyField="c lnGUID"
Enabled="true"
EnableViewState ="true"
HeaderStyle-BackColor="Blac k"
HeaderStyle-Font-Bold="True"
HeaderStyle-ForeColor="Whit e" id="DataGrid2" runat="server"
ShowFooter="fal se"
OnSortCommand=" SortCommand_OnC lick"
OnPageIndexChan ged="PageIndexC hanged_OnClick"
PageSize="50"
PagerStyle-Mode="NumericPa ges"
PagerStyle-HorizontalAlign ="Right"
ShowHeader="tru e"
<SelectedItemS tyle Font-Bold="True" ForeColor="#663 399"

BackColor="#FFC C66"></SelectedItemSty le><ItemStyle Font-Size="8pt" Font-Names="Verdana" ForeColor="#330 099"
BackColor="Whit e"></ItemStyle><Head erStyle Font-Size="8pt" Font-Names="Verdana" Font-Bold="True"
HorizontalAlign ="Center" ForeColor="#FFF FCC"
BackColor="#990 000"></HeaderStyle><Fo oterStyle ForeColor="#330 099" BackColor="#FFF FCC"></FooterStyle><Co lumns><asp:Hype rLinkColumn DataNavigateUrl Field="Communit y"
DataNavigateUrl FormatString="c lnGUID" DataTextField=" Community"
Visible="true" NavigateUrl="ht tp://{cgi.server_nam e}/c={clnGUID}"
SortExpression= "Community"
HeaderText="Com munity" text="Community " runat="server"> <HeaderStyle HorizontalAlign ="Left"></HeaderStyle><It emStyle HorizontalAlign ="Left"></ItemStyle></asp:HyperLinkCo lumn><asp:Bound Column DataField="Impa ct" SortExpression= "Impact"
HeaderText="Imp act"></asp:BoundColumn ><asp:BoundColu mn DataField="Popu lationKeyInfo"
SortExpression= "PopulationKeyI nfo" HeaderText="Pop ulation<br>Key
Info"></asp:BoundColumn ><asp:BoundColu mn DataField="Mine dAreaVictimCoun t"
SortExpression= "MinedAreaVicti mCount"
HeaderText="Rec ent<br>Victims" ></asp:BoundColumn ><asp:BoundColu mn DataField="SHAC ount" SortExpression= "SHACount"
HeaderText="No. of<br>SHA's"></asp:BoundColumn ><asp:BoundColu mn DataField="clnE conomicBaseTC"
SortExpression= "clnEconomicBas eTC"
HeaderText="Eco nomic<br>Base"> </asp:BoundColumn ><asp:BoundColu mn DataField="clnM ADoneTC" SortExpression= "clnMADoneT C"
HeaderText="Min e Risk<br>Educati on"></asp:BoundColumn ><asp:BoundColu mn DataField="Vict imAssist" SortExpression= "VictimAssi st"
HeaderText="Vic tim<br>Assist"> </asp:BoundColumn ><asp:BoundColu mn DataField="MinD istance" SortExpression= "MinDistanc e"
HeaderText="Min Distance<br>to SHA"></asp:BoundColumn ></columns><PagerS tyle HorizontalAlign ="Center" ForeColor="#330 099"
Position="TopAn dBottom" BackColor="#FFF FCC"
Mode="NumericPa ges"></PagerStyle></asp:DataGrid></form></body></html>
Nov 18 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
49582
by: Pavils Jurjans | last post by:
Hallo, I have been programming for restricted environments where Internet Explorer is a standard, so I haven't stumbled upon this problem until now, when I need to write a DOM-compatible code. The question is about best practices for passing parameters to an event function. I have, say, the following HTML:
1
4374
by: Lucifer | last post by:
Hi I am trying to raise a bubble event. I have a dropdownlist and a datalist in a datalist. I want to use the postback from the dropdownlist to rebind the nested datalist. But i need the event to be a datalist Command so i have access to e.item for the main datalist
5
1973
by: csgraham74 | last post by:
Hi guys, I posted regarding this issue the other day but i still dont have an answer to my problem. Basically i have imported asp.net pages from dreamweaver into visual studio. Ive added a few controls that ive copied in from another asp.net page that i built within visual studio. The problem is that the asp:button does not fir an event and therefore my code behind it wont work. The page load event is firing correctly so i think the...
5
1836
by: glenn | last post by:
Hi folks, The problem I have is that a query string works if hard-coded but if I pass a variable to it, it does not work as shown here. This works: querystring="SELECT * FROM USERS WHERE CNAME = 'MICROSOFT'" This does not work: Dim var as string
1
4117
by: Kevin Blount | last post by:
I have a test script right now that I'm fighting with. The idea is to "simply" have an aspx page with 3 panels, to show 3 "different" forms and then a 4th panel to show the results of processing these forms. One of the panels will contain DropDownLists, who's items are dynamically added in terms of text and values. For example, one of these lists will be languages. I want to list presented in the language of the person viewing it, i.e....
4
2383
by: simon | last post by:
hi, I would like to separate my javascript completely from my xhtml. in the end there should be only <script type="text/javascript" src="javalib.js"></script> in the head-tag to my javascript. Because I want to use some ajax-requests and other javascript-functions on my xhtml, I need to dynamically add event handlers to any possible dom-elements. All solutions I found so fare are for specific, pre-known
10
13054
by: Janus | last post by:
Hi, Is there a way to pass arguments to the callback function used inside an addEventListener? I see that I can only list the name of the callback function. For eg, I use this: var boldLink=document.getElementById('cmtbold');
0
2436
by: landesjoe | last post by:
Hi, here's my problem in short: Text boxes in gridview don't seem to hold their value if the column's .Visible property is changed back and forth. I've got a form with a gridview populated from a data view (which in turn is loaded from a manually setup DataTable for testing purposes). One of the columns in the grid is a checkbox that's tied to an event handler that'll change the .Visible property of a column with a text box. That text...
10
1545
by: Dan | last post by:
Hi, I create 5 dropdownlist in code-behind. I want to insert their selectedvalues in a table by making a string separated with ":" I can get their selecedvalues but i'm stuck when i want to execute the insert. The error is "name dd is not declared" (in line: selvalue = selvalue & Session("dd" & dd.id) & ":" Any idea how to solve this?
0
9423
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10210
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10043
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9861
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7406
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6672
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5298
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
3956
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3561
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.