You need to sign in to do that
Don't have an account?
z.chen
How to get subject from a visualforce page for SControl which is embeded in the visualforce page
Hi,
I've created an scontrol and want to embed it into a visualforce page.
With the attribute subject we can give an object id to the scontroll:
<apex:page standardController="Account">
<apex:scontrol controlName="HelloWorld" height="60" subject="0017000000NHLs5"></apex:scontrol>
</apex:page>
But how can I get this object id in the scontrol?
Thanks for your idea.
Zhengdao
I've created an scontrol and want to embed it into a visualforce page.
With the attribute subject we can give an object id to the scontroll:
<apex:page standardController="Account">
<apex:scontrol controlName="HelloWorld" height="60" subject="0017000000NHLs5"></apex:scontrol>
</apex:page>
But how can I get this object id in the scontrol?
Thanks for your idea.
Zhengdao
Why are you building new scontrols at all? Scontrols are on a deprecation path and there is nothing you can do in an scontrol that you cannot do in VF at least as well and almost always better, faster, cheaper etc.
Can you provide a bit more info on what you are trying to accomplish and we'll see if we can get you on the right path?
Thanks for your reply.
Want I want to do is to list records of an SObject in a VF page. For this I tried to use the apex dataTable elemet. But I could not make the number of columns dynamic. For example, depending on some current field values I want the table to have different number of columns.
E.g.:
If columnNumber__c == 2, then the table schold have columns field1__c and field2__c and if columnNumber__c == 3, then the table should have columns field2__c, field4__c and field__5.
That is, in the first case the table has 2 columns while in the second case the table has 3 columns.
It seem that it's impossible to realize this with VF I wanted to try this with SControl, since with Scontrol we can print a table with both dynamic number of columns and rows. That's why I wanted to deliver the ID of the object which has the field columnNumber__c.
Thanks a lot for your answer,
Zhengdao
At the end of the day you can get as close to the metal/browser as you want using VF.
Zhengdao
indeed trying to pass parameter to scontrol from vf page. any ideas?
hey i followed your post it is pretty intresting , but i want to see how you implemented the dynamic soql could you plz shed some ideas and the code snippets.
Thanks in advance.