• Pravesh Mehta 3
  • NEWBIE
  • 0 Points
  • Member since 2015

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

I have created a force.com site. After that I set the 'Public access setting', read/write permission on contact object,other objects required. When I use my site, I am inserting some data in custom object which is having lookup on contact. It is giving me below error 

"First exception on row 0; first error: INSUFFICIENT_ACCESS_ON_CROSS_REFERENCE_ENTITY, insufficient access rights on cross-reference"

Contact object is also having some record types. Is that creating some problem. 
When I query the contact object like  Integer cont = [Select count() from contact];
It is returning 0 as result while I have many contacts in object. Please suggest me what permissions I am missing here.

 
Can we schedule job every 10 min for a class which is in a managed package installed in our organisation. It gives error 'Type is not visible' when we run   -  System.schedule('Job Name', '0 0 * * * ?', new class());
Hi,

I have created a force.com site. After that I set the 'Public access setting', read/write permission on contact object,other objects required. When I use my site, I am inserting some data in custom object which is having lookup on contact. It is giving me below error 

"First exception on row 0; first error: INSUFFICIENT_ACCESS_ON_CROSS_REFERENCE_ENTITY, insufficient access rights on cross-reference"

Contact object is also having some record types. Is that creating some problem. 
When I query the contact object like  Integer cont = [Select count() from contact];
It is returning 0 as result while I have many contacts in object. Please suggest me what permissions I am missing here.

 
Can we schedule job every 10 min for a class which is in a managed package installed in our organisation. It gives error 'Type is not visible' when we run   -  System.schedule('Job Name', '0 0 * * * ?', new class());
Hi,
how can i load data when click on particular tab.
I create visualforce (page) tab when i ckick tab but the page is not refresh (inside tab i use <apex:include p"></apex:include>).How can i do please giv me ur solution..
-----------------------------
Visualforce page:
<apex:page standardController="Case" showHeader="true" tabStyle="case" sidebar="false">

 <style>
    .activeTab {background-color: #B0E2FF; color:black; background-image:none }
    .inactiveTab { background-color: lightgrey; color:black; background-image:none}
 </style>
     <apex:tabPanel switchType="server" selectedTab="tabdetails" 
                  id="CaseTabPanel" tabClass="activeTab" inactiveTabClass="inactiveTab">
        <apex:tab label="Unclaimed Ticket" name="OpenActivities"  id="tabOpenAct">
        <apex:include pageName="UnclaimedTicketPage"/>
        </apex:tab>
        <apex:tab label="Claimed Ticket" name="OpenActivitiesg" id="claim_id"> 
        <apex:include pageName="ClaimedTicketPage"/>
        </apex:tab>
        <apex:tab label="Patient view" name="OpenActivities3" id="tabOpenAct126">
        <apex:include pageName="protectedSearch3"/>
        </apex:tab>
     </apex:tabPanel>
<script type="text/javascript" language="javascript">
    if(jQuery) {
        jQuery.noConflict();
    }
    var $jq = jQuery.noConflict();
    function testrun() {
    cler();
    }
    $jq(document).ready(function() {
    $jq('[id$=claim_id]').click(function() {

    //$jq('window').location.reload(true);
    $jq(document).location.reload();
    });
    });
</script>
</apex:page>
------------------------------------------
 

Hi everyone,

 

I am new developer in Salesforce. I'm using Salesforce for two month now. I have to do a project for my studies, so it's only a prototype. The project will be used as a mobile application.

The application is about events and fairs.

Now i want to have Page, which lists every stand on the fair. With a click you will get more information about the stand like location, name etc...

I have a problem with passing the parameters.

I've got 2 Pages. The standList and standInfo.  How can I connect both Pages? I hope you can understand my explanation.

 

Here are my Pages and Controllers:

 

LIST:

<apex:page standardController="Account" extensions="standList_Controller" showHeader="false">
<apex:form >
    <head>
        <meta charset="utf-8"/>
        <meta name="viewport" content="width=device-width, initial-scale=1"/>
        <link rel="stylesheet" href="http://code.jquery.com/mobile/1.3.2/jquery.mobile-1.3.2.min.css"/>
        <script type="text/javascript" src="http://code.jquery.com/jquery-1.9.1.min.js"></script>
        <script type="text/javascript" src="http://code.jquery.com/mobile/1.3.2/jquery.mobile-1.3.2.min.js"></script>
        
        <style type="text/css">
              
            #caption2{
                font-size: 15px;
            }
            
            #caption3{
                color: #06FC01;
                font-size: 15px;
                vertical-align: middle;
                weight: 40px;
            }
        </style> 
    </head>
    <body>
        <div data-role="page" id="standInfo" data-theme="b">
        
            <div id="header" data-role="header" data-theme="b">
                <a id="zurueck" data-icon="arrow-l" class="ui-btn-left" style="margin-top:10px;" href="SlidingMenu">Zurück</a>
                <h1 align="center" style="margin-top:15px; font-size:20px;">Stand Liste</h1>
            </div>
            
            <div id="content" data-role="content" > 
               <table border="1" width="100%">              
                  <tr id="caption2">
                    <th><h2>Name</h2></th>
                    <th><h2>Messestand</h2></th>
                    <th><h2>Kategorie</h2></th>
                  </tr>
                  
                  <apex:repeat var="accs" value="{!accounts}">
                    <tr id="caption2">
                       <td onclick="location.href='StandInfo?name=' + {!accs.Name}';" style="cursor:pointer;">{!accs.Name}</td>
                        <td>{!accs.located__c}</td>
                        <td>{!accs.category__c}</td>
                    </tr>
                  </apex:repeat> 
               </table>
            </div> 
            
        </div>
    </body>
  </apex:form>
</apex:page>

 Controller:

 

global with sharing class standList_Controller {

    public standList_Controller(ApexPages.StandardController controller) {

    }
    
    List<Account> accounts;

    public List<Account> getAccounts() {

        if(accounts == null) accounts = [select name, located__c, category__c from account]; // limit 1  where category__c != ''

        return accounts;

    }  
    
    public PageReference test(){
        return null;
    } 
}

 

Standinformation:

 

<apex:page standardController="Account" extensions="StandInfo_Controller" showHeader="false">
  <apex:form >
    <head>
        <meta charset="utf-8"/>
        <meta name="viewport" content="width=device-width, initial-scale=1"/>
        <link rel="stylesheet" href="http://code.jquery.com/mobile/1.3.2/jquery.mobile-1.3.2.min.css"/>
        <script type="text/javascript" src="http://code.jquery.com/jquery-1.9.1.min.js"></script>
        <script type="text/javascript" src="http://code.jquery.com/mobile/1.3.2/jquery.mobile-1.3.2.min.js"></script>
        
        <style type="text/css">
              
            #caption2{
                font-size: 15px;
            }
            
            #caption3{
                color: #06FC01;
                font-size: 15px;
                vertical-align: middle;
                weight: 40px;
            }
        </style> 
    </head>
    <body>
        <div data-role="page" id="standInfo" data-theme="b">
        
            <div id="header" data-role="header" data-theme="b">
                <a id="zurueck" data-icon="arrow-l" class="ui-btn-left" style="margin-top:10px;" href="SlidingMenu">Zurück</a>
                <h1 align="center" style="margin-top:15px; font-size:20px;">{!account.Name}</h1>
            </div>
            
            <div id="content" data-role="content">
                <table border="1" width="100%">              
                  <tr id="caption2">
                    <td><h1>Headquarter</h1></td>
                    <td>{!account.Headquarter__c}</td>
                  </tr>
                  
                  <tr id="caption2">
                    <td><h2>Employees</h2></td>
                    <td>{!account.NumberOfEmployees}</td>
                  </tr>
                  
                  <tr id="caption2">
                    <td><h2>located on fair</h2></td>
                    <td>{!account.located__c}</td>
                  </tr>
                  
                  <tr id="caption2">
                    <td><h2>Contact Person</h2></td>
                    <td>{!account.ContactPerson__c}</td>
                  </tr>
                
                  <tr id="caption2">
                    <td><h2>Website</h2></td>
                    <td>{!account.Website}</td>
                  </tr>
                 </table>
            </div> 
            
        </div>
    </body>
  </apex:form>
</apex:page>

 Controller:

global with sharing class StandInfo_Controller {

    public StandInfo_Controller(ApexPages.StandardController controller) {

    }
    
    Account account;
    
    public Account getAccount() {
        if(account == null) account = [select name, phone, website, ContactPerson__c, Headquarter__c, located__c, NumberOfEmployees FROM Account
                WHERE id = :ApexPages.currentPage().getParameters().get('name')];
        return account;
    }
    
    public PageReference test(){
         PageReference page = new PageReference('http://company-developer-edition.eu2.force.com/SlidingMenu');
         page.setRedirect(true);
         return page;
    }
}