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.
Since we can't use macros (in 2007) to copy data from the sheet that has the WebFOCUS data to the sheet that has the preset formatting and styling etc., Is there any other way to get the data in the sheet - some sort of referencing syntax that can say this sheet (which let's say contains my Excel FOOTER) references all the data on another sheet?This message has been edited. Last edited by: Kerry,
If your aim is to purely apply the data into the pre-styled sheet then turn it around. Load the data and then use macros to style the sheet. The scope you have with VBA is immense so just get your head around it and don't be too blinkered in your analysis.
T
In FOCUS since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2
WebFOCUS App Studio 8.2.06 standalone on Windows 10
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004
The reason I was trying to get away from VBA is because of the Excel 2007 problem - to recap:
WebFOCUS requires you to save your templates in .mht files. Microsoft stopped supporting VBA in .mht files as of 2007. If your organization has moved over to 2007 you're out of luck...
Yeah - we could always find someone with Excel 2003 (myself included) to give us the template but something tells me that would NOT be a good idea from a support/maintenance perspective...
I've just tested creating an .mht file from within Excel 2007 perfectly OK. I've also looked at it via an editor and it looks OK and seems to have the necessary headers but have not tested it from WebFOCUS.
Have you actually tried it?
T
In FOCUS since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2
WebFOCUS App Studio 8.2.06 standalone on Windows 10
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004
Yes, I tried it - the problem is when you have VBA in it - Microsoft won't save the VBA.
What do I need the VBA - I would like to get an Excel Footer into my template. If I put it on the same sheet as where the WebFOCUS data goes, it gets wiped out. If I put it on a different sheet, I was using VBA to copy the data over but the VBA doesn't get saved now...
So this brings us back to my original post on this thread - is there any other way to get the data to the sheet with the footer (either by some reference or somehow have the Footer on the same sheet where WebFOCUS dumps the data and not have the Footer wiped out)?
When you say "Excel Footer", do you mean one assigned during the print setup? If so then you either have to do it as per J.G.'s article mentioned by him above or add it via a WebFOCUS footing.
T
In FOCUS since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2
WebFOCUS App Studio 8.2.06 standalone on Windows 10
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004
We make extensive use of VBA in Excel templates for our reporting, so I have a strong interest in finding a solution to this problem before our company upgrades to Office 2007. I've been doing some research.
I came across something called Excel Named Ranges, and I'm wondering if this would work in place of copying data from the data worksheet to the formatted worksheet. Take a look and see what you think - it's in the Dev Studio help index under Excel Named Ranges. Apparently a named range in an Excel template will expand to hold whatever volume of data is shipped to it.
Richard the Blackhearted Scourge of the Internet
WebFOCUS 7.6.4, AIX 5.3, Win XP Pro SP2 / MRE / Oracle / MS SQL
Posts: 12 | Location: Boston, MA | Registered: July 11, 2007
Judging only from the Help file info (which is sometimes not precisely true) it sounds like Excel Named Ranges would accommodate variable-row and variable-column layouts. We haven't actually tested this yet - I was talking this over with a colleague late yesterday afternoon, and we may be trying it soon. One thing that concerns me is that the help file says you can't use this method with subtotals - that could be a vexing limitation in some cases.
Richard the Blackhearted Scourge of the Internet
WebFOCUS 7.6.4, AIX 5.3, Win XP Pro SP2 / MRE / Oracle / MS SQL
Posts: 12 | Location: Boston, MA | Registered: July 11, 2007
I've just tested creating an .mht file from within Excel 2007 perfectly OK
Did you try putting a formula; such as in a cell on sheet1 referring to another cell on sheet2? I tried to save the mht file. Excel 07 would not save the formula.
wf 7.6.11 unix aix active reports, HTML, Excel, Text and PDF formats
I must admit that I did not try that particular scenario. My main requirements for Excel templates is the VBA ability and, because WebFOCUS overwrites all contents including formulae, I would not normally code formulae direct but would use VBA in the workbook_open sub.
T
In FOCUS since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2
WebFOCUS App Studio 8.2.06 standalone on Windows 10
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004
I have just tested an .MHT file saved from within Excel 2007.
Upon saving the file you get the ... some features are not compatible etc. etc. ... but the file appears to save OK. If you edit the file using a text editor then the layout looks perfectly OK from the point of view of headers.
However, if you open the file from within Excel, the VBA code is no longer in existance (I guess that includes any formulae etc. as well!). A BIG problem for the future and one that reduces the functionality and useability of Excel templates from within WebFOCUS. I hope IB will issue recommendations other than "stick with Office 2003" which, corporatly, is not an option. I guess that "some features" actually means "most if not all features"!
I suppose J.G's article method might be possible - a bit retrograde though!.
I'm not sure if Cognos can utilise Excel to the same extent as WebFOCUS, but if it can then this could sign a warrant for WF at some of my clients as one, in particular, has around 1000 multi sheet Excel files produced per day - each one is internally formatted using VBA code as WF cannot achieve the page settings, borders etc.
Finally, yes, I know that the problem is caused by MicroShaft shifting their policy with Excel 2007 (who needs backward compatability anyway ) but I am sure that there are many IB Customers out there, like my Client, who utilise this functionality and will be left up the provebial creek without so much as a paddle if we cannot find a way forward!
Because I am a Contractor, I will maintain one of my own machines with Orifice 2003 so that I can still create template files - always open to consultancy requests for piece work
Horrified from England!
In FOCUS since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2
WebFOCUS App Studio 8.2.06 standalone on Windows 10
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004
but are you actively seeking a solution or waiting on others?
Me, I've just taken the VBA out of the Excel workbooks and created the necessary bits in VBScript. Of course, it helps if you can code your requirements in VBScript .....
T
In FOCUS since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2
WebFOCUS App Studio 8.2.06 standalone on Windows 10
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004
Very much so! If I come up with anything, or if IBI provides anything, I will let you all know. I had put the question up to see if others had already come up with decent workarounds.
Very much so! If I come up with anything, or if IBI provides anything, I will let you all know. I had put the question up to see if others had already come up with decent workarounds.
what about the VBScript solution Tony A offered? if it was me i would have started thinking about trying to do it in VB as the languages are so similar but VBScript is even better suited to it...
Developer Studio 7.64 Win XP Output: mostly HTML, also Excel and PDF
"Never attribute to malice that which can be adequately explained by stupidity." - Heinlein's Razor
Posts: 285 | Location: UK | Registered: October 26, 2007
I'd do your research first and then answer this question yourself.
I now have a working alternative and I can assure you that it does the same job as the internal (clue!) VBA code. Only four more template files to replicate now
T
In FOCUS since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2
WebFOCUS App Studio 8.2.06 standalone on Windows 10
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004