Webinar Winter '09 Developer Highlights FAQ

Webinar Winter '09 Developer Highlights FAQ

This is the FAQ for the Winter09 Developer Highlights Webinar.

Contents


In the past, I've seen changes in Visualforce syntax between the developer release - and production release - is this likely to be the case again with Winter '09?

Is possible to create Visualforce templates through Apex code?

Visualforce pages can be created from the Setup area or from the Force.com IDE. Winter '09 does not support creating new Visualforce page definitions at runtime from Apex.

When will the new Force.com IDE be available?

The Force.com IDE is scheduled to go GA October 27, 2008. More details can be found at the Force.com IDE page.

Does the Winter '09 lDE support Eclipse 3.4 (Ganymede)?

No, the Force.com IDE has not been tested with Eclipse 3.4, and some users have reported minor issues. We recommend users run the Force.com IDE with Eclipse 3.3.

In the future, will the Force.com IDE release be more in sync with Salesforce releases?

The Force.com IDE release schedule is synchronized with the end of each Force.com Platform upgrade cycle.

Each release of the Force.com IDE is tied to the latest version of the Force.com Platform. For example, the Winter '09 IDE requires a server node running Winter '09 or later. Force.com Platform upgrades typically occur over a series of weeks, during which some server nodes have the latest version and some are still running the previous version. Thus we release the IDE at the end of this upgrade period to minimize confusion among users who are unaware that each new major IDE release cannot connect to older server versions.

Will the Force.com IDE have support for version control systems, like SVN?

Support for version control systems is already provided by the Eclipse Platform, through its Team Synchronization API. Eclipse comes with built-in support for CVS, and all major version control systems have Eclipse plug-ins available. Support for these plug-ins is provided by the vendor.

The Eclipse plug-in for Subversion (SVN) is called subclipse: http://subclipse.tigris.org/install.html

Will the new Force.com IDE plugin work with Adobe Flex Builder, or only on bare Eclipse? At the moment it 'kind of' works with Flex Builder but some features don't seem to (code completion and docs).

Salesforce.com does not specifically support or test the Force.com IDE in conjunction with any third party plug-ins. Please use the forums on developer.force.com to report any issues encountered.

Are there any best practices or certain files that need to be excluded while using Subclipse with the Force.com IDE?

When using the Force.com IDE, it is recommend that you only add the "src" folder in your Force.com project. You do not want to include the "Referenced Packages" folder or the file "salesforce.schema".

After checking out a project from a version control system into a new workspace, you may need to indicate that the project is a Force.com project. To do so, right-click on the project and select Force.com > Add Force.com Nature. If you do this and instead see the option Force.com > Remove Force.com Nature then your project is already correctly configured to use the Force.com IDE plug-in.

The final step is to right-click on the project and select Properties, then select Force.com in the left nav. This page allows you specify the credentials to your Salesforce organization, which are not saved to the version control project.

Can Visualforce template based emails be sent on a scheduled basis ?

Yes - Visualforce Templates are treated just like other email templates. You can create a event-based or time-based workflow to send out a Visualforce Email template.

Will the new Analytics features in the API allow you to execute a report and/or access its data, not just its configuration?

No. Winter '09 adds Analytics types (reports, dashboards, custom report types) to the Metadata API, which allows you to modify the definition/configuration of these components only.

Do I have to create a new Developer Edition account or will the current ones be upgraded?

Existing Developer Edition accounts will be upgraded to Winter '09, but will otherwise remain unchanged. You will need to sign up for a new Developer Edition account to obtain the latest developer examples and features. It's FREE to do and can be done here.

In the Visualforce Email Template demo from the webinar, would a contact need to have access to my Salesforce organization in order to use the view/edit features?

Yes - the links to View/Edit are meant for users of the specific Salesforce organization.

Can you associate a custom controller with an email template, and then use that to pull in merge field data from multiple objects?

No - it is not possible to use custom controllers with Visualforce email templates

Will custom buttons in Professional Edition still support S-controls or just Visualforce pages?

Yes - customs buttons support URLs, Custom S-Controls, OnClick JavaScript and now Visualforce Pages.

Professional Edition now allows overrides of custom buttons, but it only allows standard buttons to be overridden with a Visualforce page, not with an S-control. Is there a reason for this?

Can we also package custom controllers along with our Visualforce pages to all editions?

Yes - you can package Visualforce Pages, Static Resources and Visualforce Components.

When we sign up for a new Developer Edition organization for the new features, what happens to our existing Developer Edition organizations that have registered namespaces for certified apps?

Nothing - when you signup for a new Developer Edition account, this does not affect your existing Developer Edition organization.

How would you query for accounts that do not have opportunities?

Here is the SOQL statement:

SELECT Id, Name, (SELECT Name from Opportunities)
FROM Account
WHERE Id NOT IN (SELECT AccountId FROM Opportunity WHERE Name !=' ')

Do I still want to go to the Hackathon if I am a new developer?

Yep, the Hackathon is open to new developers as well, and will offer great opportunities to get exposure to developer features.

Is it possible to export the metadata information using Salesforce.schema?

Metadata can be exported using the Force.com IDE or the Migration Tool, and data can be exported using the Data Loader.


Are Dynamic SOQL, DML and Aysnc fully released in Winter '09, or are they still in developer preview?

Dynamic Apex (which includes Dynamic SOQL, SOQL and DML) and Asynchronous Apex are GA with the Winter '09 release.

How many IN clauses can you have in a SOQL query?

Winter '09 support a maximum of 2 sub-query semi/anti-joins.


Can Winter '09 break an existing trialforce OEM?

Yes - with the Winter '09 upgrade, you will need to recreate your Trialforce Master Org DOT. Please log a case at the Partner Portal for assistance.


Should new developers begin tutorials based on the new editions coming out or trace their way from existing tutorials?

The new tutorials are standalone and do not require experience with existing tutorials. Developers are recommended to start fresh with the new editions.

What about being able to callout to Web Services (e.g. realtime currency exchange rates) from Triggers, etc.?

With Asynchronous Apex, developers can instruct the Apex runtime to execute methods asynchronously. This means technically, you can make a call out from a trigger.

Can you do correlated subqueries? (i.e. show me accounts that have NO opportunities)

Yes - here is the SOQL statement:

SELECT Id, Name, (SELECT Name from Opportunities)
FROM Account
WHERE Id NOT IN (SELECT AccountId FROM Opportunity WHERE Name !=' ')


Do we need to bring our laptops to the hackathon?

Yes, you need to bring your laptop to the Monday night Hackathon.

Where do I find information on Visualforce email templates?

Check out the docs for more information on the templates. See http://wiki.apexdevnet.com/index.php/Documentation for example.

I am a beginner to Force.com. Do you have any recommendations on training classes or tutorials?

Yes, start with the flash tutorials. They can be found by clicking on the link of the start page of your new DE org. Also check out developer.force.com for other documentation.


Why can't I deploy packages in my current Winter '09 Sandbox to my production organization running Summer '08?

Packages published from a Winter '09 organization may contain new features incompatible with the Summer '08 release. Once your production organization is upgraded to Winter '09 as well, you will be able to install the packages from Sandbox.

As a best practice, we recommend using the Force.com Migration Tool or the Force.com IDE rather than packages for migrating configuration changes from Sandbox to a production organization. These tools will allow you to migrate changes from a Sandbox running Winter '09 to a production organization running Summer '08--just make sure you download the metadata files from your Sandbox using the 13.0 (Summer '08) endpoint, so they are compatible with your production organization.

Does Winter '09 allow me to deactivate triggers without deleting them completely from a production organization?

You can deactivate triggers in production by editing the .trigger-meta.xml file in the Force.com IDE.

Will you be releasing the source code for your demonstrations? ie. the Visualforce template page, and so on?

Yes - here is the source code to build a Visualforce Email Template that displays all of the cases related to a specific account:

<messaging:emailTemplate recipientType="Contact"
    relatedToType="Account"
    subject="Case Report for Account: {!relatedTo.name}"
    replyTo="support@acme.com" >
    
<messaging:htmlEmailBody >
    <html>
        <body>
         <STYLE type="text/css">
               TH {font-size: 11px; font-face: arial;background: #CCCCCC;
border-width: 1;  text-align: center }
               TD  {font-size: 11px; font-face: verdana }
               TABLE {border: solid #CCCCCC; border-width: 1}
               TR {border: solid #CCCCCC; border-width: 1}
         </STYLE>
                  <font face="arial" size="2">
        <p>Dear {!recipient.name},</p>
        <p>Below is a list of cases related to the account:
{!relatedTo.name}.</p>
       <table border="0" >
                 <tr >
                     <th>Action</th><th>Case Number</th><th>Subject</th><th>Creator Email</th><th>Status</th>
                  </tr>
    <apex:repeat var="cx" value="{!relatedTo.Cases}">
       <tr>
           <td><a
href="https://na1.salesforce.com/{!cx.id}">View</a> |
           <a
href="https://na1.salesforce.com/{!cx.id}/e">Edit</a></td>
           <td>{!cx.CaseNumber}</td>
           <td>{!cx.Subject}</td>
           <td>{!cx.Contact.email}</td>
           <td>{!cx.Status}</td>
       </tr>
    </apex:repeat> 
       </table>
       <p />
       <center>
       <apex:outputLink value="http://www.salesforce.com">
            For more detailed information login to Salesforce.com
       </apex:outputLink>
       </center> </font>
       
        </body>
    </html>
</messaging:htmlEmailBody>
    
<messaging:plainTextEmailBody >
Dear {!recipient.name},
 
Below is a list of cases related to Account: {!relatedTo.name}

              [ Case Number ] - [ Subject ] - [ Email ] - [ Status ]

<apex:repeat var="cx" value="{!relatedTo.Cases}">
              [ {!cx.CaseNumber} ] - [ {!cx.Subject} ] - [ {!cx.Contact.email} ] - [ {!cx.Status} ] </apex:repeat>

 For more detailed information login to http://www.salesforce.com </messaging:plainTextEmailBody>
    
    <messaging:attachment renderas="pdf" filename="cases.pdf">
    <html>
    <body>
    <p />
    <img
src="https://c.na1.visual.force.com/img/force_logo_w09.gif"
border="0" />
    <p />
    <apex:datatable border="2" cellspacing="5" var="cx"
value="{!relatedTo.Cases}">
        <apex:facet name="header">Cases currently associated with {!relatedTo.name}</apex:facet>
        <apex:column value="{!cx.CaseNumber}" headerValue="Case Number"/>
        <apex:column value="{!cx.Subject}" headerValue="Subject"/>
        <apex:column value="{!cx.Contact.email}" headerValue="Case Creator"
/>
        <apex:column value="{!cx.Status}" headerValue="Status" />
    </apex:datatable>
   
    <p />
    </body>
    </html>
    </messaging:attachment>
    
    <messaging:attachment filename="cases.csv" renderAs="text" >
        Case Number, Case Subject, Contact Email, Case Status
            <apex:repeat var="cx" value="{!relatedTo.Cases}">
               {!cx.CaseNumber} , {!cx.Subject} ,  {!cx.Contact.email} , {!cx.Status} 
            </apex:repeat>
    </messaging:attachment>
        
</messaging:emailTemplate>
</code>

Bold text