Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

RePublishToUpfront command

Status
Not open for further replies.

PekkaK

Technical User
Jul 8, 2003
4
FI
I have problems in republishing reports to UpFront with CognosScript.

I published reports using command:

objPPRep.PublishToUpfront strNewsItemName, strReportDescription, strNewsBoxName, strUserName, strPassword

And after saving and reopening I'm trying to republish them with command:

objPPRep.RePublishToUpfront strReportDescription, strUserName, strPassword

Publishing works fine, but republishing gives me following error message:

"Error 440: PowerPlay: Not currently available"


Has anyone experienced similar problems? Or do you know commands to manage (to remove in this case) NewsItems in UpFront?
 
Sounds like it wants you to have the app open maybe?

Sub Main()
Dim objPPRep as Object
Dim objPPApp as Object
Set objPPApp = CreateObject("CognosPowerPlay.Application.cer3")
objPPApp.Visible 1

PublishToUpfront Method
Syntax
Report.PublishToUpfront ItemName, [ItemDescription], NewsBoxName, UserId, Password
Applies To
Report Object
Description
Creates a NewsItem in Upfront from a report built on a remote cube.
Discussion
Use this method to distribute PowerPlay for Windows reports to other users on the Web. You can
save PowerPlay for Windows reports to Upfront NewsBoxes to give subscribers access to the
report as a PDF. Users do not need PowerPlay for Windows to view the reports; all they need is
a Web browser (either Netscape Navigator 3.01+ or Microsoft Internet Explorer 3.01+) and
Upfront.
To use this method you must
• have a connection to a cube on a remote server
• be a registered user on Access Manager who has authorized access to the remote cube
and publishing rights to a NewsBox in Upfront
• have access to the report server
If the report is successfully published to Upfront, the method returns True and the NewsItem
identification is saved so that you can republish updates to the report.

Example
This example creates a NewsItem in Upfront based on the active report.
Sub Main()
Dim objPPRep as Object
Dim strNewsItemName as String
Dim strReportDescription as String
Dim strNewsBoxName as String
Set objPPRep = GetObject(, "CognosPowerPlay.Report")
strNewsItemName = "Sales Projections for 1999"
strReportDescription = "Western cities sales projections"
strNewsBoxName = "//NewsIndex/Public NewsBoxes/Tests"
objPPRep.PublishToUpfront strNewsItemName, _
strReportDescription,strNewsBoxName,"Administrator","admin1234"
objPPRep.Save
Set objPPRep = Nothing
End Sub

CP [cook]
 
I don't think so since the code before PublishToUpfront and RepublishToUpfront are exactly the same and when having the two commands together (republish righ after publish) republishing works fine. But republishing doesn't work when I open the saved report later with the same macro. Republishing works fine though with PowerPlay client.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top