Calculating Total Shipped Qty

I set the counter to 0 and it didn't work. I have yet to work with BPM but I will give it a shot.

Thanks,

Drew
I am currently trying to sum up the field ShipDtl.SellingShipmentQty for the packing slip and dumping that summed value in ShipHead.Number02. I am new to vb so I'm learning as I go. I initialize the code upon the ShipHead.PackNum field change. I don't get any errors thrown but the value that appears in the ShipHead.Number02 field is 0. I'm guessing it is not storing my calculation. Any thoughts?

Thanks,

Drew


Private Sub ShipHead_AfterFieldChange(ByVal sender As object, ByVal args As DataColumnChangeEventArgs) Handles ShipHead_Column.ColumnChanged


Select Case args.Column.ColumnName

Case "PackNum"

'On Error Resume Next
Dim tempTotalShipped As Decimal = 6
Dim counter As integer = 1

Dim edvPackingLine As EpiDataView = CType(oTrans.EpiDataViews("ShipDtl"), EpiDataView)
Dim PackingLine As Int32 = edvPackingLine.dataView(edvPackingLine.Row)("PackLine")

Dim edvSellShipQty As EpiDataView = CType(oTrans.EpiDataViews("ShipDtl"), EpiDataView)
Dim SellShipQty As Decimal = edvSellShipQty.dataView(edvSellShipQty.Row) ("SellingShipmentQty")

Dim edvTotalQtyShipped As EpiDataView = CType(oTrans.EpiDataViews("ShipHead"), EpiDataView)
Dim TotalQtyShipped As Decimal = edvTotalQtyShipped.dataView(edvTotalQtyShipped.Row)("Number02")


while(counter <= PackingLine)


tempTotalShipped = tempTotalShipped + SellShipQty

counter = counter + 1


End while


TotalQtyShipped = tempTotalShipped

otrans.Update()


Case Else

End Select
End Sub
Have you tried bpm
Sent from my Verizon Wireless BlackBerry

-----Original Message-----
From: "drew.pete" <drew.pete@...>

Date: Mon, 17 Aug 2009 16:27:41
To: <vantage@yahoogroups.com>
Subject: [Vantage] Calculating Total Shipped Qty


I am currently trying to sum up the field ShipDtl.SellingShipmentQty for the packing slip and dumping that summed value in ShipHead.Number02. I am new to vb so I'm learning as I go. I initialize the code upon the ShipHead.PackNum field change. I don't get any errors thrown but the value that appears in the ShipHead.Number02 field is 0. I'm guessing it is not storing my calculation. Any thoughts?

Thanks,

Drew


Private Sub ShipHead_AfterFieldChange(ByVal sender As object, ByVal args As DataColumnChangeEventArgs) Handles ShipHead_Column.ColumnChanged


Select Case args.Column.ColumnName

Case "PackNum"

'On Error Resume Next
Dim tempTotalShipped As Decimal = 6
Dim counter As integer = 1

Dim edvPackingLine As EpiDataView = CType(oTrans.EpiDataViews("ShipDtl"), EpiDataView)
Dim PackingLine As Int32 = edvPackingLine.dataView(edvPackingLine.Row)("PackLine")

Dim edvSellShipQty As EpiDataView = CType(oTrans.EpiDataViews("ShipDtl"), EpiDataView)
Dim SellShipQty As Decimal = edvSellShipQty.dataView(edvSellShipQty.Row) ("SellingShipmentQty")

Dim edvTotalQtyShipped As EpiDataView = CType(oTrans.EpiDataViews("ShipHead"), EpiDataView)
Dim TotalQtyShipped As Decimal = edvTotalQtyShipped.dataView(edvTotalQtyShipped.Row)("Number02")


while(counter <= PackingLine)


tempTotalShipped = tempTotalShipped + SellShipQty

counter = counter + 1


End while


TotalQtyShipped = tempTotalShipped

otrans.Update()


Case Else

End Select
End Sub




[Non-text portions of this message have been removed]
Start your counter at 0.

Scott

 Conserve our resources. Please don't print this e-mail unless it's really necessary.

-----Original Message-----
From: vantage@yahoogroups.com [mailto:vantage@yahoogroups.com] On Behalf Of drew.pete
Sent: Monday, August 17, 2009 11:28 AM
To: vantage@yahoogroups.com
Subject: [Vantage] Calculating Total Shipped Qty

I am currently trying to sum up the field ShipDtl.SellingShipmentQty for the packing slip and dumping that summed value in ShipHead.Number02. I am new to vb so I'm learning as I go. I initialize the code upon the ShipHead.PackNum field change. I don't get any errors thrown but the value that appears in the ShipHead.Number02 field is 0. I'm guessing it is not storing my calculation. Any thoughts?

Thanks,

Drew


Private Sub ShipHead_AfterFieldChange(ByVal sender As object, ByVal args As DataColumnChangeEventArgs) Handles ShipHead_Column.ColumnChanged


Select Case args.Column.ColumnName

Case "PackNum"

'On Error Resume Next
Dim tempTotalShipped As Decimal = 6
Dim counter As integer = 1

Dim edvPackingLine As EpiDataView = CType(oTrans.EpiDataViews("ShipDtl"), EpiDataView)
Dim PackingLine As Int32 = edvPackingLine.dataView(edvPackingLine.Row)("PackLine")

Dim edvSellShipQty As EpiDataView = CType(oTrans.EpiDataViews("ShipDtl"), EpiDataView)
Dim SellShipQty As Decimal = edvSellShipQty.dataView(edvSellShipQty.Row) ("SellingShipmentQty")

Dim edvTotalQtyShipped As EpiDataView = CType(oTrans.EpiDataViews("ShipHead"), EpiDataView)
Dim TotalQtyShipped As Decimal = edvTotalQtyShipped.dataView(edvTotalQtyShipped.Row)("Number02")


while(counter <= PackingLine)


tempTotalShipped = tempTotalShipped + SellShipQty

counter = counter + 1


End while


TotalQtyShipped = tempTotalShipped

otrans.Update()


Case Else

End Select
End Sub



------------------------------------

Useful links for the Yahoo!Groups Vantage Board are: ( Note: You must have already linked your email address to a yahoo id to enable access. )
(1) To access the Files Section of our Yahoo!Group for Report Builder and Crystal Reports and other 'goodies', please goto: http://groups.yahoo.com/group/vantage/files/.
(2) To search through old msg's goto: http://groups.yahoo.com/group/vantage/messages
(3) To view links to Vendors that provide Vantage services goto: http://groups.yahoo.com/group/vantage/linksYahoo! Groups Links