aimlion11yahoo
Instructor
Below is a selection of code I've highlighted.
I want to find every pattern that begins with .Item and ends with GID").
Then I want to replace these patterns with a prefix of Func.CheckDBNull( and a suffixe of ).
Code:
Me._oRelease.PriceShipping = .Item("PriceShipping")
Me._oRelease.PriceTotal = .Item("PriceTotal")
Me._oRelease.PriceTotalItems = .Item("PriceTotalItems")
Me._oRelease.ReleaseGID = .Item("ReleaseGID")
Me._oRelease.ReleaseStatusTypeGID = .Item("ReleaseStatusTypeGID")
Me._oRelease.SalesTax = .item("SalesTax")
Me._oRelease.ShipDateEst = .item("ShipDateEst")
Me._oRelease.ShippingMethodGID = .item("ShippingMethodGID")
Me._oRelease.ShipToGID = .Items("ShipToGID")
Me._oRelease.SubTotal = .Item("SubTotal")
I want to find every pattern that begins with .Item and ends with GID").
Then I want to replace these patterns with a prefix of Func.CheckDBNull( and a suffixe of ).
Code:
Me._oRelease.PriceShipping = .Item("PriceShipping")
Me._oRelease.PriceTotal = .Item("PriceTotal")
Me._oRelease.PriceTotalItems = .Item("PriceTotalItems")
Me._oRelease.ReleaseGID = [COLOR=red]Func.CheckDBNull([/color].Item("ReleaseGID")[COLOR=red])[/color]
Me._oRelease.ReleaseStatusTypeGID = [COLOR=red]Func.CheckDBNull([/color].Item("ReleaseStatusTypeGID")[COLOR=red])[/color]
Me._oRelease.SalesTax = .item("SalesTax")
Me._oRelease.ShipDateEst = .item("ShipDateEst")
Me._oRelease.ShippingMethodGID = [COLOR=red]Func.CheckDBNull([/color].item("ShippingMethodGID")[COLOR=red])[/color]
Me._oRelease.ShipToGID = [COLOR=red]Func.CheckDBNull([/color].Items("ShipToGID")[COLOR=red])[/color]
Me._oRelease.SubTotal = .Item("SubTotal")