Sounds strange !!!
I bet many you would immediately think it is not possible to configure a drill down on a form applet but I would say, “Technically it is possible”. It wouldn’t be usual Hyperlink on a field that we have on a list applet but it would work the same way.
First let’s analyze the functionality of usual drilldown that we have on a list applet. You configure a field to have a drilldown. In UI that field value starts acting as Hyperlink and clicking on that Hyperlink takes you to another view and important thing to note is that it maintains the context and you land up on the same record on which you drilldown.
Now, in form applet is not possible to configure the field value to appear as Hyperlink but it is possible to have a button which will act in same way.
How is it possible?
There is a function provided by Siebel “GotoView” that can help us to achieve this functionality.
GotoView elaborated!
GotoView function accepts two arguments View Name and Business Object Instance for example
GotoView(“Opportunity Detail View”,OptyBO)
The second argument (BO Instance) is optional but if you don’t provide that you will not be able to maintain the context which means that you will not land up on the same record. BO Instance which is passed should be an inactive BO instance you cannot use ActiveBusObject function to get BO Instance.
Let’s see this functionality in action with help of a requirement
Requirement:
I have Opportunity (Parent) and Quotes (Child). I want to have a button on Opportunity Form Applet with caption (My Primary Quote) on click of the button user should be taken to Quotes View and Quote which has ‘Primary Flag’ set to true should be visible.
Primary Flag is just a boolean base field.
Solution:
I am assuming that you have already exposed a button with MethodName as ‘ShowPrimaryQuote’. I am just going to provide the code.
if(MethodName == “ShowPrimaryQuote”)
{
var QuoteBO:BusObject = TheApplication().GetBusObject(“Quote”);
var QuoteBC:BusComp = QuoteBO.GetBusComp(“Quote”);
with(QuoteBC)
{
SetViewMode(AllView);
ClearToQuery();
ActivateField(“OpptyId”); // Field that stores Opportunity Id
ActivateField(“PrimaryFlag”);
SetSearchSpec(“OpptyId”,this.GetFieldValue(“Id”));
SetSearchSpec(“PrimaryFlag”,”Y”);
ExecuteQuery(ForwardOnly);
if(FirstRecord())
{
GotoView(“Quote Detail View”,QuoteBO);
}
}
}
This code will take the user to Quote detail view if it is able to find Primary Quote for that opportunity otherwise it will do nothing. You can modify it to give an error message or some other processing if required.


(10 votes, average: 4.10 out of 5)





Hi Neel,
Thanks for sharing this with all!!
The same can be achieved without writing script…i have done this two weeks back and its working as expected.
Wanted to create a drilldown from Form applet to different view.
Resolution:
The following test case shows how to create drilldown hyperlink in Form applet:
1) In the Account Entry Applet create new Drilldown object with the following properties:
Name – GotoActivity
Hyper Link Field – Name
View – Account Detail – Activities View
2) create a control with the following properties:
HTML Type = Link
Field = Name
Method Invoke = Drilldown
3) Add the control to the applet.
Using this configuration steps creates an hyperlink allowing to the Account Detail – Activities View.
Note: The hyperlink is showing the value entered in the control Caption and not the field value.
Thats it!!! Hyperlink button is ready in Form applet.
This will take the user back to the same record which keeps the context as well.
Incase anyone have question on this, please email me @ mailmerajan[at]gmail.com
Renga,
This is a really nice solution and will work well as drilldown. But for above requirement that I discussed you are not suppose to drilldown on opportunity but you need to drill down on quotes (that too primary one) associated to that opportunity. So, I don’t think for above requirement this can work.
but a nice clean solution if you want a simple drill down
Hi Neel,
Rengarajan has provided the standard way to implement drilldowns from form applets. I gave it a try and implemented a drilldown (hyperlink) from the Opportunity Form Applet (Child) to the primary quote by adding a drilldown object to the applet and setting PR Quote Id as the source field, Quote as the BC and Id as the destination field.
The control is configured as Rengarajan points out.
Works like a charm.
As always, your advocate for scriptless Siebel
@lex
Alex,
I tired that too… works perfectly…
Posts and conversation like these make me feel that this site is serving its purpose because most of the time you are under assumption that you are implementing the best solution but there is always somebody out there who comes up with a better one.
And now it is for everybody to see and learn from it.They can use this information in their future implementations.
Thanks Renga again for sharing the perfect solution
Hi Neel,
This is an interesting topic that you have initiated. I was curious to see if someone has a different idea. Kudos to Renka for his valuable suggestion.
For the benefits of other readers, I am just highlighting the article posted by Joshua Weir in IT ToolBox 8/19/2008 on
“Create a Drill Down Object on a Form Applet”.This article describes how to display a drill down on a form applet.
I have not used this approach but its quite directive and similar to the solution that Rengarajan used.
Approach is well documented. Feel free to research.
Thanks
Harish Kumar
There is another way of drilling down from a form applet I’m usin occasionally. Suppose you have a button on an applet which does smthng and then navigates you to another view within the same BO. The requirement is to keep the context.
1. Change class of your form applet to CSSSWEFrameBase (it supports the required method)
2. Create a drilldown object you need
3. Invoke “DrillDownToView” method with one parameter – name of the DD
Assume you have a “Goto Account” button on an order form applet.
Then you have a button which invokes method Test that should take the user to order account.
You can put such a script:
InvokeMethod (“DrillDownToView”, “Account”);
Or use a simple user property instead (if you hate scripting just as much as I do):
Name: Named Method: Test
Value: ‘INVOKE’, ‘DrillDownToView’, ‘Account’
Hope that will help someone
But in name field that was not showing a account name it works like hyperlink field only
But how we can change to caption of this field ,
when iam using in account it working as drilldown but How to show that record name it was always showing a caption only
Rengarajan, your suggestion is good and it worked for me too.
I have one another question that it shows caption as a Hyperlink and can not it show the value of name field ?