• Najoop
  • NEWBIE
  • 25 Points
  • Member since 2008

  • Chatter
    Feed
  • 1
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 19
    Questions
  • 14
    Replies

 

Hi,

 

we are trying to transition from Self service portal to Customer Portal (yeah, we are still on SSP) and do not want to create new users in customer portal. we would be transitioning 400+ users and dont want to reset passwords for all of them when moved to customer portal.

 

is there any way we can create same users in customer portal as in SSP w/o resetting passwords. we want it to be seamless for our customers.

 

thanks for any help

 

Poojan.

  • November 29, 2010
  • Like
  • 0

Hi,

 

I have customer portal where they can log a case through UI. I am developing ASP.NET application where through salesforce API customer will able to enter username and password. API will authenticate the credential.

 

I am able to authenticate the use. But while creating Case through code I am getting error "INVALID_SESSION_ID: Self Service User Sessions are not valid for use with the API"

 

How can I solve this issue.?

 

Thanks

  • August 26, 2010
  • Like
  • 0

 

Hi,

 

we have exposed the SFDC CRM content on customer portal. but the header/footer on content tab does not consumer the style sheets for other customer portal pages. Is there a way to configure it?

 

also, can we change the content Tab name to something else. I figure that we can not and may need to use apex.

 

Any help is appreciated.

 

thanks,

 

Hi,

 

We are trying to put online trainings on salesforce content (documents has limitation of 15MB). the training are .swf files which does not have preview functionality and users needed to download and view it. we are trying to create a VF page that would embed the links and when clicked open it up in the browser where users can play it without the need to download on their machines.

 

The problem is we are not able to locate the exact location of the files uploaded on content.  Does anyone have any idea on how to approach this issue.

 

Thanks,

 

 

Hi,

 

I am trying to highlight the recent items in the list views that are exposed on customer portal.

 

example - In the Knowledge base list view i want to highlight the latest 5 articles in green color or with some indicator that can highlight them.

 

anyone have any ideas. this would be a great help with rather rigid sf in this aspect.

 

appreciate all help

 

thanks

  • April 21, 2010
  • Like
  • 0

Hi,

 

We need to preview flash type SF content in browser. Is there any way to do this as salesforce documentation states only word, excel, ppt and pdf can be previewed inline.

 

any ideas.

 

thanks,

Poojan.

  • March 23, 2010
  • Like
  • 0

 

Hi,

 

I am trying to write a html s-control (yeah, still writing s-controls) that shows whether the case owner is active in routing or not on the case detail page. for some reason it is not working as expected.

 

I need to do this as User fields are not available in formula.

 

it just fails (undefined message) when the case owner is a queue and also does not validates the value.

I must be missing something here or logic ay not be correct.

 

here is the code.

 

any help is appreciated. thanks.

 

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<link href="/dCSS/Theme2/default/common.css" type="text/css" media="handheld,print,projection,screen,tty,tv" rel="stylesheet" >
<link href="/dCSS/Theme2/default/custom.css" type="text/css" media="handheld,print,projection,screen,tty,tv" rel="stylesheet" >
<html>
<head>
<script src="/soap/ajax/17.0/connection.js" type="text/javascript"></script>
<script type="text/javascript" src="/js/functions.js"></script>
<script>
function resizeIframe()
{
var thisWindow = window.name;
if(thisWindow)
{
var iframes = parent.document.getElementsByName(thisWindow);
if (iframes && iframes.length == 1)
{
var height = document.body.scrollHeight;
iframes[0].style.height = height + "px";
}
}
}
function Init()
{
try
{
var SearchString="Select Assignment_Group_Active__c from User where Id = '{!Case.OwnerId}'";
var queryResults = sforce.connection.query(SearchString);
var queryRecords = queryResults.getArray('records');
document.getElementById("mainBody").innerHTML = queryRecords.length;
var txtOutput = "";
txtOutput = "<table width='100%' border='0' cellspacing='0' cellpadding='0'>";
txtOutput = txtOutput + "<tr class='headerRow' height=15>";
var active = queryRecords[0].Assignment_Group_Active__c;
if ( queryRecords.length <> 1 ) {
txtoutput = txtOutput + "<td bgcolor=" + "#F3F3EC" + ">" + 'Invalid owner for routing' + "</td>";
}
if ( queryRecords.length ==1 )
{
txtoutput = txtOutput + "<td bgcolor=" + "#F3F3EC" + ">" + "<img src=" + "/img/samples/light_green.gif" + " height=15 width =28>" + active + "</td>";
}
txtOutput = txtOutput + "</tr>";
txtOutput = txtOutput + "</table>";
document.getElementById("mainBody").innerHTML = txtoutput;
}
catch(error)
{
alert(error.faultline);
}
}
</script>
</head>
<body id="mainBody" onload="Init();resizeIframe()">
<div class="bPageBlock secondaryPalette" style="border-top:0px; border-bottom:0px; margin-bottom:0px; padding-bottom:0px">
<div class=pbBody>
<div class=pbSubsection>
<div id="mainBody">
</div>
</div>
</div>
</div>
</body>
</html>

 

  • March 15, 2010
  • Like
  • 0

Hi,

 

 

I am trying to validate the picklist values on case page with fields on asset page.

 

we have a picklist with values (product names) that customers need to select while loggin cases and we need to restrict these values based on whether the product is under active maintenance.

 

Is there any way we can include validated values in the picklist?

 

also, is there any way I can indicate on internal case page whether this product has active status by validating it from asset for that account. this would help reps to know whether they need to respond to this case rather than going to asset to verify.

 

any hep is appreciated.

 

Najoop.

 

  • March 15, 2010
  • Like
  • 0

Hi,

 

We have self service portal and customer portal enabled.We want to route the specific users to Self service portal or Customer portal based on their profiles/ login information. Any help anyone can provide would be helpful.

 

A VF page with login authentication and routing to specific portal home page OR something else. please provide some directions to get this started.

 

thanks.

  • March 11, 2010
  • Like
  • 0

Hi,

 

I have a custom Field on case. I want to create a workflow to update this field if a specific condition is true.

 

this custom field has validation trigger.

 

When I am trying to create the workflow this field(custom field with validation rule) is not available in selection. I use the adance tab to use this field but then it is not available to update and I try for field update rule.

 

Any ideas why this is happening and a way to do this.

 

Thanks,

  • December 21, 2009
  • Like
  • 0

 

Hi,

 

Still learning Apex and there seem to be a problem with this code below.

 

getting error 

 

Error: Compile Error: unexpected token: '{' at line 7 column 62 
 
 any help/direction is appreciated.

 

Thanks

 

 

 

trigger CaseCloseTrigger on Case (after update) {

Case[] cs = Trigger.new;

Set<ID> cseIds = new Set<ID>();

 

// Get suggested solution on case and update solutionstatus field for dashboard

 

cse = [select SolutionID from CaseSolution where CaseId = {!Case.id};

 

if (Cse != NULL){

cs.ClosedKBStatus__c = 'Closed with KB';

}

update cse;

 

 

 

  • November 30, 2009
  • Like
  • 0

Hi,

 

Can we create a Apex trigger to update a field on case whenever a new KB is referenced to that case?

 

I guess yes, and I tried to write one but no luck.

 

Thanks

  • October 26, 2009
  • Like
  • 0

Hi,

 

I am trying to create a button or drop down to select a template when reps are adding new comment on the case. this template willpopulate the case comment box with some merge fields. something similar to sending an email. we have some standard responses for situations and do not want reps to type whole thing again.

 

any way I can do this without coding..like using formula, javascript button overrides etc....

 

thanks,

Poojan.

  • August 24, 2009
  • Like
  • 0

I am trying to display a msg when number of records in the list is 0.

 

but it is displaying on page load.

 

here is the code.

 

Public class Mycontroller {
   
    String searchText;
    List<Account> results;
    List<Case> Score = new List<Case>();
    String SetAcc;
    List<FeedBack__c> fback ;
       
    Public string getSearchtext(){
        return searchText;
        }
   
     Public PageReference doSearch () {
        results = (List<Account>) [FIND :searchtext RETURNING Account(ID, Name, Account_type__C)][0];
        return null;
        }
   
       
    Public void setSearchText (String s) {
        searchtext = s;
        }
   
    Public List<Account> getResults() {
        return results;
        }
   
    Public List<Case> getScore() {
        Score = [select Account.Name, casenumber, Solution_Type__C, ClosedDate, Priority from case where Account.ID = :ApexPages.currentPage().getParameters().get('aid') and status = 'Closed' limit 10];
        if (Score.size() == 0 ){               
                ApexPages.addmessage(new ApexPages.message(ApexPages.severity.info,'No Records Found'));
                return null;
                }
        return Score;
        }
      
  
   
    Public List<Feedback__c> getfback() {
        fback = [select Case__c, TAM__c, Account__c, Score__c from feedback__c where Account__c = :ApexPages.currentPage().getParameters().get('aid')];
        return fback;
        }
 
  }

 

Still learning , any help is appreciated

Hi,

 

I am trying to code my first VF page and am stuck. gone through documentations and guides and community.

if anyone can help with this , would appreciate.

 

I am trying to show a pageblock based on the results of first query results. Searching for accounts. when clicked on account Name, show details about the cases in another panel.

 

I know I am doing something wrong but dont know what.

 

here is my code

markup

 

<apex:page controller="Mycontroller" >
<apex:form >
    <apex:pageBlock id="block">
        <apex:pageBlockSection >
            <apex:pageBlockSectionItem >
            <apex:outputLabel for="searchText">Search Account</apex:outputLabel>
                <apex:panelGroup >
                <apex:inputText id="searchText" value="{!searchText}"/>
                <apex:commandButton value="Go!" action="{!doSearch}" rerender="block" status="status"/>
                </apex:panelGroup>
            </apex:pageBlockSectionItem>
        </apex:pageBlockSection>
        <apex:actionStatus id="status" startText="Processing..."/>
        <apex:pageBlockSection title="Account Detail Results" id="results" columns="2">
        <apex:pageBlockTable value="{!results}" var="l" rendered="{!NOT(ISNULL(results))}">
               <apex:actionSupport event="ondblClick" action="{!getScore}" reRender="Score">
               <apex:param name="aid" value="{!l.Name}"/>
               </apex:actionSupport>
             <apex:column value="{!l.Name}"/>
             <apex:column value="{!l.Account_Type__c}"/>
        </apex:pageBlockTable>
        </apex:pageBlockSection>
        </apex:pageblock>
        </apex:form>               
        <apex:outputPanel id="Score" rendered="true" >
        <apex:pageblock>
        <apex:pageBlockSection title="Score Card"  id="results" columns="4" rendered = "True">
        <apex:pageBlockTable value="{!Score}" var="S" rendered="{!NOT(ISNULL(Score))}">
            <apex:column value="{!S.Account.Name}"/>
            <apex:column value="{!S.casenumber}"/>
            <apex:column value="{!S.Solution_Type__c}"/>
            <apex:column value="{!S.ClosedDate}"/>
        </apex:pageBlockTable >
        </apex:pageBlockSection >
        </apex:pageBlock>
        </apex:outputPanel>
</apex:page>

 

Controller

 

Public class Mycontroller {
       
    String searchText;
    List<Account> results;
    List<Case> Score;
       
    Public string getSearchtext(){
        return searchText;
        }
       
    Public void setSearchText (String s) {
        searchtext = s;
        }
    
           
    Public List<Account> getResults() {
        return results;
        }
   
    Public List<Case> getScore() {
        Score = [select Account.Name, casenumber, Solution_Type__C, ClosedDate from case where Account.Name = :searchText and status = 'Closed' limit 10];
        return Score;
        }
       
    Public PageReference doSearch () {
        results = (List<Account>) [FIND :searchtext RETURNING Account(ID, Name, Account_type__C)][0];
        return null;
        }
  }

 

I also wanted to move away from :searchtext and pass aid from markup to this query, not sure how to do it.

 

I also tried this rendered function but did not appear to resolve what I am trying to do.

 

 Public boolean getRendered() {
        Boolean render = (Score == null || results.size() == 0 );
        return render;
        }

 

 

any help anyone can provide is appreciated. been on this for last 3 days.

 

thanks a lot

Poojan.

Still learning apex. trying to update all contacts for a Account if Account type field is set to customer-inactive. 

this does not work when account is updated but works when a contact is updated.

Not sure why. any help is appreciated.

 

trigger code below.

 

 

trigger updatefields on Account (after insert)

{

for (Account accs : Trigger.new)

 {

  if (accs.Account_type__C == 'Customer-Inactive' ) {

  Contact cons = [SELECT Id FROM Contact WHERE AccountId = :accs.ID];

  Cons.HasOptedOutOfEmail = True;

  update cons;

  }

  }

}

I am trying to add some text for new user registration on self service portal login page. I tried checking the style sheets but was not able to find an option. we are still on the older Selfservice portal and not on Customer portal.

 

Is there a way this can be achieved?

Hi, I am trying to write a S-control which returns the number of SelfService Contacts for the Account. I am not able to get this query worked. SELECT Id from selfserviceuser where ContactID IN (Select ContactID from Contact where AccountID={!Account.Id}"; I am learning writing Apex and triggers to any help is appreciated. I tried searching the APex guide and cookbook but did not exactly understood how to get this working. it may be incorrect syntax for child to parent relationship query. any help is appreciated. Najoop Poojan.
Hi,
 
I am new to SF APEX, need some help.
 
I have written this trigger to check a check box in Account object whenever a new record is created in custom Object.
Custom object has Account name as related lookup field.
 
TheTrigger is compiled and saved but it never updates the check box when a new record is created in custom object.
 
Any help is appreciated, Poojan
 
this is the code
trigger UpdateAccountCustomAsset on Custom_Asset__c (after insert) {

     for (Custom_Asset__c c: Trigger.new)
       {
        Account a = new Account(Id = c.account__c);
        a.Custom_Asset_available__c = True;
        update a;
        }
}
  • September 02, 2008
  • Like
  • 0

Hi,

 

We are trying to put online trainings on salesforce content (documents has limitation of 15MB). the training are .swf files which does not have preview functionality and users needed to download and view it. we are trying to create a VF page that would embed the links and when clicked open it up in the browser where users can play it without the need to download on their machines.

 

The problem is we are not able to locate the exact location of the files uploaded on content.  Does anyone have any idea on how to approach this issue.

 

Thanks,

 

Hi,

 

We need to preview flash type SF content in browser. Is there any way to do this as salesforce documentation states only word, excel, ppt and pdf can be previewed inline.

 

any ideas.

 

thanks,

Poojan.

  • March 23, 2010
  • Like
  • 0

 

Hi,

 

Still learning Apex and there seem to be a problem with this code below.

 

getting error 

 

Error: Compile Error: unexpected token: '{' at line 7 column 62 
 
 any help/direction is appreciated.

 

Thanks

 

 

 

trigger CaseCloseTrigger on Case (after update) {

Case[] cs = Trigger.new;

Set<ID> cseIds = new Set<ID>();

 

// Get suggested solution on case and update solutionstatus field for dashboard

 

cse = [select SolutionID from CaseSolution where CaseId = {!Case.id};

 

if (Cse != NULL){

cs.ClosedKBStatus__c = 'Closed with KB';

}

update cse;

 

 

 

  • November 30, 2009
  • Like
  • 0

Hi,

 

I am trying to create a button or drop down to select a template when reps are adding new comment on the case. this template willpopulate the case comment box with some merge fields. something similar to sending an email. we have some standard responses for situations and do not want reps to type whole thing again.

 

any way I can do this without coding..like using formula, javascript button overrides etc....

 

thanks,

Poojan.

  • August 24, 2009
  • Like
  • 0

I am trying to display a msg when number of records in the list is 0.

 

but it is displaying on page load.

 

here is the code.

 

Public class Mycontroller {
   
    String searchText;
    List<Account> results;
    List<Case> Score = new List<Case>();
    String SetAcc;
    List<FeedBack__c> fback ;
       
    Public string getSearchtext(){
        return searchText;
        }
   
     Public PageReference doSearch () {
        results = (List<Account>) [FIND :searchtext RETURNING Account(ID, Name, Account_type__C)][0];
        return null;
        }
   
       
    Public void setSearchText (String s) {
        searchtext = s;
        }
   
    Public List<Account> getResults() {
        return results;
        }
   
    Public List<Case> getScore() {
        Score = [select Account.Name, casenumber, Solution_Type__C, ClosedDate, Priority from case where Account.ID = :ApexPages.currentPage().getParameters().get('aid') and status = 'Closed' limit 10];
        if (Score.size() == 0 ){               
                ApexPages.addmessage(new ApexPages.message(ApexPages.severity.info,'No Records Found'));
                return null;
                }
        return Score;
        }
      
  
   
    Public List<Feedback__c> getfback() {
        fback = [select Case__c, TAM__c, Account__c, Score__c from feedback__c where Account__c = :ApexPages.currentPage().getParameters().get('aid')];
        return fback;
        }
 
  }

 

Still learning , any help is appreciated

Hi,

 

I am trying to code my first VF page and am stuck. gone through documentations and guides and community.

if anyone can help with this , would appreciate.

 

I am trying to show a pageblock based on the results of first query results. Searching for accounts. when clicked on account Name, show details about the cases in another panel.

 

I know I am doing something wrong but dont know what.

 

here is my code

markup

 

<apex:page controller="Mycontroller" >
<apex:form >
    <apex:pageBlock id="block">
        <apex:pageBlockSection >
            <apex:pageBlockSectionItem >
            <apex:outputLabel for="searchText">Search Account</apex:outputLabel>
                <apex:panelGroup >
                <apex:inputText id="searchText" value="{!searchText}"/>
                <apex:commandButton value="Go!" action="{!doSearch}" rerender="block" status="status"/>
                </apex:panelGroup>
            </apex:pageBlockSectionItem>
        </apex:pageBlockSection>
        <apex:actionStatus id="status" startText="Processing..."/>
        <apex:pageBlockSection title="Account Detail Results" id="results" columns="2">
        <apex:pageBlockTable value="{!results}" var="l" rendered="{!NOT(ISNULL(results))}">
               <apex:actionSupport event="ondblClick" action="{!getScore}" reRender="Score">
               <apex:param name="aid" value="{!l.Name}"/>
               </apex:actionSupport>
             <apex:column value="{!l.Name}"/>
             <apex:column value="{!l.Account_Type__c}"/>
        </apex:pageBlockTable>
        </apex:pageBlockSection>
        </apex:pageblock>
        </apex:form>               
        <apex:outputPanel id="Score" rendered="true" >
        <apex:pageblock>
        <apex:pageBlockSection title="Score Card"  id="results" columns="4" rendered = "True">
        <apex:pageBlockTable value="{!Score}" var="S" rendered="{!NOT(ISNULL(Score))}">
            <apex:column value="{!S.Account.Name}"/>
            <apex:column value="{!S.casenumber}"/>
            <apex:column value="{!S.Solution_Type__c}"/>
            <apex:column value="{!S.ClosedDate}"/>
        </apex:pageBlockTable >
        </apex:pageBlockSection >
        </apex:pageBlock>
        </apex:outputPanel>
</apex:page>

 

Controller

 

Public class Mycontroller {
       
    String searchText;
    List<Account> results;
    List<Case> Score;
       
    Public string getSearchtext(){
        return searchText;
        }
       
    Public void setSearchText (String s) {
        searchtext = s;
        }
    
           
    Public List<Account> getResults() {
        return results;
        }
   
    Public List<Case> getScore() {
        Score = [select Account.Name, casenumber, Solution_Type__C, ClosedDate from case where Account.Name = :searchText and status = 'Closed' limit 10];
        return Score;
        }
       
    Public PageReference doSearch () {
        results = (List<Account>) [FIND :searchtext RETURNING Account(ID, Name, Account_type__C)][0];
        return null;
        }
  }

 

I also wanted to move away from :searchtext and pass aid from markup to this query, not sure how to do it.

 

I also tried this rendered function but did not appear to resolve what I am trying to do.

 

 Public boolean getRendered() {
        Boolean render = (Score == null || results.size() == 0 );
        return render;
        }

 

 

any help anyone can provide is appreciated. been on this for last 3 days.

 

thanks a lot

Poojan.

Still learning apex. trying to update all contacts for a Account if Account type field is set to customer-inactive. 

this does not work when account is updated but works when a contact is updated.

Not sure why. any help is appreciated.

 

trigger code below.

 

 

trigger updatefields on Account (after insert)

{

for (Account accs : Trigger.new)

 {

  if (accs.Account_type__C == 'Customer-Inactive' ) {

  Contact cons = [SELECT Id FROM Contact WHERE AccountId = :accs.ID];

  Cons.HasOptedOutOfEmail = True;

  update cons;

  }

  }

}

Hi, I am trying to write a S-control which returns the number of SelfService Contacts for the Account. I am not able to get this query worked. SELECT Id from selfserviceuser where ContactID IN (Select ContactID from Contact where AccountID={!Account.Id}"; I am learning writing Apex and triggers to any help is appreciated. I tried searching the APex guide and cookbook but did not exactly understood how to get this working. it may be incorrect syntax for child to parent relationship query. any help is appreciated. Najoop Poojan.

Hi All,

 

I have a requirement that i have to run a report from a visual force page.

I am presently hard coding the report id in the URL.

Can anyone suggest me how to avoid the hard coding and query for the report id.

 

Regards,

Anil

Hi,
 
I am new to SF APEX, need some help.
 
I have written this trigger to check a check box in Account object whenever a new record is created in custom Object.
Custom object has Account name as related lookup field.
 
TheTrigger is compiled and saved but it never updates the check box when a new record is created in custom object.
 
Any help is appreciated, Poojan
 
this is the code
trigger UpdateAccountCustomAsset on Custom_Asset__c (after insert) {

     for (Custom_Asset__c c: Trigger.new)
       {
        Account a = new Account(Id = c.account__c);
        a.Custom_Asset_available__c = True;
        update a;
        }
}
  • September 02, 2008
  • Like
  • 0
Hello
 
I am tring to update the field on the Account , by checking the condition
Every time a new record on custom object is created/updated/deleted i need to check a field in the custom object(the one creating now and the previous records) is true. If it is true then i need to update the Status field on the Account object to "xyz'.
 
if it is false then i need to update the Status field to 'abc'
 
Here i have written the code. but I am getting run time errors. Any ideas?????
 
Lot of times i am getting this exception

System.ListException: Duplicate id in list:



Message Edited by renu on 06-19-2008 11:13 AM

Message Edited by renu on 06-19-2008 11:15 AM
  • June 18, 2008
  • Like
  • 0
Hi
 
I have downloaded some reports from sfdc to my excel using Office tool kit - salesforce.com.
 
I would like to know, is there any way to pass parameters to the reports for getting data from sfdc.
 
Even if it involves vba programming, please let me know.
 
Thanks
Jay
I have a report that shows activity by sales rep over the last week.

Rather than create and maintain a version of the report for each rep, is there a way to create a paramater that takes the login of the user as the filter parameter - so that when a rep logs in, the report is automatically filtered to view only their data?