• Brickboxer
  • NEWBIE
  • 0 Points
  • Member since 2009

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

When rendering a Visualforce page (which includes two page blocks and two data tables), the xls file includes a big block of javascript.

 

For example:

 

 

<script type="text/javascript"> if(!window.sfdcPage){window.sfdcPage = new ApexPage();}
UserContext.initialize({'locale':'en_US','timeFormat':'h:mm a','today':'9\/14\/2009 11:03 AM','userPreferences':[{'value':false,'index':112,'name':'HideInlineEditSplash'}
,{'value':true,'index':114,'name':'OverrideTaskSendNotification'}
,{'value':false,'index':115,'name':'DefaultTaskSendNotification'}
,{'value':false,'index':119,'name':'HideUserLayoutStdFieldInfo'}
,{'value':false,'index':116,'name':'HideRPPWarning'}
,{'value':false,'index':87,'name':'HideInlineSchedulingSplash'}
,{'value':true,'index':88,'name':'HideCRUCNotification'}
,{'value':true,'index':89,'name':'HideNewPLESplash'}
,{'value':false,'index':90,'name':'HideNewPLEWarnIE6'}
,{'value':false,'index':122,'name':'HideOverrideSharingMessage'}
],'startOfWeek':'1','isAccessibleMode':false,'ampm':['AM','PM'],'userId':'00580000001eyzn','dateTimeFormat':'M\/d\/yyyy h:mm a','dateFormat':'M\/d\/yyyy','language':'en_US','siteUrlPrefix':''}
);
</script>

 

 

Excel on a PC is happy to ignore this javascript, but Excel on a mac won't, and Numbers on a Mac completely chokes on it.

There's obviously no need to include this JS in the excel file. Is there a way to disable or remove this from the excel file?

 

 

 

Message Edited by Brickboxer on 09-14-2009 09:19 AM

We have a bunch of test methods that have stopped working because we can't insert objects anymore: worked on Thursday afternoon, stopped working on Thursday night. Here's the error message:

 

System.DmlException: Insert failed. First exception on row 0; first error: DUPLICATE_VALUE, duplicate value found: <unknown> duplicates value on record with id: <unknown>

 

And here's the boiled-down code:

 

 

public class myClass { public void createObject() { // this works (able to insert an object)

Campaign c = new Campaign(); c.name = 'test - ok to delete ' + datetime.now(); insert c; } public static testMethod void myTest() { // but running this same code in test mode results in an error (note code is identical to above) Campaign c = new Campaign(); c.name = 'test - ok to delete ' + datetime.now(); insert c; } }

 

 Anyone have any ideas how to resolve this? Thanks in advance.

 

 

 

We have a bunch of test methods that have stopped working because we can't insert objects anymore: worked on Thursday afternoon, stopped working on Thursday night. Here's the error message:

 

System.DmlException: Insert failed. First exception on row 0; first error: DUPLICATE_VALUE, duplicate value found: <unknown> duplicates value on record with id: <unknown>

 

And here's the boiled-down code:

 

 

public class myClass { public void createObject() { // this works (able to insert an object)

Campaign c = new Campaign(); c.name = 'test - ok to delete ' + datetime.now(); insert c; } public static testMethod void myTest() { // but running this same code in test mode results in an error (note code is identical to above) Campaign c = new Campaign(); c.name = 'test - ok to delete ' + datetime.now(); insert c; } }

 

 Anyone have any ideas how to resolve this? Thanks in advance.