Hello,
It still doesn't work, it gives me the following error (now I get an error, before the SVN update I didn't):
Microsoft JScript compilation error: Expected ';'
on line:
var task=new Ext.util.DelayedTask(function(o,result,response){if(result.script&&result.script.length>0){eval(result.script);}
result.script contains this:
Coolite.Ext.setValues([[OrderFirstName,"Sven"],[OrderLastName,"De Leeuw"],[OrderCompanyName,""],[OrderVAT,""],
[OrderStreet,"Nieuwe Kaai"],[OrderStreetNumber,"32A "],[OrderZipCode,"1760"],[OrderCity,"Roosdaal"],
[OrderEmail,"svendeleeuw@yahoo.com"],[OrderPhone,"0477402152"],[OrderCellPhone,""],[OrderDeliveryFirstName,"Sven"],
[OrderDeliveryLastName,"De Leeuw"],[OrderDeliveryStreet,"Nieuwe Kaai"],[OrderDeliveryStreetNumber,"32A
"],[OrderDeliveryZipCode,"1760"],[OrderDeliveryCity,"Roosdaal"],[OrderDeliveryCompanyName,""],[OrderOrderDate,"3/6/2009"],
[OrderPaymentDate,"3/6/2009"],[OrderDeliveryDateField,new Date(2009,5,6,13,44,47)],[OrderPrice,"399"],[OrderTotal,"399"],
[OrderPayID,"147156226"],[OrderPaymentMethod,"CreditCard"],[OrderPaymentBrand,"VISA"],[OrderBankAccountNumber,""],
[OrderMethod,"Delivery"],[OrderChargesOrDiscount,"+ 0"],[OrderID,"274"]]);labelOrderType.setText("<strong>Delivery</strong>",false);labelOrderType.setIconClass("icon-lorry");
OrderChargesOrDiscount.el.parent().parent().child("label").update("Charges")OrderDeliveryDateField.el.parent().parent().child("label").update("Deliverydate")OrderStatusID.setValue("3");
windowEdit.setTitle("Edit [274]");
windowEdit.show();
I have the following fields:
<ext:Anchor Horizontal="95%">
<ext:TextField
ID="OrderChargesOrDiscount"
runat="server"
FieldLabel="Charges/Discount"
ReadOnly="true"
/>
</ext:Anchor>
<ext:Anchor Horizontal="95%">
<ext:DateField
ID="OrderDeliveryDateField"
runat="server"
ShowToday="true"
FieldLabel="Pickup/Delivery Date"
/>
</ext:Anchor>
In my AjaxMethod I have:
this.OrderChargesOrDiscount.FieldLabel = "Charges";
this.OrderDeliveryDateField.FieldLabel = "Deliverydate";
Now the strange part is that when I remove in my AjaxMethod the second line (the one that changes the datefield label), it works fine.
Oh, I see the error.
After the update function in your generated script you don't have a ; closure.
Therefore it works when I only use one update of a fieldlabel, but crashes it on subsequent updates.
Could you change this please?
Thanks,
Reno