• Rameshkannan
  • NEWBIE
  • 0 Points
  • Member since 2010

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

Hi ,

 

As I am new to Apex Triggers..

 

Please guide me ,

 

I am using account object and accountsetup object.

 

 Account object is the master and the account setup object is the child.

 

I have a custom field in both objects.

 

If the custom field in the account setup object  is created/updated/deleted , the custom field in the account object  should be updated with the same value.

 

Any ideas!!!

 

 

regards

Ramesh

 

 

 

 

 

 

 

Hi ,

 

How to invoke the  text from a  text file which is available in the  documents tab in visualforce page.

 

 

 

ramesh

 

Hi all,

Please check the code and reply me .

The problem is after user login to the site . it should be redirected to " hpage"(vf page which will act as a homepage)

In this case , i couldnot be able to redirect to that page.

genius pls help me out .

Code below :

global class LoginController {
    global String username {get; set;}
    global String password {get; set;}

    global PageReference login() {
        String startUrl = System.currentPageReference().getParameters().get('hpeppdemo-developer-edition.ap1.force.com/SiteLogin?StartURL=/Welcomepage/hpage');
        return Site.login(username, password,'hpeppdemo-developer-edition.ap1.force.com/SiteLogin?StartURL=/Welcomepage/hpage');
    }
    
        global LoginController () {}
    
    global static testMethod void testSiteLoginController () {
        // Instantiate a new controller with all parameters in the page
        SiteLoginController controller = new SiteLoginController ();
        controller.username = 'test@salesforce.com';
        controller.password = '123456'; 
                
        System.assertEquals(controller.login(),null);                           
    }    
}

Whether the format of the start url is correct ?



Regards
Ramesh

Hi ,

 

How to invoke the  text from a  text file which is available in the  documents tab in visualforce page.

 

 

 

ramesh

 

Hi all,

Please check the code and reply me .

The problem is after user login to the site . it should be redirected to " hpage"(vf page which will act as a homepage)

In this case , i couldnot be able to redirect to that page.

genius pls help me out .

Code below :

global class LoginController {
    global String username {get; set;}
    global String password {get; set;}

    global PageReference login() {
        String startUrl = System.currentPageReference().getParameters().get('hpeppdemo-developer-edition.ap1.force.com/SiteLogin?StartURL=/Welcomepage/hpage');
        return Site.login(username, password,'hpeppdemo-developer-edition.ap1.force.com/SiteLogin?StartURL=/Welcomepage/hpage');
    }
    
        global LoginController () {}
    
    global static testMethod void testSiteLoginController () {
        // Instantiate a new controller with all parameters in the page
        SiteLoginController controller = new SiteLoginController ();
        controller.username = 'test@salesforce.com';
        controller.password = '123456'; 
                
        System.assertEquals(controller.login(),null);                           
    }    
}

Whether the format of the start url is correct ?



Regards
Ramesh