• Gayathri Adoni04
  • NEWBIE
  • 35 Points
  • Member since 2015

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

In our Project we will send SFDCid, Triggertime to SAP. Earlier Trigger time was taking system time ,now suddenly trigger time is 4 hours forward . what would be the reason for it. default timezone in all environments same so i thought its not because of defaulttime zone.

Anyone please help me. Where I need to check?
Hi All,

I am facing the error "The record you were editing was modified by SAP Data Loader during your edit session."
When i create new opportunity record and record saves and if update any fields i am getting the above error.But if record is already existing and if update any fields i am not facing the above error and fields are updating.

Can anyone tell me what would be the cause and how to overcome this/?

Mnay thanks well in advance.

Hi team,

I am sharing  snapshot of front and my apex class, visualforce page.

1.If i select checkbox and a value from picklist and click on save button i want to display the value of picklist in alertbox.
2.I have 2 pageblocksections, in that if the picklist values of 2 sections are Yes and corresponding checkbox is checked,i wantt a confirm dialog box saying do you want to proceed.

I dont want to make use of controller for adding logic to save button.

Thanks in advance. please help me out as i m learning i need some guidance in this to get good knowledge on javascript.


frontend of what i hav developed.

*************************************Apex class******************************************************

public class Movietable{


public List<Movie__c> mt{get;set;}
public List<Movie__c> mt1{get;set;}
public boolean b{get;set;}
public Movietable(ApexPages.standardController stdController) {

 mt=[select id, Values__c,select__c,Cinemas__c from Movie__c];
 mt1=[select id, Values__c,select__c,Cinemas__c from Movie__c where Cinemas__c='Bhajrangi Bhai jan'];


 for ( Movie__c mves : mt) {
  if(mves.Cinemas__c=='Bahubali')
  {
   system.debug('hello' +mves.Cinemas__c);
  }
 
  }
  
  for ( Movie__c mves : mt1) {
  if(mves.Cinemas__c=='Bhajrangi Bhai jan')
  {
   system.debug('hello1' +mves.Cinemas__c);
  }
 
  }

  
}
public PageReference save() { 
return null;
}

}



 

<apex:page standardController="Movie__c" extensions="Movietable" id="p">
  <apex:form id="f">
      <apex:pageBlock title="Movie Table" id="pageblock" >
          <apex:commandButton action="{!save}" id="cb"  value="Save" onclick="ss();"/>
      </apex:pageBlock>
     <apex:pageBlock id="pb1">
      <apex:pageBlockSection id="pbs" title="1st group" collapsible="false">
        <apex:dataTable id="dt" value="{!mt}" var="mlist" cellpadding="5" cellspacing="0"  width="100%">
        <apex:column id="c">
                 <apex:facet name="header"><center>Select to ADD</center></apex:facet>        
                 <apex:inputCheckbox value="{!mlist.select__c}" id="checkbox" > </apex:inputCheckbox>
                 </apex:column>          
       <apex:column >
                 <apex:facet name="header"><center>Select value</center></apex:facet>        
                 <apex:inputField id="markForTermCheckbox1" value="{!mlist.Values__c}" />
          </apex:column>

        </apex:dataTable>     
      </apex:pageBlockSection>   
      
      
       <apex:pageBlockSection id="pbs1" title="2nd group" collapsible="false">
        <apex:dataTable id="dt" value="{!mt1}" var="mlist" cellpadding="5" cellspacing="0"  width="100%">
        <apex:column >
                 <apex:facet name="header"><center>Select to ADD</center></apex:facet>        
                 <apex:inputCheckbox value="{!mlist.select__c}" id="checkbox1" > </apex:inputCheckbox>
                 </apex:column>          
       <apex:column >
                 <apex:facet name="header"><center>Select value</center></apex:facet>        
                 <apex:inputField id="markForTermCheckbox2" value="{!mlist.Values__c}" />
          </apex:column>

        </apex:dataTable>     
      </apex:pageBlockSection> 
      
      
        
     </apex:pageBlock> 
     
     <script>
     
     function ss(){
     
     alert("hi");
     var chk=document.getElementById('{!$Component.checkbox}');
     var val=document.getElementById('{!$Component.markForTermCheckbox1}');
     alert("val" +val);
     alert("cvdgjhd" +chk);
     if(chk.value==true && val=='Yes')
     alert("chk" +chk.value);

     var a=document.getElementById('{!$Component.p.f.pageblock}').cb;
     alert("a" +a);
     
     }
     
     
     </script>
     
     
     
     
      </apex:form>
  
</apex:page>
 




 


 


 

Hi All,

I am first time using javascript and i am new to salesforce too.So please help me to know where i am going wrong.

My Requirement is Onclick of checkbox a textfield should appear that too using only javascript not the controller class.I will be sharing my code here.Please helpme out with solutions.If you have some examples of javascript vfpage please do share it.It would be very beneficial to learn the things.Thanks in advance.
<apex:page standardController="contact" >
  <apex:form >
    <apex:pageBlock title="Javascript Example">
     <apex:pageBlockSection title="Checkbox Example"> 
      <apex:inputCheckbox id="cc" value="{!contact.Check_Me__c}" label="Do not call" onclick="tt(this,'{!$Component.ii}'})"/>
      <apex:inputField id="ii" value="{!contact.Languages__c}" />
     </apex:pageBlockSection>
   </apex:pageBlock>
  </apex:form>
   <script>
     function tt(input,txt)
     {
      if(input.checked)
      document.getElementById(txt).checked=true;
      else
      document.getElementById(txt).checked=false;
     }
   </script>
</apex:page>



 
Hi All,

My requirement is I have 2 radio buttons byname Movies,Events and When i click on movies related Movielist dropdown should appear similarly for events.I have a submit button byname ClickMe,if i click that button i want to display selected movie or an event.

I have done it partially,i need any of ur help as i am new to salesforce i am not exposed to these kind of scenarios.So please help me out.
I am sharing my code.Thanks in advance.


The dropdown in red box should come only if select any of above radio button.The text in yellow box should come only after Clicking Click Me button.
*********Vfpage******************

<apex:page id="pp" title="Movie's Now" controller="Movies" showHeader="false">
  <Apex:form >
   <apex:pageBlock title="Welcome to MOvie Selection Process">
   
   <!--   For Selecting Movie and Play        -->
      <apex:selectRadio value="{!s}" rendered="true">
        <apex:selectOptions value="{!items}"/>
      </apex:selectRadio><p/>
         <apex:actionSupport event="onclick" action="{!Click}" ReRender="in" >
            <apex:param assignTo="{!s}" name="ss" value="{!Movies}" />
         </apex:actionSupport>
           <!--<apex:actionFunction action="{!MovieSelection}"  name="MovieLocked" /> 
           <apex:actionFunction action="{!EventSelection}"  name="EventLocked" />-->
           
           <!-- for dropdown list -->
            <apex:selectList size="1" value="{!newmovies}" multiselect="false" rendered="{!newMovies!=null}" onclick="MovieSelection">
                <apex:selectOptions value="{!Movies1}"/>
                <apex:actionSupport event="onchange" reRender="in" action="{!MovieSelection}"/>
            </apex:selectList>
        
        
         <apex:selectList size="1" value="{!newEvents}" multiselect="false" rendered="{!newEvents!=null}">
            <apex:selectOptions value="{!Events1}"/>
        </apex:selectList>
        
        <!-- command button -->
        <apex:commandButton value="$$Click Me$$" action="{!Click}" rerender="out" status="status"/>
   </apex:pageBlock>
   
   
   <apex:outputpanel id="in" rendered="{!lmve.size != 0 && newEvents!=null || newmovies!=null}">
    
                              <apex:actionSupport event="onchange" rerender="out" status="status"/>
                          
   </apex:outputpanel>
   
   
   
   <apex:outputPanel id="out" rendered="{!lmve.size != 0}">
           <apex:outputText value="{!lmve}">The selected option is "{!s}"</apex:outputText>
           <apex:outputText value="{!lmve}">The selected Movie is "{!Events}"</apex:outputText>
          
     </apex:outputPanel> 
  </Apex:form>
</apex:page>
 
************Controller class**********************


public class Movies
{

  public String s{get;set;}
  public String name{get;set;}

  public boolean Movieflag{get;set;}
  public boolean Eventflag{get;set;}
  public  List<Movie__c> lmve{Get;Set;}
  public String Events{get;set;}
  public String Movies { get; set; }
  public boolean displayflag{get;set;}
  public List<SelectOption> options1{get;set;}
  public List<SelectOption> options2{get;set;}
  
  
  String[] newmovies= new String[]{};
  
  public String[] getnewmovies() {
            return newmovies;
        }
            
        public void setnewmovies(String[] newmovies) {
            this.newmovies= newmovies;
        }


  String[] newEvents=new String[]{};
  
  public String[] getnewEvents() {
            return newEvents;
        }
            
        public void setnewEvents(String[] newEvents) {
            this.newEvents= newEvents;
        }
  
  public Movies(){
   System.Debug('Helllo');
  }
  
  
  public PageReference Click()
  {
   Eventflag=false;
   if(s!=null && s.equalsIgnoreCase(Movies)){
    Movieflag=true;
   }
   
   else if(s!=null &&s.equalsIgnoreCase(Events)){
   Eventflag=true;
   }
   
   List<Movie__c> lmve=new List<Movie__c>();
   if(s!=null)
   lmve=[SELECT Id,Cinemas__c,name__c,Price__c,Tickets__c from Movie__c];
   
   return null;
  
  }
  
  
   public pagereference MovieSelection() 
    {
        Events=null;
        ApexPages.addMessage(new ApexPages.Message(ApexPages.Severity.confirm,'You Selected a movie'));
        return null;  
    }
    
    
    public pagereference EventSelection() 
    {
        Movies=null;
        ApexPages.addMessage(new ApexPages.Message(ApexPages.Severity.confirm,'You Selected an Event'));
        return null;  
    }
  

   public List<SelectOption> getItems() {
        List<SelectOption> options = new List<SelectOption>(); 
        options.add(new SelectOption('Movies','Movies'));
        options.add(new SelectOption('Events','Events')); 
        return options; 
    }
    
    public List<SelectOption> getMovies1() {
            List<SelectOption> options1 = new List<SelectOption>();
            options1.add(new SelectOption('Bahubali','Bahubali'));
            options1.add(new SelectOption('Rangitaranga','Rangitaranga'));
            options1.add(new SelectOption('BhaiJan','BhaiJan'));
            return options1;
        }
    public List<SelectOption> getEvents1() {
            List<SelectOption> options2 = new List<SelectOption>();
            options2.add(new SelectOption('abc','abc'));
            options2.add(new SelectOption('def','def'));
            options2.add(new SelectOption('sss','sss'));
            return options2;
        }
    

}

 
HI all,

Can anyone help me,My requirement is i want to display 3 columns 1st column only radio button,2nd column account name and 3rd column account number.when i click that radio button beside that account name, i should get related contact information of that  particular account
Hi All,

I am first time using javascript and i am new to salesforce too.So please help me to know where i am going wrong.

My Requirement is Onclick of checkbox a textfield should appear that too using only javascript not the controller class.I will be sharing my code here.Please helpme out with solutions.If you have some examples of javascript vfpage please do share it.It would be very beneficial to learn the things.Thanks in advance.
<apex:page standardController="contact" >
  <apex:form >
    <apex:pageBlock title="Javascript Example">
     <apex:pageBlockSection title="Checkbox Example"> 
      <apex:inputCheckbox id="cc" value="{!contact.Check_Me__c}" label="Do not call" onclick="tt(this,'{!$Component.ii}'})"/>
      <apex:inputField id="ii" value="{!contact.Languages__c}" />
     </apex:pageBlockSection>
   </apex:pageBlock>
  </apex:form>
   <script>
     function tt(input,txt)
     {
      if(input.checked)
      document.getElementById(txt).checked=true;
      else
      document.getElementById(txt).checked=false;
     }
   </script>
</apex:page>



 
Hi All,

My requirement is I have 2 radio buttons byname Movies,Events and When i click on movies related Movielist dropdown should appear similarly for events.I have a submit button byname ClickMe,if i click that button i want to display selected movie or an event.

I have done it partially,i need any of ur help as i am new to salesforce i am not exposed to these kind of scenarios.So please help me out.
I am sharing my code.Thanks in advance.


The dropdown in red box should come only if select any of above radio button.The text in yellow box should come only after Clicking Click Me button.
*********Vfpage******************

<apex:page id="pp" title="Movie's Now" controller="Movies" showHeader="false">
  <Apex:form >
   <apex:pageBlock title="Welcome to MOvie Selection Process">
   
   <!--   For Selecting Movie and Play        -->
      <apex:selectRadio value="{!s}" rendered="true">
        <apex:selectOptions value="{!items}"/>
      </apex:selectRadio><p/>
         <apex:actionSupport event="onclick" action="{!Click}" ReRender="in" >
            <apex:param assignTo="{!s}" name="ss" value="{!Movies}" />
         </apex:actionSupport>
           <!--<apex:actionFunction action="{!MovieSelection}"  name="MovieLocked" /> 
           <apex:actionFunction action="{!EventSelection}"  name="EventLocked" />-->
           
           <!-- for dropdown list -->
            <apex:selectList size="1" value="{!newmovies}" multiselect="false" rendered="{!newMovies!=null}" onclick="MovieSelection">
                <apex:selectOptions value="{!Movies1}"/>
                <apex:actionSupport event="onchange" reRender="in" action="{!MovieSelection}"/>
            </apex:selectList>
        
        
         <apex:selectList size="1" value="{!newEvents}" multiselect="false" rendered="{!newEvents!=null}">
            <apex:selectOptions value="{!Events1}"/>
        </apex:selectList>
        
        <!-- command button -->
        <apex:commandButton value="$$Click Me$$" action="{!Click}" rerender="out" status="status"/>
   </apex:pageBlock>
   
   
   <apex:outputpanel id="in" rendered="{!lmve.size != 0 && newEvents!=null || newmovies!=null}">
    
                              <apex:actionSupport event="onchange" rerender="out" status="status"/>
                          
   </apex:outputpanel>
   
   
   
   <apex:outputPanel id="out" rendered="{!lmve.size != 0}">
           <apex:outputText value="{!lmve}">The selected option is "{!s}"</apex:outputText>
           <apex:outputText value="{!lmve}">The selected Movie is "{!Events}"</apex:outputText>
          
     </apex:outputPanel> 
  </Apex:form>
</apex:page>
 
************Controller class**********************


public class Movies
{

  public String s{get;set;}
  public String name{get;set;}

  public boolean Movieflag{get;set;}
  public boolean Eventflag{get;set;}
  public  List<Movie__c> lmve{Get;Set;}
  public String Events{get;set;}
  public String Movies { get; set; }
  public boolean displayflag{get;set;}
  public List<SelectOption> options1{get;set;}
  public List<SelectOption> options2{get;set;}
  
  
  String[] newmovies= new String[]{};
  
  public String[] getnewmovies() {
            return newmovies;
        }
            
        public void setnewmovies(String[] newmovies) {
            this.newmovies= newmovies;
        }


  String[] newEvents=new String[]{};
  
  public String[] getnewEvents() {
            return newEvents;
        }
            
        public void setnewEvents(String[] newEvents) {
            this.newEvents= newEvents;
        }
  
  public Movies(){
   System.Debug('Helllo');
  }
  
  
  public PageReference Click()
  {
   Eventflag=false;
   if(s!=null && s.equalsIgnoreCase(Movies)){
    Movieflag=true;
   }
   
   else if(s!=null &&s.equalsIgnoreCase(Events)){
   Eventflag=true;
   }
   
   List<Movie__c> lmve=new List<Movie__c>();
   if(s!=null)
   lmve=[SELECT Id,Cinemas__c,name__c,Price__c,Tickets__c from Movie__c];
   
   return null;
  
  }
  
  
   public pagereference MovieSelection() 
    {
        Events=null;
        ApexPages.addMessage(new ApexPages.Message(ApexPages.Severity.confirm,'You Selected a movie'));
        return null;  
    }
    
    
    public pagereference EventSelection() 
    {
        Movies=null;
        ApexPages.addMessage(new ApexPages.Message(ApexPages.Severity.confirm,'You Selected an Event'));
        return null;  
    }
  

   public List<SelectOption> getItems() {
        List<SelectOption> options = new List<SelectOption>(); 
        options.add(new SelectOption('Movies','Movies'));
        options.add(new SelectOption('Events','Events')); 
        return options; 
    }
    
    public List<SelectOption> getMovies1() {
            List<SelectOption> options1 = new List<SelectOption>();
            options1.add(new SelectOption('Bahubali','Bahubali'));
            options1.add(new SelectOption('Rangitaranga','Rangitaranga'));
            options1.add(new SelectOption('BhaiJan','BhaiJan'));
            return options1;
        }
    public List<SelectOption> getEvents1() {
            List<SelectOption> options2 = new List<SelectOption>();
            options2.add(new SelectOption('abc','abc'));
            options2.add(new SelectOption('def','def'));
            options2.add(new SelectOption('sss','sss'));
            return options2;
        }
    

}

 
Hi All,

I am facing the error "The record you were editing was modified by SAP Data Loader during your edit session."
When i create new opportunity record and record saves and if update any fields i am getting the above error.But if record is already existing and if update any fields i am not facing the above error and fields are updating.

Can anyone tell me what would be the cause and how to overcome this/?

Mnay thanks well in advance.

Hi team,

I am sharing  snapshot of front and my apex class, visualforce page.

1.If i select checkbox and a value from picklist and click on save button i want to display the value of picklist in alertbox.
2.I have 2 pageblocksections, in that if the picklist values of 2 sections are Yes and corresponding checkbox is checked,i wantt a confirm dialog box saying do you want to proceed.

I dont want to make use of controller for adding logic to save button.

Thanks in advance. please help me out as i m learning i need some guidance in this to get good knowledge on javascript.


frontend of what i hav developed.

*************************************Apex class******************************************************

public class Movietable{


public List<Movie__c> mt{get;set;}
public List<Movie__c> mt1{get;set;}
public boolean b{get;set;}
public Movietable(ApexPages.standardController stdController) {

 mt=[select id, Values__c,select__c,Cinemas__c from Movie__c];
 mt1=[select id, Values__c,select__c,Cinemas__c from Movie__c where Cinemas__c='Bhajrangi Bhai jan'];


 for ( Movie__c mves : mt) {
  if(mves.Cinemas__c=='Bahubali')
  {
   system.debug('hello' +mves.Cinemas__c);
  }
 
  }
  
  for ( Movie__c mves : mt1) {
  if(mves.Cinemas__c=='Bhajrangi Bhai jan')
  {
   system.debug('hello1' +mves.Cinemas__c);
  }
 
  }

  
}
public PageReference save() { 
return null;
}

}



 

<apex:page standardController="Movie__c" extensions="Movietable" id="p">
  <apex:form id="f">
      <apex:pageBlock title="Movie Table" id="pageblock" >
          <apex:commandButton action="{!save}" id="cb"  value="Save" onclick="ss();"/>
      </apex:pageBlock>
     <apex:pageBlock id="pb1">
      <apex:pageBlockSection id="pbs" title="1st group" collapsible="false">
        <apex:dataTable id="dt" value="{!mt}" var="mlist" cellpadding="5" cellspacing="0"  width="100%">
        <apex:column id="c">
                 <apex:facet name="header"><center>Select to ADD</center></apex:facet>        
                 <apex:inputCheckbox value="{!mlist.select__c}" id="checkbox" > </apex:inputCheckbox>
                 </apex:column>          
       <apex:column >
                 <apex:facet name="header"><center>Select value</center></apex:facet>        
                 <apex:inputField id="markForTermCheckbox1" value="{!mlist.Values__c}" />
          </apex:column>

        </apex:dataTable>     
      </apex:pageBlockSection>   
      
      
       <apex:pageBlockSection id="pbs1" title="2nd group" collapsible="false">
        <apex:dataTable id="dt" value="{!mt1}" var="mlist" cellpadding="5" cellspacing="0"  width="100%">
        <apex:column >
                 <apex:facet name="header"><center>Select to ADD</center></apex:facet>        
                 <apex:inputCheckbox value="{!mlist.select__c}" id="checkbox1" > </apex:inputCheckbox>
                 </apex:column>          
       <apex:column >
                 <apex:facet name="header"><center>Select value</center></apex:facet>        
                 <apex:inputField id="markForTermCheckbox2" value="{!mlist.Values__c}" />
          </apex:column>

        </apex:dataTable>     
      </apex:pageBlockSection> 
      
      
        
     </apex:pageBlock> 
     
     <script>
     
     function ss(){
     
     alert("hi");
     var chk=document.getElementById('{!$Component.checkbox}');
     var val=document.getElementById('{!$Component.markForTermCheckbox1}');
     alert("val" +val);
     alert("cvdgjhd" +chk);
     if(chk.value==true && val=='Yes')
     alert("chk" +chk.value);

     var a=document.getElementById('{!$Component.p.f.pageblock}').cb;
     alert("a" +a);
     
     }
     
     
     </script>
     
     
     
     
      </apex:form>
  
</apex:page>
 




 


 


 

Hi All,

I am first time using javascript and i am new to salesforce too.So please help me to know where i am going wrong.

My Requirement is Onclick of checkbox a textfield should appear that too using only javascript not the controller class.I will be sharing my code here.Please helpme out with solutions.If you have some examples of javascript vfpage please do share it.It would be very beneficial to learn the things.Thanks in advance.
<apex:page standardController="contact" >
  <apex:form >
    <apex:pageBlock title="Javascript Example">
     <apex:pageBlockSection title="Checkbox Example"> 
      <apex:inputCheckbox id="cc" value="{!contact.Check_Me__c}" label="Do not call" onclick="tt(this,'{!$Component.ii}'})"/>
      <apex:inputField id="ii" value="{!contact.Languages__c}" />
     </apex:pageBlockSection>
   </apex:pageBlock>
  </apex:form>
   <script>
     function tt(input,txt)
     {
      if(input.checked)
      document.getElementById(txt).checked=true;
      else
      document.getElementById(txt).checked=false;
     }
   </script>
</apex:page>



 
Hi All,

My requirement is I have 2 radio buttons byname Movies,Events and When i click on movies related Movielist dropdown should appear similarly for events.I have a submit button byname ClickMe,if i click that button i want to display selected movie or an event.

I have done it partially,i need any of ur help as i am new to salesforce i am not exposed to these kind of scenarios.So please help me out.
I am sharing my code.Thanks in advance.


The dropdown in red box should come only if select any of above radio button.The text in yellow box should come only after Clicking Click Me button.
*********Vfpage******************

<apex:page id="pp" title="Movie's Now" controller="Movies" showHeader="false">
  <Apex:form >
   <apex:pageBlock title="Welcome to MOvie Selection Process">
   
   <!--   For Selecting Movie and Play        -->
      <apex:selectRadio value="{!s}" rendered="true">
        <apex:selectOptions value="{!items}"/>
      </apex:selectRadio><p/>
         <apex:actionSupport event="onclick" action="{!Click}" ReRender="in" >
            <apex:param assignTo="{!s}" name="ss" value="{!Movies}" />
         </apex:actionSupport>
           <!--<apex:actionFunction action="{!MovieSelection}"  name="MovieLocked" /> 
           <apex:actionFunction action="{!EventSelection}"  name="EventLocked" />-->
           
           <!-- for dropdown list -->
            <apex:selectList size="1" value="{!newmovies}" multiselect="false" rendered="{!newMovies!=null}" onclick="MovieSelection">
                <apex:selectOptions value="{!Movies1}"/>
                <apex:actionSupport event="onchange" reRender="in" action="{!MovieSelection}"/>
            </apex:selectList>
        
        
         <apex:selectList size="1" value="{!newEvents}" multiselect="false" rendered="{!newEvents!=null}">
            <apex:selectOptions value="{!Events1}"/>
        </apex:selectList>
        
        <!-- command button -->
        <apex:commandButton value="$$Click Me$$" action="{!Click}" rerender="out" status="status"/>
   </apex:pageBlock>
   
   
   <apex:outputpanel id="in" rendered="{!lmve.size != 0 && newEvents!=null || newmovies!=null}">
    
                              <apex:actionSupport event="onchange" rerender="out" status="status"/>
                          
   </apex:outputpanel>
   
   
   
   <apex:outputPanel id="out" rendered="{!lmve.size != 0}">
           <apex:outputText value="{!lmve}">The selected option is "{!s}"</apex:outputText>
           <apex:outputText value="{!lmve}">The selected Movie is "{!Events}"</apex:outputText>
          
     </apex:outputPanel> 
  </Apex:form>
</apex:page>
 
************Controller class**********************


public class Movies
{

  public String s{get;set;}
  public String name{get;set;}

  public boolean Movieflag{get;set;}
  public boolean Eventflag{get;set;}
  public  List<Movie__c> lmve{Get;Set;}
  public String Events{get;set;}
  public String Movies { get; set; }
  public boolean displayflag{get;set;}
  public List<SelectOption> options1{get;set;}
  public List<SelectOption> options2{get;set;}
  
  
  String[] newmovies= new String[]{};
  
  public String[] getnewmovies() {
            return newmovies;
        }
            
        public void setnewmovies(String[] newmovies) {
            this.newmovies= newmovies;
        }


  String[] newEvents=new String[]{};
  
  public String[] getnewEvents() {
            return newEvents;
        }
            
        public void setnewEvents(String[] newEvents) {
            this.newEvents= newEvents;
        }
  
  public Movies(){
   System.Debug('Helllo');
  }
  
  
  public PageReference Click()
  {
   Eventflag=false;
   if(s!=null && s.equalsIgnoreCase(Movies)){
    Movieflag=true;
   }
   
   else if(s!=null &&s.equalsIgnoreCase(Events)){
   Eventflag=true;
   }
   
   List<Movie__c> lmve=new List<Movie__c>();
   if(s!=null)
   lmve=[SELECT Id,Cinemas__c,name__c,Price__c,Tickets__c from Movie__c];
   
   return null;
  
  }
  
  
   public pagereference MovieSelection() 
    {
        Events=null;
        ApexPages.addMessage(new ApexPages.Message(ApexPages.Severity.confirm,'You Selected a movie'));
        return null;  
    }
    
    
    public pagereference EventSelection() 
    {
        Movies=null;
        ApexPages.addMessage(new ApexPages.Message(ApexPages.Severity.confirm,'You Selected an Event'));
        return null;  
    }
  

   public List<SelectOption> getItems() {
        List<SelectOption> options = new List<SelectOption>(); 
        options.add(new SelectOption('Movies','Movies'));
        options.add(new SelectOption('Events','Events')); 
        return options; 
    }
    
    public List<SelectOption> getMovies1() {
            List<SelectOption> options1 = new List<SelectOption>();
            options1.add(new SelectOption('Bahubali','Bahubali'));
            options1.add(new SelectOption('Rangitaranga','Rangitaranga'));
            options1.add(new SelectOption('BhaiJan','BhaiJan'));
            return options1;
        }
    public List<SelectOption> getEvents1() {
            List<SelectOption> options2 = new List<SelectOption>();
            options2.add(new SelectOption('abc','abc'));
            options2.add(new SelectOption('def','def'));
            options2.add(new SelectOption('sss','sss'));
            return options2;
        }
    

}

 
HI all,

Can anyone help me,My requirement is i want to display 3 columns 1st column only radio button,2nd column account name and 3rd column account number.when i click that radio button beside that account name, i should get related contact information of that  particular account
Well, all I can say is that it does add an account, and if you send it a blank string, it does return a NULL, so I am wondering what I did wrong. Here is the code:

public class AccountHandler {

    public static ID  insertNewAccount(String myStr) {
        try {
            Account acct = new Account(Name=myStr);
            insert acct;
            
            return(acct.id);
            
        } catch (DmlException e) {
            System.debug('A DML exception has occurred:' + e.getMessage());
            return(NULL);
        }
        
    }
            
}

Thanks in advance for the help,

Feeling dumb