As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.
Join the TIBCO Community TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.
From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
Request access to the private WebFOCUS User Group (login required) to network with fellow members.
Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.
I am using a macro template created by an ex-coworker that uses a particular fex. I copied that fex into my folder and made some two modifications to the report. I reduced the number of columns that appear on the report and I created an across column. When I execute the fex and it opens up in Excel, I enable the macro but nothing happens. I need to know why the macro does not run. I'm familiar with Excel macros, but know little about vba. There is some vba code in the macro that I need to know what it is doing. Perhaps that is the reason why the macro does not run. Pasted below is the macro code and I have highlighted the code that I do not understand. Can someone interpret what the highlighted code is doing so that I can figure out why the macro does not work? This is an urgent matter that needs to be resolved by tomorrow. Thank you.
Sub Auto_Open() ' ' MRS Auto_Open Macro (used for fomatting MRS reports) ' Macro recorded 10/1/2010 by Administrator ' ' Keyboard Shortcut: Ctrl+Shift+M ' Dim rngBorder As Range
Application.ScreenUpdating = False
' Check if signature is present, if so, macro has been run once and should exit If Sheets(1).Range("A1").Value <> "" Then GoTo exitSub
' Loop through all sheets in workbook For Each sh In ActiveWorkbook.Sheets sh.Activate If Range("A10").Value = "" And Range("B10").Value = "" And Range("C10").Value = "" And Range("D10").Value = "" Then GoTo nextSheet
If InStr(1, sh.Range("A8").Value, "rpt_v2") Then Set rngBorder = Range(Range("A11"), Range("A11").Offset(0, 250).End(xlToLeft).Offset(65000, 0).End(xlUp)) ElseIf InStr(1, sh.Range("A8").Value, "rpt_v3") Then ' add rpt_v3 logic. 02/10/11-kb above. Set rngBorder = Range(Range("A12"), Range("A12").Offset(0, 250).End(xlToLeft).Offset(65000, 0).End(xlUp)) Else Set rngBorder = Range(Range("A10"), Range("A10").Offset(0, 250).End(xlToLeft).Offset(65000, 0).End(xlUp)) End If With rngBorder .Columns.AutoFit ' add borders .Borders(xlDiagonalDown).LineStyle = xlNone .Borders(xlDiagonalUp).LineStyle = xlNone .Borders.LineStyle = xlContinuous .Borders.Weight = xlThin .Borders.ColorIndex = xlAutomatic End With 'add autofit kb 2/10/11 Cells.Select Selection.Columns.AutoFit
' page setup With ActiveSheet.PageSetup .PrintArea = "" If InStr(1, sh.Range("A8").Value, "rpt_v2") Then .PrintTitleRows = "$1:$11" ElseIf InStr(1, sh.Range("A8").Value, "rpt_v3") Then ' add rpt_v3 logic. 02/10/11-kb above. .PrintTitleRows = "$1:$12" Else .PrintTitleRows = "$1:$10" End If .PrintTitleColumns = "$A:$A" .LeftHeader = "" .CenterHeader = "" .RightHeader = "" .LeftFooter = "&6&F" .CenterFooter = "&6Confidential, [Un]published Property of GENEX Services, Inc." & Chr(10) & "Do Not Duplicate or Distribute. Use and Distribution Limited Solely to Authorized Personnel." & Chr(10) & "@Copyright 2013 GENEX Services, Inc." .RightFooter = "&6Page &P of &N" .LeftMargin = Application.InchesToPoints(0.5) .RightMargin = Application.InchesToPoints(0.5) .TopMargin = Application.InchesToPoints(0.5) .BottomMargin = Application.InchesToPoints(1) .HeaderMargin = Application.InchesToPoints(0.25) .FooterMargin = Application.InchesToPoints(0.5) .PrintHeadings = False .PrintGridlines = False .PrintComments = xlPrintNoComments .CenterHorizontally = False .CenterVertically = False .Orientation = xlLandscape .Draft = False .PaperSize = xlPaperLetter .FirstPageNumber = xlAutomatic .Order = xlOverThenDown .BlackAndWhite = False .Zoom = 90 .PrintErrors = xlPrintErrorsDisplayed End With
If InStr(1, sh.Range("A8").Value, "rpt_v2") Then Range("B12").Select ElseIf InStr(1, sh.Range("A8").Value, "rpt_v3") Then ' add rpt_v3 logic. 02/10/11-kb above. Range("B13").Select Else Range("B11").Select End If ActiveWindow.FreezePanes = True
' add logic to pull tab name from A8. 10/25/10-chg to A4. If sh.Range("A4").Value <> "" Then sh.Name = sh.Range("A4").Value sh.Range("A4").Value = " " End If
nextSheet: Next sh
exitSub: Set rngBorder = Nothing Sheets(1).Activate Sheets(1).Range("A1").Value = " " ActiveWorkbook.Save Application.ScreenUpdating = True End SubThis message has been edited. Last edited by: <Kathryn Henning>,
There is an embeded Company logo that takes up 3 rows, starting in cell A1 in both the original and modified fex. The logo image is set up as a define field and included on the first line of the heading section in the fex. Thanks.
Right now I'm trying to understand the following code. Cells A10-D10 on Sheet1 contain column headings. Thanks. ' Loop through all sheets in workbook For Each sh In ActiveWorkbook.Sheets sh.Activate If Range("A10").Value = "" And Range("B10").Value = "" And Range("C10").Value = "" And Range("D10").Value = "" Then GoTo nextSheet
quote:
Originally posted by j.gross:
quote:
' Check if signature is present, if so, macro has been run once and should exit If Sheets(1).Range("A1").Value <> "" Then GoTo exitSub
What does cell A1 of sheet 1 contain, when macros are disabled and you run (a) the original fex? (b) the modified fex?