• sreedharp286
  • NEWBIE
  • 0 Points
  • Member since 2013

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

Hi,

 

<apex:page Controller="selectst" >
<apex:form >
<apex:selectList value="{!str}">
<apex:selectOptions value="{!values}" />





</apex:selectList>

</apex:form>
</apex:page>

 

 

 

Controller :--------------

public class selectst {


public List<SelectOption> getValues() {
List<SelectOption> options = new List<SelectOption>();
options.add(new SelectOption('US','US'));
options.add(new SelectOption('CANADA','Canada'));
options.add(new SelectOption('MEXICO','Mexico'));
return options;
}

 

public string str {get;set;}

}

 

Can any one help me?

 

How to write Apex class and test class  based on below conditions?

     A) Username should be unique.

     B) Username and password should not be same.

     C) Password should have alphanumeric characters.

 

  Can any one help me ?

Write controller class and test class  based on below conditions?

     A) Username should be unique.

     B) Username and password should not be same.

     C) Password should have alphanumeric characters.

 

  Can any one help me ?

 

 

public  class calculator1{

public integer num1{get;set;}
public integer num2{get;set;}
public integer num3{get;set;}

 
 
public void add(){
num3=num1+num2;
//EmailConformation1 E=new EmailConformation1();
//E.sendMail();
}
}

 

hi 

i am trying to send below code as package

 

public  class calculator1{

public integer num1{get;set;}
public integer num2{get;set;}
public integer num3{get;set;}

 
 
public void add(){
num3=num1+num2;
//EmailConformation1 E=new EmailConformation1();
//E.sendMail();
}
}

 

 

but getting  error 

Class.calculator1.add: line 10, column 1 Class.MyTestClass34.test11: line 13, column 1

 

 Class.calculator1.add: line 10, column 1 Class.MyTestClass34.test11: line 13, column 1

 

 

please help me quickly

Hi,

 

<apex:page Controller="selectst" >
<apex:form >
<apex:selectList value="{!str}">
<apex:selectOptions value="{!values}" />





</apex:selectList>

</apex:form>
</apex:page>

 

 

 

Controller :--------------

public class selectst {


public List<SelectOption> getValues() {
List<SelectOption> options = new List<SelectOption>();
options.add(new SelectOption('US','US'));
options.add(new SelectOption('CANADA','Canada'));
options.add(new SelectOption('MEXICO','Mexico'));
return options;
}

 

public string str {get;set;}

}

 

Can any one help me?

 

 

 

public  class calculator1{

public integer num1{get;set;}
public integer num2{get;set;}
public integer num3{get;set;}

 
 
public void add(){
num3=num1+num2;
//EmailConformation1 E=new EmailConformation1();
//E.sendMail();
}
}