Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Datagrid Control > MXDataGrid Sorting Probelms

Reply
Thread Tools

MXDataGrid Sorting Probelms

 
 
Steve Bishop
Guest
Posts: n/a
 
      03-04-2004
My mxDataGrid doesn't sort, even if I set the properties to sort. When I
drag a SQL table onto my form, it works fine, but I'm working with ODBC
databases and it's not working. Paging works good, but not sorting. Can
someone put me in the right direction? Thanks.

<%@ Page Language="vb" %>
<%@ Register TagPrefix="wmx"
Namespace="Microsoft.Matrix.Framework.Web.UI"
Assembly="Microsoft.Matrix.Framework, Version=0.6.0.0, Culture=neutral,
PublicKeyToken=6f763c9966660626" %>
<%@ import Namespace="System.Data" %>
<%@ import Namespace="Microsoft.Data.ODBC" %>
<script runat="server">

Sub Page_Load(source As Object, E As EventArgs)

Dim cn as OdbcConnection
cn = New
OdbcConnection("dsn=SOTAMAS90AUTO;uid=sys;pwd=Rang ers;")
Dim mystring As String = "Select * FROM AR1_CustomerMaster"

Dim ObjAdapter As New OdbcDataAdapter(mystring, cn)

Dim ObjDataSet As New DataSet()

ObjAdapter.Fill(objDataSet, "dtAR1")

dgAR1.DataSource = objDataSet.Tables("dtAR1")
dgAR1.DataBind()

End Sub

</script>
<html>
<head>
</head>
<body>
<h3><font color="#000040">Bring in AR1 </font>
</h3>
<p>
</p>
<form runat="server">
<wmx:MxDataGrid id="dgAR1" runat="server" Width="700px"
AutoGenerateFields="False" Height="50px" HorizontalAlign="Center"
ForeColor="Navy" CellPadding="5" ShowFooter="True" BackColor="AliceBlue"
AllowSorting="True" AllowPaging="True">
<AlternatingItemStyle forecolor="White"
backcolor="Navy"></AlternatingItemStyle>
<FooterStyle backcolor="Navy"></FooterStyle>
<HeaderStyle forecolor="White"
backcolor="Navy"></HeaderStyle>
<Fields>
<wmx:BoundField DataField="CustomerNumber"
HeaderText="Customer No."></wmx:BoundField>
<wmx:BoundField DataField="CustomerName"
HeaderText="Customer Name"></wmx:BoundField>
<wmx:BoundField DataField="PhoneNumber"
HeaderText="Phone"></wmx:BoundField>
<wmx:BoundField DataField="EmailAddress"
HeaderText="Email"></wmx:BoundField>
</Fields>
</wmx:MxDataGrid>
<!-- Insert content here -->
</form>
</body>
</html>




*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
post & put probelms with restclient Andrew Nisbet Ruby 0 02-24-2009 11:58 PM
Probelms Converting a Cisco 7940 from SCCP to SIP Big Phil UK VOIP 3 05-22-2007 04:28 PM
X-Privat Posting Probelms. ~misfit~ NZ Computing 15 05-05-2007 11:43 PM
E-mail Probelms angela stirland Computer Support 3 02-09-2004 11:31 PM
hiperlink in a mxdatagrid Cristhian Massa Medina ASP .Net 0 01-07-2004 06:05 PM



Advertisments