• Oxene
  • NEWBIE
  • 80 Points
  • Member since 2008


  • Chatter
    Feed
  • 3
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 12
    Questions
  • 12
    Replies

Hi friends,

 

 Can u pls help me to get all queuemembers in Queue?

 

 Is there any SOQL query to get this! pls Help me regarding this........

 

 

 Thank U

Sfdcbluefish

 

 

 

I have imported few data sheets into SF - sandbox. But there are quite a lot of duplicates being created.

I want to delete the data using Apex Data Loader. I am new to the this data loader. When I login to the data loader and Use the 'Delete' option, it asks to select the SF object. This is fine. But then it also needs a CSV file. I am here to delete the data.(Not import/Update). Kindly help me

 

  • January 12, 2010
  • Like
  • 0

Hi,

 

We have a scenario where we need to replicate a task created on an Account for the child accounts. So I have written a trigger on Task before update. Everything works fine till I create a recurring task. When I create a recurring task I get an error saying "Apex Task Trigger cannot handle batch operations on recurring tasks". Is there any work around to create recurring tasks?

  • August 31, 2009
  • Like
  • 0

I have a scenario wherein I have to assign a record of a custom object to a queue for approval. The record has to go to approver A first, then to approver B and on approval from B, it has to go to a queue. Now, the queue to which the record has to be assigned depends on the district to which the record belongs. Since the number of queues is large, I cannot do this check in the approval process steps as it will run out of the limit of 15 steps for an approval process.

 

           So, I'm trying to populate the queue to which the record has to be routed in a field on the custom object. I'm not able to create a lookup to Queue object. So I tried with lookup to User object, but when I assign a queue Id to this field it throws a DML exception saying 'FIELD_INTEGRITY_EXCEPTION, id value of incorrect type'.

 

How can I assign a queue id to a custom field and use that field to route approvals in my approval processes (there being a constraint that only User lookup fields can be used in approval processes)?

  • May 26, 2009
  • Like
  • 0

Hi,

 

I need to show the translation of some custom messages on an s-control HTML page. I have these messages created as Custom Labels but I am unable to access the translated values from the server through my s-control since CustomLabel is not an Object. I even tried with Metadata API using describeSObject and describeGlobal but couldn't fetch the values.

 

Can anybody tell me how I can fetch these labels?

  • May 22, 2009
  • Like
  • 0

Hi Community,

 

I'm creating a visualforce page on opportunity object. My Stage values are dependent on Record type in Opportunity. I need to display the Stage picklist on this new visualforce page but it should contain only the valid picklist values for the particular record type of the Opportunity record. How can I achieve this?

         

       I found this article in which the author is making use of two new custom objects to store the dependency information but I don't want to use this since it is going to be very difficult to maintain it. Is there any workaround for this (using the Metadata API or something)?

  • April 22, 2009
  • Like
  • 0

Hi Community,

I'm creating a custom formula field Field1 which refers to 4 other formula fields(FieldA,FieldB,FieldC,FieldD) to populate a value. Now based on the value in Field1, I'm populating another custom formula field Field2 using the formula

CASE (Field1, 'A', Object__r.fld1__c, 'B', Object__r.fld2__c, Object__r.fld3__c)

where Object__r is the reference to another custom object through a lookup and fld1,fld2 and fl3 are custom fields on that object.

 

Now, the character count when compiling formula field Field1 is around 2000. So, when I use it in the formula for Field2 given above, the compiled count comes to around 4000 and hence I'm not able to include anymore conditions. I need to compare values from 'A' to 'T'.

          

         I found on the community that using Case function instead of multiple If functions will help reduce the character count. I also found that using workflows is another workaround for reducing the character count. So I have implemented the above two methods in the calculation of Field1 and brought down the character count to a minimum but still I'm not able to get the required functionality because for each set of options I give in Case function, the character count of Field1 is being taken into account. Has anybody come across something like this? Is there a way in which I can compare the value in Field1without it being called multiple times.

  • April 22, 2009
  • Like
  • 0
I'm trying to create a merge field in a custom object A that refers and gets value from another custom object B. I'm not able to get this value in objectA, but i'm able to get values for similar fields on standard object Account.

In short, i'm able to get 'C_Account__r.Name' in the formula field but not 'C_Partner__r.Name__c' where Account and Partner objects are related to custom object A through lookups. Here Account is the standard object and Partner is a custom object

Can anybody help me out?
  • December 11, 2008
  • Like
  • 0

I am writing a trigger to approve a record submitted for approval using the standard 'Submit for approval' button. But when i do that the record is getting approved twice with the same date and time of approval. I was submitting the record for approval in the morning through apex and it was getting submitted twice. In the afternoon it was working fine, executing only one submission. This is happening with the same apex code without any modification. Can anyone please help me out? I am giving a sample for the code i have used below.

trigger triggerName on customObject (after insert, after update) { customObject cObj = Trigger.new[0]; ProcessInstance[] prInst = [Select Id from ProcessInstance where

                TargetObjectId=:cObj.Id and Status='Pending']; if(prInst.size()>0){

                ProcessInstanceWorkitem[] prInstWItem = [select Id,OriginalActorId from

                       ProcessInstanceWorkitem where ProcessInstanceId=rInst[0].Id]; Approval.ProcessWorkitemRequest prWkItem =

                                    new Approval.ProcessWorkitemRequest();

prWkItem.setWorkitemId(prInstWItem[0].Id);

prWkItem.setComments('Approving request.'); prWkItem.setAction('Approve'); Approval.ProcessResult prResult = Approval.process(prWkItem);

          }

  }

 

Thanks in advance for your help.

  • December 02, 2008
  • Like
  • 0

I am writing a trigger to approve a record submitted for approval using the standard 'Submit for approval' button. But when i do that the record is getting approved twice with the same date and time of approval. I was suubmitting the record for approval in the morning through apex and it was getting submitted twice. In the afternoon it was working fine, executing only one submission. This is happening with the same apex code without any modification. Can anyone please help me out? I am giving a sample for the code i have used below.

 

trigger triggerName on customObject (after insert, after update) { customObject cObj = Trigger.new[0]; ProcessInstance[] prInst = [Select Id from ProcessInstance where

                TargetObjectId=:cObj.Id and Status='Pending']; if(prInst.size()>0){

                ProcessInstanceWorkitem[] prInstWItem = [select Id,OriginalActorId from

                       ProcessInstanceWorkitem where ProcessInstanceId=:prInst[0].Id]; Approval.ProcessWorkitemRequest prWkItem =

                                    new Approval.ProcessWorkitemRequest();

prWkItem.setWorkitemId(prInstWItem[0].Id);

prWkItem.setComments('Approving request.'); prWkItem.setAction('Approve'); Approval.ProcessResult prResult = Approval.process(prWkItem);

          }

  }

 

Thanks in advance for your help.

  • December 02, 2008
  • Like
  • 0
Hi all,

I have a requirement where i need to give a field update in an approval process. I need to get a custom field updated with the approval comments entered for that record by the approver. How can i do this?


  • October 15, 2008
  • Like
  • 0
I have a VF page in which i'm using 40 outputFields. I want these to be styled according to a particular condition. If the field value satisfies the condition, style1 should be used or else style2 should be used. Now i can write 40 different functions to check whether each field satisfies the criteria or not. I want to use a generalized function by passing some parameter to the function.

But I'm not able to pass parameters to a function from the VF page. Does anybody know how to do this?

How can i do this in a better way so that i use a generalized function?

Please help me out if you have any ideas.
  • September 11, 2008
  • Like
  • 0
I have a VF page and an extension class to extend the standard controller. I need to have a global variable in the apex class which keeps incrementing by 1 each time a particular function is accessed. As the scope of 'static' is limited to a request, i'm not able to track the count. Can anybody help?
  • September 11, 2008
  • Like
  • 0
Hi all,

Can anyone tell me how i can call a apex class method with parameter from a visualforce page?

This is my code.

<apex:outputLabel styleClass="{!relay}" value="Postal Code"/>

How can i pass a value to the apex method 'relay' as shown above?
  • September 09, 2008
  • Like
  • 0

Hi friends,

 

 Can u pls help me to get all queuemembers in Queue?

 

 Is there any SOQL query to get this! pls Help me regarding this........

 

 

 Thank U

Sfdcbluefish

 

 

 

I have imported few data sheets into SF - sandbox. But there are quite a lot of duplicates being created.

I want to delete the data using Apex Data Loader. I am new to the this data loader. When I login to the data loader and Use the 'Delete' option, it asks to select the SF object. This is fine. But then it also needs a CSV file. I am here to delete the data.(Not import/Update). Kindly help me

 

  • January 12, 2010
  • Like
  • 0

I have a scenario wherein I have to assign a record of a custom object to a queue for approval. The record has to go to approver A first, then to approver B and on approval from B, it has to go to a queue. Now, the queue to which the record has to be assigned depends on the district to which the record belongs. Since the number of queues is large, I cannot do this check in the approval process steps as it will run out of the limit of 15 steps for an approval process.

 

           So, I'm trying to populate the queue to which the record has to be routed in a field on the custom object. I'm not able to create a lookup to Queue object. So I tried with lookup to User object, but when I assign a queue Id to this field it throws a DML exception saying 'FIELD_INTEGRITY_EXCEPTION, id value of incorrect type'.

 

How can I assign a queue id to a custom field and use that field to route approvals in my approval processes (there being a constraint that only User lookup fields can be used in approval processes)?

  • May 26, 2009
  • Like
  • 0

Hi Community,

 

I'm creating a visualforce page on opportunity object. My Stage values are dependent on Record type in Opportunity. I need to display the Stage picklist on this new visualforce page but it should contain only the valid picklist values for the particular record type of the Opportunity record. How can I achieve this?

         

       I found this article in which the author is making use of two new custom objects to store the dependency information but I don't want to use this since it is going to be very difficult to maintain it. Is there any workaround for this (using the Metadata API or something)?

  • April 22, 2009
  • Like
  • 0
Hi,

 I am trying to install SUBCLIPSE from the force.com IDE (Eclipse), but my network is with in the proxy due to that I am not able to install subclipse. Please let me know how can I install using proxy settings.



I'm trying to create a merge field in a custom object A that refers and gets value from another custom object B. I'm not able to get this value in objectA, but i'm able to get values for similar fields on standard object Account.

In short, i'm able to get 'C_Account__r.Name' in the formula field but not 'C_Partner__r.Name__c' where Account and Partner objects are related to custom object A through lookups. Here Account is the standard object and Partner is a custom object

Can anybody help me out?
  • December 11, 2008
  • Like
  • 0

I am writing a trigger to approve a record submitted for approval using the standard 'Submit for approval' button. But when i do that the record is getting approved twice with the same date and time of approval. I was submitting the record for approval in the morning through apex and it was getting submitted twice. In the afternoon it was working fine, executing only one submission. This is happening with the same apex code without any modification. Can anyone please help me out? I am giving a sample for the code i have used below.

trigger triggerName on customObject (after insert, after update) { customObject cObj = Trigger.new[0]; ProcessInstance[] prInst = [Select Id from ProcessInstance where

                TargetObjectId=:cObj.Id and Status='Pending']; if(prInst.size()>0){

                ProcessInstanceWorkitem[] prInstWItem = [select Id,OriginalActorId from

                       ProcessInstanceWorkitem where ProcessInstanceId=rInst[0].Id]; Approval.ProcessWorkitemRequest prWkItem =

                                    new Approval.ProcessWorkitemRequest();

prWkItem.setWorkitemId(prInstWItem[0].Id);

prWkItem.setComments('Approving request.'); prWkItem.setAction('Approve'); Approval.ProcessResult prResult = Approval.process(prWkItem);

          }

  }

 

Thanks in advance for your help.

  • December 02, 2008
  • Like
  • 0

I am writing a trigger to approve a record submitted for approval using the standard 'Submit for approval' button. But when i do that the record is getting approved twice with the same date and time of approval. I was suubmitting the record for approval in the morning through apex and it was getting submitted twice. In the afternoon it was working fine, executing only one submission. This is happening with the same apex code without any modification. Can anyone please help me out? I am giving a sample for the code i have used below.

 

trigger triggerName on customObject (after insert, after update) { customObject cObj = Trigger.new[0]; ProcessInstance[] prInst = [Select Id from ProcessInstance where

                TargetObjectId=:cObj.Id and Status='Pending']; if(prInst.size()>0){

                ProcessInstanceWorkitem[] prInstWItem = [select Id,OriginalActorId from

                       ProcessInstanceWorkitem where ProcessInstanceId=:prInst[0].Id]; Approval.ProcessWorkitemRequest prWkItem =

                                    new Approval.ProcessWorkitemRequest();

prWkItem.setWorkitemId(prInstWItem[0].Id);

prWkItem.setComments('Approving request.'); prWkItem.setAction('Approve'); Approval.ProcessResult prResult = Approval.process(prWkItem);

          }

  }

 

Thanks in advance for your help.

  • December 02, 2008
  • Like
  • 0
I have a VF page and an extension class to extend the standard controller. I need to have a global variable in the apex class which keeps incrementing by 1 each time a particular function is accessed. As the scope of 'static' is limited to a request, i'm not able to track the count. Can anybody help?
  • September 11, 2008
  • Like
  • 0
Hi all,

Can anyone tell me how i can call a apex class method with parameter from a visualforce page?

This is my code.

<apex:outputLabel styleClass="{!relay}" value="Postal Code"/>

How can i pass a value to the apex method 'relay' as shown above?
  • September 09, 2008
  • Like
  • 0