Sometimes you would want to give users the option to click a button on the page and send them back to the Portal Folder they came from, or may be couple folders back! Here is how you go about doing that.

You can actually use the PeopleSoft delivered function NavPageURL to accomplish this! So, lets get started!

On your page, go ahead and add a button. Place the following PeopleCode at the Component Record Field level under FieldChange event

Declare Function NavPageURL PeopleCode EOPP_SCRTN_WRK.FUNCLIB FieldFormula;
&LINKURL = NavPageURL(%Portal, %Node, "your-folder-object-name", "PSC", "", "", "False", "", "", "");

%Response.RedirectURL(&LINKURL);

And here is the code for the NavPageURL function:

/********************************************************************/ /* Function: NavPageURL */ /* Purpose: Returns the Absolute URL value to the Navigation Page */ /* for a given collecton object name or folder object. */ /* Inputs: Nav Page PortalName, Nav Page NodeName, Nav Page */ /* Collection or Folder ObjectName, and URLType. */ /* Output: URL value as a string */ /* Format: &MYURL = NavPageURL("EMPLOYEE", "ERP", "MY_OBJECT", */ /* "", "", "", "", "") */ /********************************************************************/ Function NavPageURL(&PortalName As string, &NodeName As string, &ObjName As string, &URLType As string, &FolderName As string, &TargPortalName As string, &SecValue As string, &VirtualValue As string, &PTfname As string, &PTcname As string) Returns string; Local string &URL;
If All(&PortalName, &NodeName, &ObjName) Then
Evaluate Upper(&URLType) When = "PSC" &URL = GenerateScriptContentURL(&PortalName, &NodeName, Record.WEBLIB_EOPP_SC, Field.HOMEPAGE, "FieldFormula", "IScript_AppHP"); Break; When = "PSP" &URL = GenerateScriptPortalURL(&PortalName, &NodeName, Record.WEBLIB_EOPP_SC, Field.HOMEPAGE, "FieldFormula", "IScript_AppHP"); Break; When-Other &URL = GenerateScriptContentURL(&PortalName, &NodeName, Record.WEBLIB_EOPP_SC, Field.HOMEPAGE, "FieldFormula", "IScript_AppHP");
End-Evaluate;
&URL = &URL | "?scname=" | &ObjName;
If All(&SecValue) Then &URL = &URL | "&secondary=" | &SecValue; End-If;
If All(&FolderName) Then &URL = &URL | "&fname=" | &FolderName; End-If;
If All(&PTcname) Then /* pass either CFAN Cref or DFAN Fref, not both */ &URL = &URL | "&PORTALPARAM_PTCNAV=" | &PTcname; Else If All(&PTfname) Then &URL = &URL | "&pt_fname=" | &PTfname; End-If; End-If;
If All(&TargPortalName) Then &URL = &URL | "&targetportal=" | &TargPortalName; End-If;
If Upper(&VirtualValue) = "TRUE" Then &URL = &URL | "&isvirtual=" | &VirtualValue; End-If;
End-If;
Return &URL;

End-Function;

Send User to a Portal Folder的更多相关文章

  1. Visual Basic 函数速查

    Calendar 常数 可在代码中的任何地方用下列常数代替实际值: 常数 值 描述 vbCalGreg 0 指出使用的是阳历. vbCalHijri 1 指出使用的是伊斯兰历法. Color 常数 可 ...

  2. push or get File or Folder using scp wrapped with expect and bash

    经常需要把服务器的某些文件传到 Mac,或者获取 Mac 的一些文件到服务器.尽管有很多命令scp, ftp, rsync都可以,霸特每次都有敲好长的命令,好烦,而且还要输入密码.所以想着 wrap ...

  3. Send Push Notifications to iOS Devices using Xcode 8 and Swift 3, APNs Auth Key

    Send Push Notifications to iOS Devices using Xcode 8 and Swift 3 OCT 6, 2016 Push notifications are ...

  4. The specified file or folder name is too long

    You receive a "The specified file or folder name is too long" error message when you creat ...

  5. Portal Page的呈現

    先看一下在JSR168中提到的Portal page,可以了解一個Portal Page上大概有哪些element: OK...進入本次主題 PSML:PSML的全名是Portal Structure ...

  6. Overview Of Portal Registry And Content References

     Portal Registry Each portal is defined by a portal registry.A portal registry has a tree-like struc ...

  7. Step-by-Step Guide to Portal Development for Microsoft Dynamics CRM - 摘自网络

    The Challenge Oftentimes in the world of Dynamics CRM, the need arises for non-CRM users to gain acc ...

  8. [转]How to Send Ethereum with Web3.js and Node

    原文:https://davekiss.com/ethereum-web3-node-tutorial/   Ethereum took the web and cryptocurrency worl ...

  9. [转]How To Send Transactional Email In A NodeJS App Using The Mailgun API

    https://www.npmjs.com/package/mailgun-js 本文转自:https://www.mailgun.com/blog/how-to-send-transactional ...

随机推荐

  1. 荣耀6 Plus 的屏幕大小pt计算方法

    使用 gomobile 检测 华为荣耀 6 Plus 的屏幕大小为:  1080*1776 px ;   162pt*266.40pt ;  每pt像素个数:6.666665个. 而实际的数据是: 主 ...

  2. 关于BEA-000402和BEA-000438

    OS:rh5 64位 JDK:1.5 64位 weblogic:9.2.3 jar 应用程序部署后,启动受管服务器报如下警告和错误: 这个问题导致系统性能下降,打开weblogic控制台各项功能和应用 ...

  3. [SQL]分组排练进行更新

    --方法(一):分组排练进行更新 ----------------------------------------------------------------------------------- ...

  4. Spark-1.5.2安装

    1.下载scala-2.10.6包解压到指定目录 #SCALA VARIABLES START export SCALA_HOME=/usr/local/scala-2.10.6 export PAT ...

  5. Flex 医疗行程图

    ================================================ 病案的质量控制: 1.医生自检,主任检测,病案室检测达到三级检测 2.人工检测,自动检测 3.抽检(采 ...

  6. iis实现类似tomcat ip:port直接访问站点

    先配置host: 建站点: iis配置文件地址:C:\Windows\System32\inetsrv\config\applicationHost.config(于tomcat中的web.xml类似 ...

  7. Note for Computer Networks_Circuit Switching & Packet Switching

    Packet Switching: - In a packet switched network data is transmitted in blocks(packets), typically l ...

  8. Android开发-API指南-<uses-sdk>

    <uses-sdk> 英文原文:http://developer.android.com/guide/topics/manifest/uses-sdk-element.html 采集(更新 ...

  9. c# 获取excel所有工作表

    var filePath="f:\xx.xlsx" string connStr = "Provider=Microsoft.Ace.OleDb.12.0;" ...

  10. BZOJ 1036 树的统计-树链剖分

    [ZJOI2008]树的统计Count Time Limit: 10 Sec Memory Limit: 162 MBSubmit: 12904 Solved: 5191[Submit][Status ...