• rvk
  • NEWBIE
  • 25 Points
  • Member since 2010

  • Chatter
    Feed
  • 1
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 44
    Questions
  • 35
    Replies

Hello, I'm getting to following error message, any ideas? Thanks in advance!

 

System.ListException: List index out of bounds: 0: Class.ManageOpportunitiesBeforeUpdate.beforeUpdate: line 84, column 32

 

list<Opportunity> allopps = [select Id, AccountId, CreatedDate
from Opportunity
where Id in :accids
and CreatedDate in :createdDates
order by AccountId, CreatedDate];
map<Id, Integer> oppid2seqnummap = new map<Id, Integer>();

//reset placeholders: last Account, last Date, current counter
Id thisaccid = allopps[0].AccountId;
Date thisdate = allopps[0].CreatedDate.date();
Integer counter = 0;

 

 

the requirement is to show a pick list of check box for each row  in page block table.

  • September 27, 2012
  • Like
  • 0

A  VF page using jquery tabs and a left horizontal navigation menu. when click on a  item description of a record should show on tab1 , tab2 displays associated accounts  uisng page block table, tab3 contacts. tabs should rerender up on naviagtion tab1 is getting refresh while tab2 and tab3 are not getting rerendered.

  • September 13, 2012
  • Like
  • 0

There is a  page block table with some input fileds and a command button .when value entered in the input field and click enter key for some reason button method getting invoke. how to swicth the focus from one field to another field when click on enter key.

  • April 12, 2012
  • Like
  • 0

There is a visual force page in account detail page section , a button  in the visualforce should redirect to another visual force page which has to open in same page but the porblem here is when clicking on the button new visual force page is opening with in the same account detail section.

  • March 22, 2012
  • Like
  • 0

how  to create a pageblock table need to be filtered up on picklist view and  also  the table has to support pagination. 

  • March 21, 2012
  • Like
  • 0

we have a web service application which use to work well till last week. After certificate got expired so we created new one and also replaced the new  key in apex code from then it is throwing some wierd error like.

 

Operation aborted. Error code: IO Exception: DER input, Integer tag error

 

Please let me know how to fix this.


  • March 06, 2012
  • Like
  • 0

How to paginate a page block table which is using a wrapper class to display a list of rows.

  • February 27, 2012
  • Like
  • 0

I have a requirement need to display a table if any of the row value is acitive in one of the column called status now how to display a link(cancel) with in the same column that is next to acitve value.if user click on that link  status should turn to cancle and link should  disappear. Any thoughts....

  • February 21, 2012
  • Like
  • 0

I have a requirement need to display a table if any of the row value is acitive in one of the column called status now how to display a link(cancel) with in the same column that is next to acitve value.if user click on that link  status should turn to cancle and link should  disappear. Any thoughts....

  • February 21, 2012
  • Like
  • 0

the task is when click on a button it has to fetch  the pdf which exists in  remote server and  that pdf should be email as an attachment to the merchant. The condition here is pdf file shouldn't be stored in salesforce.

  • November 14, 2011
  • Like
  • 0

when click on a button need to fetch  the pdf which exists in  internal server and  that pdf should be send as an email to the merchant. The condition here is pdf file shouldn't be stored in salesforce.

  • November 09, 2011
  • Like
  • 0

how to display the actual values of the encrypted text field values in a visual force page.please help me out.

  • September 02, 2011
  • Like
  • 0

I have developed a vf page to render it As pdf. With in the pdf  i need to add page break to end the page with couple of sections and should continue next section from new  page.Is there any way I could do that.

 

  • July 26, 2011
  • Like
  • 0

I need to convert vf page to pdf, In pdf i am not able to see the check boxs which are displyed in vf page and also having alignment issues.Does any one have suggestions.

 

  • July 19, 2011
  • Like
  • 0

 i need to display   the links in visual force page  similar to the  related list links at the top of  account or any other  object standard detail page, when click on the link it should show corresponding related list exists on the same page.

  • July 11, 2011
  • Like
  • 0

I have installed and  configured force IDE in  eclipse  Helios. when i try to create a project, after entering login detials  in the progress information box it shows  fetching packages it displays for a while at the end  "connection time out " error is coming up  all the time.

  • June 29, 2011
  • Like
  • 0

Can one let me how to load xml file using data loader command line interface and also need to automate the data loading.

  • February 03, 2011
  • Like
  • 0

Can one let me how to load xml file using data loader command line interface and also need to automate the data loading.

  • February 03, 2011
  • Like
  • 0

Is there away to attach  Files which are attached to inbound emails  to the case record using Email to case process.Can any one help me out.

  • November 02, 2010
  • Like
  • 0

Is there a way to attach  Files which are attached in inbound emails  to the case record using Email to case process.Can any one help me out.

  • November 02, 2010
  • Like
  • 0

A  VF page using jquery tabs and a left horizontal navigation menu. when click on a  item description of a record should show on tab1 , tab2 displays associated accounts  uisng page block table, tab3 contacts. tabs should rerender up on naviagtion tab1 is getting refresh while tab2 and tab3 are not getting rerendered.

  • September 13, 2012
  • Like
  • 0

how  to create a pageblock table need to be filtered up on picklist view and  also  the table has to support pagination. 

  • March 21, 2012
  • Like
  • 0

How to paginate a page block table which is using a wrapper class to display a list of rows.

  • February 27, 2012
  • Like
  • 0

I have a requirement need to display a table if any of the row value is acitive in one of the column called status now how to display a link(cancel) with in the same column that is next to acitve value.if user click on that link  status should turn to cancle and link should  disappear. Any thoughts....

  • February 21, 2012
  • Like
  • 0

Hello, I'm getting to following error message, any ideas? Thanks in advance!

 

System.ListException: List index out of bounds: 0: Class.ManageOpportunitiesBeforeUpdate.beforeUpdate: line 84, column 32

 

list<Opportunity> allopps = [select Id, AccountId, CreatedDate
from Opportunity
where Id in :accids
and CreatedDate in :createdDates
order by AccountId, CreatedDate];
map<Id, Integer> oppid2seqnummap = new map<Id, Integer>();

//reset placeholders: last Account, last Date, current counter
Id thisaccid = allopps[0].AccountId;
Date thisdate = allopps[0].CreatedDate.date();
Integer counter = 0;

 

 

how to display the actual values of the encrypted text field values in a visual force page.please help me out.

  • September 02, 2011
  • Like
  • 0

Hello everyone,

 

I'm currently trying to get a field to change on the opportunity when it's converted from a lead, using a custom field from the lead itself. However, I can't seem to get it change properly. My code is below. Any advice would be appreciated

 

trigger Configero_Lead_OpportunityConversion on Lead (before update) {

List<Opportunity> o = new List<Opportunity>();
List<ID> oids=new List<id>();
       for(Lead convertedLead: Trigger.new){

if(convertedLead.IsConverted == TRUE && convertedLead.ConvertedOpportunityId != NULL){               
oids.add(convertedLead.ConvertedOpportunityId);

}

o=[select id from opportunity where id IN: oids];

for(Lead convertedLead: Trigger.new){
    for(opportunity op:o)
    {
        if(op.id==convertedlead.ConvertedOpportunityId)
            op.name+=convertedLead.Proposed_Opportunity_Name__c;
    }
}

upsert o;

}

 

  • August 23, 2011
  • Like
  • 0

Good Morning,

 

I am new to Apex coding and any help would be appreciated.  I have a customer object orders and opportunity line items are related to an order.  I am trying to write a trigger that will rollup the total price of products on an order.  I get an error on the SOQL query and I cannot figure out why or work it out.  Below is my code.  Thanks in advance.

 

Trigger SumTotalPriceofProductsonOrder on OpportunityLineItem (after delete, after insert, after undelete, 
after update) 
{

	set<id> order_ids = new set<id>();
	
	if(trigger.isInsert || trigger.isupdate || trigger.isundelete)
		{for (opportunitylineitem t : Trigger.new)
			{if( trigger.isinsert || trigger.isundelete)
				{if(t.Order__c != null && t.totalprice > 0)
					{order_ids.add(t.Order__c);
					}
				}
		
			else if (trigger.isupdate)
				{if (trigger.oldmap.get(t.id).Order__c != null)
					order_ids.add(trigger.oldmap.get(t.id).Order__c);
				 if (trigger.newmap.get(t.id).Order__c != null)
				 	order_ids.add(trigger.newmap.get(t.id).Order__c);
				}			
			}
		}
	else if (trigger.isdelete)
		{for(opportunitylineitem t : Trigger.old)
			{if (t.Order__c != null && t.TotalPrice > 0)
				{order_ids.add(t.Order__c);
				}	
			}
		}

	Orders__c[] ord = new Orders__c[]{};
	
	for (Orders__c o : [Select Id, (Select Id, TotalPrice from OpportunityLineItem) From Orders__c where id in :order_ids])
		{
			double totalPrice = 0;
			
			for (OpportunityLineItem t : o.OpportunityLineItem)
				OrderTotalPrice =+ t.totalprice;
				
			o.Total_Price_of_Products__c = ordertotalPrice;
			ord.add(o);
		}
	update ord;
}

 

I have developed a vf page to render it As pdf. With in the pdf  i need to add page break to end the page with couple of sections and should continue next section from new  page.Is there any way I could do that.

 

  • July 26, 2011
  • Like
  • 0

 i need to display   the links in visual force page  similar to the  related list links at the top of  account or any other  object standard detail page, when click on the link it should show corresponding related list exists on the same page.

  • July 11, 2011
  • Like
  • 0

I have installed and  configured force IDE in  eclipse  Helios. when i try to create a project, after entering login detials  in the progress information box it shows  fetching packages it displays for a while at the end  "connection time out " error is coming up  all the time.

  • June 29, 2011
  • Like
  • 0

Hi,

The following links shows how to attach pdf and send email using Apex code

http://www.salesforce.com/us/developer/docs/pages/Content/pages_email_sending_attachments.htm

The part in the article given at end of my post reads a pdf and set its content as attachment.But this example only shows how to attach VisualForce page which is renderd as PDF.

 

When I tried same example code with a PDF file hosted on some other server and is public(Say: http://myserver.com/myFile.pdf). The VisualForce page runs without error, but does not give any response. Doesn't Apex attaching external files as attachment with email. If Not is there any other workaround. The problem is I want to attach a PDF which is hosted on some other server and send email using Apex. 

 

 

Messaging.SingleEmailMessage email = new Messaging.SingleEmailMessage();

        // Reference the attachment page and pass in the account ID
        PageReference pdf =  Page.attachmentPDF;
        pdf.getParameters().put('id',(String)account.id);
        pdf.setRedirect(true);

        // Take the PDF content
        Blob b = pdf.getContent();

        // Create the email attachment
        Messaging.EmailFileAttachment efa = new Messaging.EmailFileAttachment();
        efa.setFileName('attachment.pdf');
        efa.setBody(b);