PDA

View Full Version : DateField calendar being cropped



nbailey
18 Dec 2009, 10:46 AM
This issue is happening cross browser, and I cannot for the life of me figure out why. I have searched the forums, read the docs.... any help would be much appreciated.

The code creating the control is below, and I have attached a screenshot. I have tried increasing the width of the date control...no change...



wins["Targets"] = new Ext.Window({
contentEl: "TargetDetails",
closeAction: 'hide',
height: 475,
width: 625,
title: "Currently Existing Targets",
layout: 'fit',
//toolbar
tbar: [
new Ext.form.DateField({
value: new Date(),
maxValue: new Date(),
editable: false,
width:200
}), " ",
new Ext.Button({
text: "Load Targets",
handler: function () {
alert("test");
}
})
],
items: new Ext.grid.GridPanel({
renderTo: "TargetGrid",
frame: false,
store: datasources["TargetGrid"],
//column model
cm: new Ext.grid.ColumnModel([
{ dataIndex: "target_id", hidden: true },
{ dataIndex: "target", header: "Value", width: 75, align: "right", sortable: false },
{ dataIndex: "name", header: "Target", width: 125, sortable: true },
{ dataIndex: "package", header: "Package", width: 100, sortable: true },
{ dataIndex: "status", header: "Current Status", width: 100, sortable: true },
{ dataIndex: "effective", header: "Effective", width: 100, align: "right", sortable: true },
{ dataIndex: "expiration", header: "Expiration", width: 100, align: "right", sortable: true }
]),
//selection model
sm: new Ext.grid.RowSelectionModel({
singleSelect: true, //single select
listeners: {
rowSelect: function (mdl, idx, record) { //fires when the user clicks on a row
//call the appropriate page method to get that individual record's data
PageMethods.XXX(record.get("target_id"), function (r) {
//success}, function (err) {
//error
Ext.MessageBox.alert("An Error Has Occurred...", err.Message);
});
}
}
}),
loadMask: true,
stripeRows: true
})
});

18 Dec 2009, 11:23 AM
does this occur in a vanilla page?

nbailey
18 Dec 2009, 11:26 AM
haha No. Definitely not. However, it is occurring in a page where _everything_ else seems to be functioning properly. I am assuming it is a matter of the drop-down calendar's container being improperly sized. is there a way to check the dimensions, and also to correct them?

jpsequeira
27 Dec 2009, 11:11 AM
I had the same problem.
You need to edit your html page (or php) and remove all lines starting with "<!", like for example
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">

Just remove them all. Dont really know why. But it worked for me.

pludikhu1
28 Dec 2009, 4:25 AM
Probably way off ... listWidth?