• Ram Manohar G
  • NEWBIE
  • 10 Points
  • Member since 2014

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 6
    Questions
  • 5
    Replies

Hi How to write Regex that should allow only a-z,A-Z,. , &,-, and whitespace in a string. I written below one

[a-zA-Z\\.\\&\\-\\ ]

The above one working if string only starts with alphabets (eg:sfdc.) , not working if start with other charecters(eg: &ab.)

Please post your answer. Thanks
 

Hi, 

I am using SOAP API(enterprise WSDL) to acess the salesforce from java. My salesforce org having few managed pacakges(arround 10). 

I am able to acces the custom objects and managed package objects via java,. However i am unable to accees an object(ksfdc_product) from one managed package. While debugging in to wsdl i found that salesforce not included this pacakge(namespace: ksfdc) while creating enterprise wsdl. 

Could anyone let me know the issue here. Thanks in advance

Hi ,
I have a pageblock table contains picklist column. If the picklist in a column contains only one value it should be disabled .How can i achive this 

Eg:
<apex:column header=' '>
<apex:selectList value="{!selectedCountry}" multiselect="false" > <apex:selectOptions value="{!CountriesOptions}"/> </apex:selectList>
</apex:column>
Hi , plz help on this
I have two action function, onclick of 'Next'  it invokes 'insertrecord'  actionfunction which run same controller method  the onComplet of this i am invoking 'doCallout' method using second action function.
Now i want to stop second action function  if there is an catch exception in doInsert() and run only if runaction==true . How to do it.

<apex:actionFunction name="InsertRecord" action="{!doInsert}" Rerender="Status1"
    status="Status1" oncomplete="doCalllout()"/>

   <apex:actionFunction action="{!doCalllout}" name="doCalllout" 
    reRender="opanel" status="Status2"/>

Controller:
public void doInsert()
{
  try{
   runaction=true;
}
 catch
{   
    runaction=false;
  -----ApexpageMessage-----; 
}
}
}

Hi,

Can anyone tell me which is the best structure of wrapper class to parse this XML. I want to keep this data in to wrapper. I am writing this way.

<Body>		
		<sampleresponse>
					
					<ns:InteranetData>                
						<networkAvailbility>Y</networkAvailbility>
						<Country>Brazil</Country>
						<RiskLevel>3</RiskLevel>
            			<netstat>                        
               			   <bandwidth>100</bandwidth>
               			   <type>BroadBand</type>
						</netstat>
						<netstat>                 
               				<bandwidth>70</bandwidth>
               				<type>Wireless</type>
						</netstat>
					</ns:InteranetData>
					
					<ns:NetworkProviders>
						<ns:AON>
							<ns1:Metroavailability>true</ns1:Metroavailability>
							<ns1:minPay>600</ns1:minPay>
							<ns1:maxPay>5000</ns1:maxPay>
							<ns1:areacode>S4</ns1:areacode>
							<ns1:postcode/>
						</ns:AON>
						<ns:ExcelBB>
							<ns1:Metroavailability>true</ns1:Metroavailability>
							<ns1:monthlyChargeble>8000</ns1:monthlyChargeble>
							<ns1:minPay>3000</ns1:minPay>
							<ns1:maxPay>9000</ns1:maxPay>
							<ns1:areacode>S1</ns1:areacode>
						</ns:ExcelBB>
					</ns1:NetworkProviders>
					
	    </sampleresponse>
	    </Body>	
		
  public class InteranetData
  {
    private String networkAvailbility{get;set;}
    private String Country{get;set;}
    private String RiskLevel{get;set;}
    public List<netstat> onnetAvail=new list<netstat>();

  }
  
  public  class netstat
  {
    public String bandwidth;
    public String type;  
  }
  
  public class NetworkProviders
  {
     List<AON> alist =new List<AON>;
      List<ExcelBB> Elist =new List<ExcelBB>;	 
   
  }
   public  class AON
  {
    public String Metroavailability;
    public String monthlyChargeble;  
  }
   public  class ExcelBB
  {
    public String Metroavailability;
    public String monthlyChargeble;  
  }

 

Hi Can anyone help me to resolve this. I am getting this error in VF controller. I am creating a custom picklist in VF controller wrapper class and  getting this
Error in debug while second run : System.TypeException: Invalid conversion from runtime type String to List<System.SelectOption>

sample code :
public class controller{
public class Wrapper
    {
      public boolean isCheck{get;set}
      public List<SelectOption> Picklist{get;set;}
      public String name{get;set;}
        }    

public List<wrapper> getwrapperlist()
    {
   
    return wrapperlist;
    } 

   public void setwrapperlist()
   {
    this.wrapperlist=wrapperlist;
   }

  public void method1()
{
 Wrapper w=new Wrapper();
w.addPicker=new List<selectoption>();
for(list<object> s:olist){
w.addPicker.add(new SelectOption (s.fname,s.fname));
}
wrapperlist.add(w);

}
}

 

Hi , plz help on this
I have two action function, onclick of 'Next'  it invokes 'insertrecord'  actionfunction which run same controller method  the onComplet of this i am invoking 'doCallout' method using second action function.
Now i want to stop second action function  if there is an catch exception in doInsert() and run only if runaction==true . How to do it.

<apex:actionFunction name="InsertRecord" action="{!doInsert}" Rerender="Status1"
    status="Status1" oncomplete="doCalllout()"/>

   <apex:actionFunction action="{!doCalllout}" name="doCalllout" 
    reRender="opanel" status="Status2"/>

Controller:
public void doInsert()
{
  try{
   runaction=true;
}
 catch
{   
    runaction=false;
  -----ApexpageMessage-----; 
}
}
}

Hi Can anyone help me to resolve this. I am getting this error in VF controller. I am creating a custom picklist in VF controller wrapper class and  getting this
Error in debug while second run : System.TypeException: Invalid conversion from runtime type String to List<System.SelectOption>

sample code :
public class controller{
public class Wrapper
    {
      public boolean isCheck{get;set}
      public List<SelectOption> Picklist{get;set;}
      public String name{get;set;}
        }    

public List<wrapper> getwrapperlist()
    {
   
    return wrapperlist;
    } 

   public void setwrapperlist()
   {
    this.wrapperlist=wrapperlist;
   }

  public void method1()
{
 Wrapper w=new Wrapper();
w.addPicker=new List<selectoption>();
for(list<object> s:olist){
w.addPicker.add(new SelectOption (s.fname,s.fname));
}
wrapperlist.add(w);

}
}