function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
magdamagda 

Failure: DML currently not allowed

Hi,

I try to save a customer object and use the Id to have notes and attachement.
If I try to insert this Object during the load of a page I become this failure: DML currently not allowed,

but if I insert the object in the save function I have no Problems. But it is to late, because I want to have on the same page the possibility to add notes & attachments.
Function Info:

Code:
public void Info(){
try{
if (booleaninfo == false) {
        insert Object;
        booleaninfo = true;}
}catch (Exception e){

}
}

 ActionSupport:

Code:
<apex:actionSupport event="onMouseOver" action="{!Info}" rerender="counter"
status="counterStatus"/>

 
Any Idea?

Thx

Magda

magdamagda
Hi,

i find how to save this object. But know I have a Problem with URL Link:
cf:

http://community.salesforce.com/sforce/board/message?board.id=general_development&thread.id=16475

I don't know why the Id not the same is.

Do you have an Idea?

Thx

Magda