Click here to Skip to main content
16,011,611 members
Home / Discussions / Visual Basic
   

Visual Basic

 
QuestionReport from SQL Server with Vb.NET Pin
mhaneefa4-Oct-07 9:41
mhaneefa4-Oct-07 9:41 
AnswerRe: Report from SQL Server with Vb.NET Pin
Johan Hakkesteegt5-Oct-07 0:16
Johan Hakkesteegt5-Oct-07 0:16 
GeneralRe: Report from SQL Server with Vb.NET Pin
mhaneefa5-Oct-07 9:53
mhaneefa5-Oct-07 9:53 
QuestionGet Access() [modified] Pin
zchwllms4-Oct-07 9:28
zchwllms4-Oct-07 9:28 
AnswerRe: Get Access() Pin
balaji baskar4-Oct-07 13:24
balaji baskar4-Oct-07 13:24 
QuestionArray Sort Pin
Scott_Roberts4-Oct-07 8:51
Scott_Roberts4-Oct-07 8:51 
AnswerRe: Array Sort Pin
nlarson114-Oct-07 10:29
nlarson114-Oct-07 10:29 
QuestionSelecting multipe parameters Pin
TAK784-Oct-07 7:24
TAK784-Oct-07 7:24 
I'm trying to pass multiple DataKeynames after a selection is made in the Gridview, and to view them in a DataList where the selection matches them. Right now it will only display the first selected parameter (jacket).
Here is my code:

<asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" BackColor="White" Visible="false"
BorderColor="#999999" BorderStyle="Solid" BorderWidth="1px" CellPadding="3" DataKeyNames="jacket, closure, shielding" ForeColor="Black" GridLines="Vertical" Width="750px" OnPageIndexChanging="gridViewPublishers_PageIndexChanging" OnSorting="gridViewPublishers_Sorting"
AllowPaging="True" PageSize="20" AllowSorting="True" PagerSettings-Mode="NumericFirstLast">
<FooterStyle BackColor="#CCCCCC" />
<Columns>
<asp:CommandField ItemStyle-Width="70" ShowSelectButton="True" />
<asp:BoundField ItemStyle-Width="130" DataField="partnumber" HeaderText="Partnumber" ReadOnly="True" SortExpression="partnumber" />
<asp:BoundField ItemStyle-Width="100" DataField="jacket" HeaderText="Jacket" SortExpression="jacket" />
<asp:BoundField ItemStyle-Width="220" DataField="closure" HeaderText="Closure" SortExpression="Closure" />
<asp:BoundField ItemStyle-Width="110" DataField="shape" HeaderText="Shape" SortExpression="shape" />
<asp:BoundField ItemStyle-Width="130" DataField="shielding" HeaderText="Shielding" SortExpression="Shielding" />
</Columns>
<SelectedRowStyle BackColor="#7c7979" Font-Bold="True" ForeColor="White" />
<PagerStyle BackColor="#999999" ForeColor="Black" HorizontalAlign="Center" />
<HeaderStyle BackColor="Black" Font-Bold="True" ForeColor="White" />
<AlternatingRowStyle BackColor="#CCCCCC" />
<PagerSettings Mode="NumericFirstLast" />
</asp:GridView><br /><br />



<asp:DataList ID="DataList1" runat="server" BackColor="#1679d5" BorderColor="#999999"
BorderStyle="Solid" BorderWidth="1px" CellPadding="3"
ForeColor="White" GridLines="Vertical" DataSourceID="SqlDataSource1" Visible="false">
<FooterStyle BackColor="#CCCCCC" />
<SelectedItemStyle BackColor="Blue" Font-Bold="False" ForeColor="White" />
<ItemTemplate>
<table>
<tr>
<td style="width:120px; font-weight:bold;">
<asp:Label ID="materialLabel" runat="server" Text='<%# Eval("material") %>' />
</td>
<td style="width:450px;">
<asp:Label ID="Label" runat="server" TabIndex="1" Text='<%# Eval("marketing_tagline") %>' />
</td>
<td style="width:150px; text-align:center;">
<div class="SearchDataLink">
<asp:HyperLink ID="HyperLink1" runat="server" NavigateUrl='<%# Eval("material", "dataSheet.aspx?id={0}") %>' TabIndex="2" Target="_blank" Text="View datasheet" />
</div>
</td>
</tr>
</table>
</ItemTemplate>
<AlternatingItemStyle BorderWidth="1" />
<HeaderStyle BackColor="Black" Font-Bold="True" ForeColor="White" />
</asp:DataList>


<asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:ZippertubingConnectionString %>" SelectCommand="SELECT * FROM [ProductVerbage] WHERE ([material] = @jacket) OR ([material] = @closure) OR ([material] = @shielding) " >
<SelectParameters>
<asp:ControlParameter ControlID="GridView1" Name="jacket" PropertyName="SelectedValue" Type="String" />
<asp:ControlParameter ControlID="GridView1" Name="closure" PropertyName="SelectedValue" Type="String" />
<asp:ControlParameter ControlID="GridView1" Name="shielding" PropertyName="SelectedValue" Type="String" />
</SelectParameters>
</asp:SqlDataSource>

AnswerRe: Selecting multipe parameters Pin
Dave Kreskowiak5-Oct-07 1:45
mveDave Kreskowiak5-Oct-07 1:45 
QuestionSMO Sample Pin
Naderrafiee4-Oct-07 6:08
Naderrafiee4-Oct-07 6:08 
AnswerRe: SMO Sample Pin
Dave Kreskowiak5-Oct-07 1:44
mveDave Kreskowiak5-Oct-07 1:44 
QuestionVB/ASP problem - HTML strings in ASP Pin
Dmitry Khudorozhkov4-Oct-07 5:51
Dmitry Khudorozhkov4-Oct-07 5:51 
AnswerRe: VB/ASP problem - HTML strings in ASP Pin
nlarson114-Oct-07 7:45
nlarson114-Oct-07 7:45 
GeneralRe: VB/ASP problem - HTML strings in ASP Pin
Dmitry Khudorozhkov4-Oct-07 7:55
Dmitry Khudorozhkov4-Oct-07 7:55 
GeneralRe: VB/ASP problem - HTML strings in ASP Pin
nlarson114-Oct-07 8:00
nlarson114-Oct-07 8:00 
GeneralRe: VB/ASP problem - HTML strings in ASP Pin
Dmitry Khudorozhkov4-Oct-07 8:05
Dmitry Khudorozhkov4-Oct-07 8:05 
GeneralRe: VB/ASP problem - HTML strings in ASP Pin
nlarson114-Oct-07 8:11
nlarson114-Oct-07 8:11 
Questionreport generation using dataenvironment Pin
devendra20uk4-Oct-07 2:48
devendra20uk4-Oct-07 2:48 
AnswerRe: report generation using dataenvironment Pin
mhaneefa4-Oct-07 9:45
mhaneefa4-Oct-07 9:45 
QuestionUpdating a datagridview with the value selected in a combo box Pin
Mr Oizo4-Oct-07 2:27
Mr Oizo4-Oct-07 2:27 
QuestionTo remove xmlns value from Xml file Pin
Sam.M4-Oct-07 1:39
Sam.M4-Oct-07 1:39 
AnswerRe: To remove xmlns value from Xml file Pin
Dave Kreskowiak4-Oct-07 4:08
mveDave Kreskowiak4-Oct-07 4:08 
AnswerRe: To remove xmlns value from Xml file Pin
richardw484-Oct-07 5:00
richardw484-Oct-07 5:00 
GeneralRe: To remove xmlns value from Xml file Pin
ALI_SHAH9-Dec-09 5:31
ALI_SHAH9-Dec-09 5:31 
QuestionCurrent path of the crystal report, Pin
ShuklaGirish4-Oct-07 0:41
ShuklaGirish4-Oct-07 0:41 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.