|
-
Jan 30th, 2010, 09:24 PM
#1
Thread Starter
Member
nid help using datagrid
hi, i got a table with this fields
employee_name salary
i know how to display records of a specific employee, now i want to get his/her total salary based on his/her number of records
thx in advance
-
Jan 31st, 2010, 02:11 AM
#2
Re: nid help using datagrid
If my post was helpful to you, then express your gratitude using Rate this Post. 
And if your problem is SOLVED, then please Mark the Thread as RESOLVED (see it in action - video)
My system: AMD FX 6100, Gigabyte Motherboard, 8 GB Crossair Vengance, Cooler Master 450W Thunder PSU, 1.4 TB HDD, 18.5" TFT(Wide), Antec V1 Cabinet
Social Group: VBForums - Developers from India
Skills: PHP, MySQL, jQuery, VB.Net, Photoshop, CodeIgniter, Bootstrap,...
-
Jan 31st, 2010, 02:39 AM
#3
Thread Starter
Member
Re: nid help using datagrid
Private Sub Command1_Click()
Adodc1.RecordSource = "SELECT SUM(salary) AS totalsalary FROM Table2;"
Adodc1.Refresh
End Sub
how do i pass the value to a variable?
-
Jan 31st, 2010, 09:57 AM
#4
Re: nid help using datagrid
Perhaps something like:
Code:
Dim TS
TS = Adodc1.RecordSet.Fields(0).Value
-
Jan 31st, 2010, 10:47 AM
#5
Re: nid help using datagrid
Thread moved to 'Database Development' forum (the 'VB6' forum is only meant for questions which don't fit in more specific forums)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|