diff --git a/PriceLists.bas b/PriceLists.bas index 6d674a1..225d9ee 100644 --- a/PriceLists.bas +++ b/PriceLists.bas @@ -562,11 +562,14 @@ Sub build_customer_files() '---------------------logo---------------------------------------------------------------------------------- fcws.Rows("1:2").RowHeight = 28.5 fcws.Cells(1, 1).Select - fcws.Pictures.Insert("https://hc-companies.com/wp-content/themes/hc-companies/images/logo.svg").Select - Selection.ShapeRange.ScaleHeight 0.6, msoFalse, msoScaleFromTopLeft - Selection.ShapeRange.IncrementLeft 2 - Selection.ShapeRange.IncrementTop 2 + ActiveSheet.Pictures.Insert("https://hccompanies.sharepoint.com/_layouts/15/download.aspx?UniqueId=2ee21088%2Ddad1%2D41aa%2Daf65%2D14b44c46941e").Select + 'Selection.ShapeRange.ScaleHeight 0.6, msoFalse, msoScaleFromTopLeft + Selection.ShapeRange.ScaleWidth 0.375, msoFalse, msoScaleFromTopLeft + 'Selection.ShapeRange.ScaleHeight 0.52, msoFalse, msoScaleFromTopLeft + 'Selection.ShapeRange.IncrementLeft 2 + 'Selection.ShapeRange.IncrementTop 2 ActiveSheet.Hyperlinks.Add Anchor:=ActiveSheet.Shapes.Item(1), address:="https://hc-companies.com/" + ActiveSheet.Cells(5, 1).Select fcws.Cells(1, 4).value = "Distributor Price List - Effective " & Format(effdate, "MM/DD/YYYY") fcws.Name = "Full Code Listing" fcws.Cells(3, 1).Select @@ -579,7 +582,7 @@ Sub build_customer_files() Set nwb = Application.Workbooks.Add nwb.Activate Set nws = nwb.Sheets(1) - segment_regex = "G|N|F" + segment_regex = "^G|^N|^F|^P" '---------------------get price list------------------------------------------------------------------------ If pricelevel.chbNURSERY Then @@ -589,7 +592,7 @@ Sub build_customer_files() Exit Sub End If If UBound(pln, 2) > 21 Then - segment_regex = "^F|^G" + segment_regex = "^F|^G|^P" Set nnws = nwb.Sheets.Add(, nws) nnws.Name = "Price List - Nursery" Call paste_pretty(pln, nnws, effdate) @@ -603,10 +606,10 @@ Sub build_customer_files() Exit Sub End If If UBound(plf, 2) > 21 Then - If segment_regex = "^F|^G" Then - segment_regex = "^G" + If segment_regex = "^F|^G|^P" Then + segment_regex = "^G|^P" Else - segment_regex = "^G|^N" + segment_regex = "^G|^N|^P" End If Set nfws = nwb.Sheets.Add(, nws) nfws.Name = "Price List - Fiber" @@ -746,10 +749,12 @@ Sub paste_pretty(ByRef pl() As String, ByRef nws As Worksheet, ByVal effdate As '---------------------logo---------------------------------------------------------------------------------- ActiveSheet.Cells(1, 1).Select - ActiveSheet.Pictures.Insert("https://hc-companies.com/wp-content/themes/hc-companies/images/logo.svg").Select - Selection.ShapeRange.ScaleHeight 0.6, msoFalse, msoScaleFromTopLeft - Selection.ShapeRange.IncrementLeft 2 - Selection.ShapeRange.IncrementTop 2 + ActiveSheet.Pictures.Insert("https://hccompanies.sharepoint.com/_layouts/15/download.aspx?UniqueId=2ee21088%2Ddad1%2D41aa%2Daf65%2D14b44c46941e").Select + 'Selection.ShapeRange.ScaleHeight 0.6, msoFalse, msoScaleFromTopLeft + Selection.ShapeRange.ScaleWidth 0.375, msoFalse, msoScaleFromTopLeft + 'Selection.ShapeRange.ScaleHeight 0.52, msoFalse, msoScaleFromTopLeft + 'Selection.ShapeRange.IncrementLeft 2 + 'Selection.ShapeRange.IncrementTop 2 ActiveSheet.Hyperlinks.Add Anchor:=ActiveSheet.Shapes.Item(1), address:="https://hc-companies.com/" ActiveSheet.Cells(5, 1).Select