Click here to Skip to main content
15,886,919 members
Home / Discussions / ASP.NET
   

ASP.NET

 
Questioni have issue for calculating Total in Grid control of ASP.net Pin
bablug30-Jul-15 2:25
bablug30-Jul-15 2:25 
AnswerRe: i have issue for calculating Total in Grid control of ASP.net Pin
Richard Deeming30-Jul-15 7:43
mveRichard Deeming30-Jul-15 7:43 
AnswerRe: i have issue for calculating Total in Grid control of ASP.net Pin
User 41802543-Aug-15 10:17
User 41802543-Aug-15 10:17 
QuestionOnly authenticate user can access the authenticated page otherwise redirect to login page uaing ASP.NET webfroms Pin
Member 1115728828-Jul-15 21:40
Member 1115728828-Jul-15 21:40 
AnswerRe: Only authenticate user can access the authenticated page otherwise redirect to login page uaing ASP.NET webfroms Pin
Wendelius28-Jul-15 21:47
mentorWendelius28-Jul-15 21:47 
Questioncalculate the weighted average Pin
jkirkerx27-Jul-15 13:43
professionaljkirkerx27-Jul-15 13:43 
AnswerRe: calculate the weighted average Pin
Kenneth Haugland28-Jul-15 1:19
mvaKenneth Haugland28-Jul-15 1:19 
AnswerRe: calculate the weighted average Pin
deepankarbhatnagar28-Jul-15 2:14
professionaldeepankarbhatnagar28-Jul-15 2:14 
Hi, you can get the average by doing this:

m_avgMarkup += sCIR(idx).FMARGIN_PERCENT /idx

below is the whole code,

SQL
If (sCIR.Length > 0) Then
                    For idx As Integer = 0 To sCIR.Length - 1

                        rs_DataRow = rs_Table.NewRow()
                        rs_DataRow(0) = sCIR(idx).FITEMNO
                        rs_DataRow(1) = sCIR(idx).FDESCRIPT
                        rs_DataRow(2) = sCIR(idx).FSHIPQTY
                        rs_DataRow(3) = sCIR(idx).FCOST
                        rs_DataRow(4) = sCIR(idx).FPRICE
                        rs_DataRow(5) = sCIR(idx).FAMOUNT
                        rs_DataRow(6) = sCIR(idx).FMARGIN_PERCENT
                        rs_DataRow(7) = sCIR(idx).FMARGIN_PROFIT

                        'Add up the total cost value
                        m_totalCost += sCIR(idx).FCOST * sCIR(idx).FSHIPQTY

                        'Add up the total price value
                        m_totalPrice += sCIR(idx).FPRICE * sCIR(idx).FSHIPQTY

                        'Calculate the average margin of all the items
                        'm_avgMarkup +=  sCIR(idx).FMARGIN_PERCENT /idx

                        'Add up the total margin value
                        m_totalMargin += sCIR(idx).FMARGIN_PROFIT

                        rs_Table.Rows.Add(rs_DataRow)

                    Next

                End If

hi

GeneralRe: calculate the weighted average Pin
jkirkerx28-Jul-15 6:25
professionaljkirkerx28-Jul-15 6:25 
QuestionDisplay data from SQL database to HTML page in table format using Angular JS Pin
iamcpmember27-Jul-15 0:21
professionaliamcpmember27-Jul-15 0:21 
QuestionApplied css styles showing wrong in mozilla firefox Pin
Member 920164824-Jul-15 2:50
Member 920164824-Jul-15 2:50 
AnswerRe: Applied css styles showing wrong in mozilla firefox Pin
jkirkerx24-Jul-15 9:29
professionaljkirkerx24-Jul-15 9:29 
GeneralRe: Applied css styles showing wrong in mozilla firefox Pin
Member 92016485-Aug-15 21:25
Member 92016485-Aug-15 21:25 
Questionhiding label and textbox after update Pin
spirospap22-Jul-15 19:16
spirospap22-Jul-15 19:16 
AnswerRe: hiding label and textbox after update Pin
Blikkies23-Jul-15 0:46
professionalBlikkies23-Jul-15 0:46 
GeneralRe: hiding label and textbox after update Pin
spirospap23-Jul-15 12:11
spirospap23-Jul-15 12:11 
SuggestionRe: hiding label and textbox after update Pin
ZurdoDev23-Jul-15 3:26
professionalZurdoDev23-Jul-15 3:26 
QuestionTrying to prevent the first dropdownlist value changing my database field unless I need to in C# Pin
Norris Chappell22-Jul-15 16:30
Norris Chappell22-Jul-15 16:30 
AnswerRe: Trying to prevent the first dropdownlist value changing my database field unless I need to in C# Pin
Herman<T>.Instance23-Jul-15 11:06
Herman<T>.Instance23-Jul-15 11:06 
GeneralRe: Trying to prevent the first dropdownlist value changing my database field unless I need to in C# Pin
Norris Chappell23-Jul-15 18:23
Norris Chappell23-Jul-15 18:23 
GeneralRe: Trying to prevent the first dropdownlist value changing my database field unless I need to in C# Pin
Herman<T>.Instance23-Jul-15 20:51
Herman<T>.Instance23-Jul-15 20:51 
Questionquery Pin
saif.rashid21-Jul-15 22:35
saif.rashid21-Jul-15 22:35 
AnswerRe: query Pin
Blikkies21-Jul-15 23:13
professionalBlikkies21-Jul-15 23:13 
AnswerRe: query Pin
F-ES Sitecore22-Jul-15 0:40
professionalF-ES Sitecore22-Jul-15 0:40 
AnswerRe: query Pin
Richard Deeming22-Jul-15 1:42
mveRichard Deeming22-Jul-15 1:42 

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.