visualforce

How to implement “Save & New” functionality in a VisualForce Page

我与影子孤独终老i 提交于 2019-12-30 10:14:06
问题 I know that this is how to save a record <apex:commandButton action="{!save}" value="Save"/> Now I want a button to save the current record and reset the form to input another record. Something like this... <apex:commandButton action="{!SaveAndNew}" value="Save & New"/> 回答1: The URL for the new record page is the {org URL}/{3 letter object prefix}/e?". You could define your save method as follows, where m_sc is a reference to the standardController passed to your extension in it's constructor

Is there any option to connect other db in the salesforce platform? [closed]

只愿长相守 提交于 2019-12-25 08:23:26
问题 It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center. Closed 7 years ago . I would like to know whether there any option to connect to the external db in the salesforce platform. Thanks, Easwar 回答1: You cannot use an external database for your Salesforce data, if that's what you're

make a select object field in salsforce

笑着哭i 提交于 2019-12-25 02:02:32
问题 First, I'm just a beginner in salesforce and started to learn visualforce page using apex, basically I have the default object "people", and many records in it now is to write a "payment" visual page to allow people to select the people record they are master-details relationship, what apex tag should I use in both page side and apex class? similar like time selector one below: page code: <apex:inputField value="{!proxyObject.closeDate}"/> class: opportunity o = new Opportunity(); public

How to Deploy an existing project in Force.com

大城市里の小女人 提交于 2019-12-24 12:44:13
问题 i am using eclipse IDE i am provided with an src folder which contains code i have to save this code into my development org. How i am trying to approach this 1.first i created a Force.com project 2.then i copy given src(Ctrl+c) folder and paste(Ctrl+v) in to my project in eclipse 3. i added metadata components by right clicking on project Force.com >Add/remove metadata components 4.then i right click on my project Force.com >Deploy to server i am getting failure error Deploy Results: File

How To Capture ISP Name?

独自空忆成欢 提交于 2019-12-24 03:27:07
问题 How do I capture the user's ISP name in Salesforce.com? The solution can be in JavaScript of in Salesforce.com such as Apex/VisualForce Pages. Example of a website which captures the user's ISP name is: http://whatismyipaddress.com/ Thanks! 回答1: You'll need to query a GeoLocation provider database that has the ISP provider information. Here is a list of providers listed on the page you've linked in your question: http://whatismyipaddress.com/geolocation-providers They usually require you to

Salesforce consuming XML and display data in Visualforce report

女生的网名这么多〃 提交于 2019-12-23 03:05:03
问题 Firstly, this question requires a bit of introduction so please bear with me. The high level is that I am connecting to a outside web service which will return some XML to my apex controller. The idea is that I want to display the XML returned into a nice tabular format in a VisualForce page. The format of the XML coming back will look something like this: <Wrapper><reportTable name='table_id' title='Report Title'> <row> <Element1><![CDATA[campaign_id]]></Element1> <Element2><![CDATA[577373]]

Debugging Schedulable Job in apex salesforce

雨燕双飞 提交于 2019-12-22 11:28:33
问题 i am trying to run a schedulable job i never used schedulable jobs in salesforce here is my code global class scheduledMerge implements Schedulable{ global void execute(SchedulableContext SC) { System.debug('Hello World'); } } created a cusom controller public class schedulableMerge{ public schedulableMerge(){ } public PageReference Hello(){ scheduledMerge m = new scheduledMerge(); String sch = '0 10 * * 1-12 ? *'; system.schedule('Merge Job', sch, m); return null; } } and visualforce page is

Uncaught TypeError: Cannot call method 'noConflict' of undefined

◇◆丶佛笑我妖孽 提交于 2019-12-22 05:13:22
问题 I am trying to create a widget using javascript and jquery in SalesForce, I was stuck with a ERROR: Uncaught TypeError: Cannot call method 'noConflict' of undefined Below is my code which i am using (function() { // Localize jQuery variable var $j; /******** Load jQuery if not present *********/ if (window.jQuery === undefined || window.jQuery.fn.jquery !== '1.4.2') { var script_tag = document.createElement('script'); script_tag.setAttribute("type","text/javascript"); script_tag.setAttribute(

Custom Button or Link to a Visualforce page with a custom controller

三世轮回 提交于 2019-12-21 13:32:21
问题 I have a Visualforce page using a custom controller that is used to edit multiple records under an opportunity. I'd like to create a custom button or link from Opportunities to this Visualforce page. Currently the link looks like: /apex/ExamplePage?oppId={!Opportunity.Id} This works fine in the development sandbox, but when it is deployed as part of a managed package the link breaks as the page reference doesn't have the namespace prefix. I found the post Managed Package Redirecting Problem

How to implement “Cancel” functionality in a VisualForce Page

坚强是说给别人听的谎言 提交于 2019-12-21 12:03:50
问题 I know that this is how to save a record <apex:commandButton action="{!save}" value="Save"/> I want a button to NOT save the current record (ie. Cancel) and navigate to the list of saved record (ie. list of objects for that object type). Something like this... <apex:commandButton action="{!cancel}" value="Cancel"/> 回答1: The list view for an object is your base URL / the 3 letter prefix for your object / o, for example: https://na1.salesforce.com/a0C/o So you could just create an action method