Small width layout Medium width layout Maximum width layout Small text Medium text Large text
     Search
Downloads Downloads Directory Directory Forums Forums Forge Forge Blogs Blogs        Marketplace Marketplace Careers Program Careers
Community › Forums Register  |  

$4.95 Windows Hosting at Webhost4life.com
  Ads  
Engage Software - Training Partner for DotNetNuke
 


  Sponsors  

Meet Our Sponsors

FCKeditor Project
Salaro -- Skins and more
OnyakTech
CrystalTech Web Hosting™
Webhost4life, specialists in DNN hosting
Mad Development is a full service interactive agency focusing on the merge of design, technology, e-commerce, and affiliate marketing by providing total website solutions.
 


DotNetNuke Forums
 
  Forum  General DotNetN...  Extend It! ( Pr...  populating a datagrid...
Previous Previous
 
Next Next
New Post 2/24/2006 9:11 AM
User is offline Rob Morrow
23 posts
www.deviant-tuning.com
10th Ranked


populating a datagrid... 
greetings, all. i'm a bit new to the module development area, so please be patient with me. lol, i may ask a lot of dumb questions. i'm attempting to populate a datagrid based on a stored procedure that is ran with values pulled from a dropdown list. when i run the stored proc with values, it pulls back the information that i expect it to. but when i attempt it through my module, it simply shows me the grid headers and no data. i'll show the flow from the beginning...

1. i tell the datagrid to populate with data pulled from the datasource which uses two values to run the query: bankid (pulled from the dropdown) and userid...
dgTransactions.DataSource = blah.BlahBlah.BlahBlahController.GetTransByBankID(Me.ddlBankName.SelectedValue, UserId)

2. the following function is called in the BlahBlahController.vb file...

Public Shared Function GetTransByBankID(ByVal bankId As Integer, ByVal userId As Integer) As DataSet
Return DataProvider.Instance.GetTransByBankId(bankId, userId)
End Function

3. this of course rolls over to the DataProvider.vb where the following is seen...

Public MustOverride Function GetTransByBankId(ByVal BankId As Integer, ByVal UserId As Integer) As DataSet

4. the override is done via the SqlDataProvider.vb, which is like so...

Public Overrides Function GetTransByBankId(ByVal bankId As Integer, ByVal userId As Integer) As DataSet
Return CType(SqlHelper.ExecuteDataset(ConnectionString, DatabaseOwner & ObjectQualifier & "nuv_AccountActivityGetTransByBankID", bankId, userId), DataSet)
End Function

i know this is asking a lot, but does anyone know what i'm doing wrong? i'm kinda new to the whole "data provider" thing, but i've been grasping quite a bit of it lately. i just keep getting stuck on little things like this. thanks in advance...
 
New Post 3/4/2006 12:33 PM
User is offline Stefan Kamphuis
319 posts
www.superska.net
8th Ranked






Re: populating a datagrid... 
Hmmm, have you set the dataMember proerty of the DataGrid to the name of the Table within the dataset? I don't know for sure if .net automaticly uses the first table if there's only one present in the dataset.

You might want to try this (assuming there's only one table in the dataset:
dgTransactions.DataSource = blah.BlahBlah.BlahBlahController.GetTransByBankID(Me.ddlBankName.SelectedValue, UserId).Tables(0)


Hope this helps.

Greetz,
Stefan Kamphuis
 
Previous Previous
 
Next Next
  Forum  General DotNetN...  Extend It! ( Pr...  populating a datagrid...
 


Forum Policy

These Discussion Forums are dedicated to the discussion of the DotNetNuke Web Application Framework.

For the benefit of the community and to protect the integrity of the project, please observe the following posting guidelines:

1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DotNetNuke.
2. Discussion or promotion of DotNetNuke product releases under a different brand name are strictly prohibited.
3. No Flaming or Trolling.
4. No Profanity, Racism, or Prejudice.
5. Site Moderators have the final word on approving/removing a thread or post or comment.
6. English language posting only, please.

 


Aricie
Aricie is one of the French pioneers and experts in DotNetNuke technology.
www.aricie.com
AFUEGO!
Looking for Free DNN Hosting?
www.AFUEGO.com
Code 5 Systems, LLC.
The DNN Missing Link: A Form Module. Form Master 1.6 is an intuitive Form Creation Module at a great price. Quality Custom Module development, and DNN consulting services.
www.code5systems.com

DotNetNuke Corporation   Terms Of Use  Privacy Statement
DotNetNuke®, DNN®, and the DotNetNuke logo are trademarks of DotNetNuke Corporation
Hosted by MaximumASP