50 |
How do I get the start/end of the bar once the BarResize/BarResizing event occurs
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) HostEvent = class::nativeObject_HostEvent endwith */ // Notifies the application once the host fires an event. function nativeObject_HostEvent(EventID) local h,key oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject h = oG2Host.HostEventParam(0) key = oG2Host.HostEventParam(1) ? Str(oG2Host.HostEventParam(-2)) ? "Start:" ? Str(oG2Host.Host.Items.ItemBar(h,key,1)) ? Str(oG2Host.HostEventParam(-2)) ? "End:" ? Str(oG2Host.Host.Items.ItemBar(h,key,2)) return local oG2Host,var_Chart,var_Items oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject var_Chart = oG2Host.Host.Chart // var_Chart.PaneWidth(false) = 128 with (oG2Host) TemplateDef = [dim var_Chart] TemplateDef = var_Chart Template = [var_Chart.PaneWidth(False) = 128] endwith var_Chart.FirstVisibleDate = "03/30/2019" var_Items = oG2Host.Host.Items var_Items.AddBar(var_Items.AddItem("Task"),"Task","04/01/2019","04/14/2019") |
49 |
How do I get the bar/task from the cursor
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) HostEvent = class::nativeObject_HostEvent endwith */ // Notifies the application once the host fires an event. function nativeObject_HostEvent(EventID) local b,i,var_Chart,var_G2antt oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? "Event:" ? Str(oG2Host.HostEventParam(-2)) var_G2antt = oG2Host.Host i = var_G2antt.ItemFromPoint(-1,-1,c,h) ? "Cell:" ? var_G2antt.Items.CellCaption(i,c) var_Chart = var_G2antt.Chart b = var_Chart.BarFromPoint(-1,1) ? "Bar:" ? Str(oG2Host.Host.Items.ItemBar(i,b,0)) return local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject |
48 |
How do I get the cell from the cursor
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) HostEvent = class::nativeObject_HostEvent endwith */ // Notifies the application once the host fires an event. function nativeObject_HostEvent(EventID) local i,var_G2antt oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? "Event:" ? Str(oG2Host.HostEventParam(-2)) var_G2antt = oG2Host.Host i = var_G2antt.ItemFromPoint(-1,-1,c,h) ? "Cell:" ? var_G2antt.Items.CellCaption(i,c) return local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject |
47 |
How can I highlights cells based on its value
local oG2Host,var_Column,var_Column1,var_ConditionalFormat,var_ConditionalFormat1,var_ConditionalFormats,var_G2antt,var_Items oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataSource("Tasks") = DataSource("Items")] // oG2Host.DataSource("Tasks") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Tasks") = "EmployeeDetails"] // oG2Host.DataMember("Tasks") = "EmployeeDetails" oG2Host.Template = [DataField(7) = "Tasks"] // oG2Host.DataField(7) = "Tasks" oG2Host.Template = [DataField(8) = "EmployeeID"] // oG2Host.DataField(8) = "EmployeeID" oG2Host.Template = [DataField(9) = "DateStart"] // oG2Host.DataField(9) = "DateStart" oG2Host.Template = [DataField(10) = "DateEnd"] // oG2Host.DataField(10) = "DateEnd" oG2Host.Template = [DataField(14) = "TaskID"] // oG2Host.DataField(14) = "TaskID" oG2Host.Template = [DataField(12) = "Color"] // oG2Host.DataField(12) = "Color" oG2Host.Template = [DataField(13) = "TaskName"] // oG2Host.DataField(13) = "TaskName" var_G2antt = oG2Host.Host var_G2antt.BeginUpdate() var_G2antt.BackColorAlternate = 0x0 var_Column = var_G2antt.Columns.Item("Title") // var_Column.Def(4) = 15790320 with (oG2Host) TemplateDef = [dim var_Column] TemplateDef = var_Column Template = [var_Column.Def(4) = 15790320] endwith var_Column.Width = var_Column.AutoWidth var_ConditionalFormats = var_G2antt.ConditionalFormats // var_ConditionalFormats.Add("lower(%4) contains `manager`").Bold = true var_ConditionalFormat = var_ConditionalFormats.Add("lower(%4) contains `manager`") with (oG2Host) TemplateDef = [dim var_ConditionalFormat] TemplateDef = var_ConditionalFormat Template = [var_ConditionalFormat.Bold = True] endwith // var_ConditionalFormats.Add("%3").BackColor = 0xf0f0f0 var_ConditionalFormat1 = var_ConditionalFormats.Add("%3") with (oG2Host) TemplateDef = [dim var_ConditionalFormat1] TemplateDef = var_ConditionalFormat1 Template = [var_ConditionalFormat1.BackColor = 15790320] endwith // var_G2antt.Items.ExpandItem(0) = true var_Items = var_G2antt.Items with (oG2Host) TemplateDef = [dim var_Items] TemplateDef = var_Items Template = [var_Items.ExpandItem(0) = True] endwith var_Column1 = var_G2antt.Columns.Item("EmployeeID") var_Column1.Width = var_Column1.AutoWidth var_G2antt.EndUpdate() |
46 |
How do I programatically hide a column
local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataSource("Tasks") = DataSource("Items")] // oG2Host.DataSource("Tasks") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Tasks") = "EmployeeDetails"] // oG2Host.DataMember("Tasks") = "EmployeeDetails" oG2Host.Template = [DataField(7) = "Tasks"] // oG2Host.DataField(7) = "Tasks" oG2Host.Template = [DataField(8) = "EmployeeID"] // oG2Host.DataField(8) = "EmployeeID" oG2Host.Template = [DataField(9) = "DateStart"] // oG2Host.DataField(9) = "DateStart" oG2Host.Template = [DataField(10) = "DateEnd"] // oG2Host.DataField(10) = "DateEnd" oG2Host.Template = [DataField(14) = "TaskID"] // oG2Host.DataField(14) = "TaskID" oG2Host.Template = [DataField(12) = "Color"] // oG2Host.DataField(12) = "Color" oG2Host.Template = [DataField(13) = "TaskName"] // oG2Host.DataField(13) = "TaskName" oG2Host.Host.Columns.Item("LastName").Visible = false |
45 |
Is it possible to get the information from the control when we click on the bar/item
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) HostEvent = class::nativeObject_HostEvent endwith */ // Notifies the application once the host fires an event. function nativeObject_HostEvent(EventID) local b,i,var_G2antt oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(oG2Host.HostEventParam(-2)) var_G2antt = oG2Host.Host i = var_G2antt.ItemFromPoint(-1,-1,c,hit) ? "cell's value from cursor: " ? Str(var_G2antt.Items.CellValue(i,c)) ? "cell's value on col 1: " ? Str(var_G2antt.Items.CellValue(i,1)) b = var_G2antt.Chart.BarFromPoint(-1,-1) ? "Bar:" ? Str(b) ? "Bar Start:" ? Str(var_G2antt.Items.ItemBar(i,b,1)) ? "Bar End:" ? Str(var_G2antt.Items.ItemBar(i,b,2)) ? "Bar Caption:" ? Str(var_G2antt.Items.ItemBar(i,b,3)) return local oG2Host,var_Bar,var_Chart,var_G2antt,var_Items oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject var_G2antt = oG2Host.Host var_G2antt.Debug = true var_Bar = var_G2antt.Chart.Bars.Item("Task") var_Bar.OverlaidType = 515 /*exOverlaidBarsStackAutoArrange | exOverlaidBarsStack*/ var_Bar.OverlaidGroup = "Task,Progress" oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataSource("Tasks") = DataSource("Items")] // oG2Host.DataSource("Tasks") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Tasks") = "EmployeeDetails"] // oG2Host.DataMember("Tasks") = "EmployeeDetails" oG2Host.Template = [DataField(7) = "Tasks"] // oG2Host.DataField(7) = "Tasks" oG2Host.Template = [DataField(8) = "EmployeeID"] // oG2Host.DataField(8) = "EmployeeID" oG2Host.Template = [DataField(9) = "DateStart"] // oG2Host.DataField(9) = "DateStart" oG2Host.Template = [DataField(10) = "DateEnd"] // oG2Host.DataField(10) = "DateEnd" oG2Host.Template = [DataField(14) = "TaskID"] // oG2Host.DataField(14) = "TaskID" oG2Host.Template = [DataField(12) = "Color"] // oG2Host.DataField(12) = "Color" oG2Host.Template = [DataField(13) = "TaskName"] // oG2Host.DataField(13) = "TaskName" // oG2Host.Host.Items.ExpandItem(0) = true var_Items = oG2Host.Host.Items with (oG2Host) TemplateDef = [dim var_Items] TemplateDef = var_Items Template = [var_Items.ExpandItem(0) = True] endwith var_Chart = oG2Host.Host.Chart // var_Chart.PaneWidth(false) = 128 with (oG2Host) TemplateDef = [dim var_Chart] TemplateDef = var_Chart Template = [var_Chart.PaneWidth(False) = 128] endwith var_Chart.ScrollTo("05/27/2017",1) |
44 |
How do I get the bar from the cursor
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) HostEvent = class::nativeObject_HostEvent endwith */ // Notifies the application once the host fires an event. function nativeObject_HostEvent(EventID) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(oG2Host.HostEventParam(-2)) ? Str(oG2Host.Host.Chart.BarFromPoint(-1,-1)) return local oG2Host,var_Bar,var_Chart,var_G2antt,var_Items oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject var_G2antt = oG2Host.Host var_G2antt.VisualAppearance.Add(1,"C:\Program Files\Exontrol\ExG2Host\Sample\EBN\Assorted\wbs-ass.ebn") var_Bar = var_G2antt.Chart.Bars.Item("Task") var_Bar.Height = 15 var_Bar.Color = 0x1ff0000 var_Bar.OverlaidType = 515 /*exOverlaidBarsStackAutoArrange | exOverlaidBarsStack*/ var_Bar.OverlaidGroup = "Task,Progress" oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataSource("Tasks") = DataSource("Items")] // oG2Host.DataSource("Tasks") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Tasks") = "EmployeeDetails"] // oG2Host.DataMember("Tasks") = "EmployeeDetails" oG2Host.Template = [DataField(7) = "Tasks"] // oG2Host.DataField(7) = "Tasks" oG2Host.Template = [DataField(8) = "EmployeeID"] // oG2Host.DataField(8) = "EmployeeID" oG2Host.Template = [DataField(9) = "DateStart"] // oG2Host.DataField(9) = "DateStart" oG2Host.Template = [DataField(10) = "DateEnd"] // oG2Host.DataField(10) = "DateEnd" oG2Host.Template = [DataField(14) = "TaskID"] // oG2Host.DataField(14) = "TaskID" oG2Host.Template = [DataField(12) = "Color"] // oG2Host.DataField(12) = "Color" oG2Host.Template = [DataField(13) = "TaskName"] // oG2Host.DataField(13) = "TaskName" // oG2Host.Host.Items.ExpandItem(0) = true var_Items = oG2Host.Host.Items with (oG2Host) TemplateDef = [dim var_Items] TemplateDef = var_Items Template = [var_Items.ExpandItem(0) = True] endwith var_Chart = oG2Host.Host.Chart // var_Chart.PaneWidth(false) = 128 with (oG2Host) TemplateDef = [dim var_Chart] TemplateDef = var_Chart Template = [var_Chart.PaneWidth(False) = 128] endwith var_Chart.ScrollTo("05/27/2017",1) |
43 |
How do I add Start/End columns
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) HostEvent = class::nativeObject_HostEvent endwith */ // Notifies the application once the host fires an event. function nativeObject_HostEvent(EventID) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(oG2Host.HostEventParam(-2)) return local oG2Host,var_Chart,var_Column,var_Column1,var_G2antt oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.HostReadOnly = 255 /*exHostReadWrite | exHostAllowAddEmptyItem*/ var_G2antt = oG2Host.Host var_G2antt.SingleSel = false var_G2antt.OnResizeControl = 1 var_G2antt.ScrollBars = 2058 /*exVScrollEmptySpace | exDisableNoVertical*/ var_Column = var_G2antt.Columns.Add("Start") var_Column.AllowSizing = false // var_Column.Def(18) = 1 with (oG2Host) TemplateDef = [dim var_Column] TemplateDef = var_Column Template = [var_Column.Def(18) = 1] endwith var_Column.Editor.EditType = 7 var_Column1 = var_G2antt.Columns.Add("End") var_Column1.AllowSizing = false // var_Column1.Def(18) = 2 with (oG2Host) TemplateDef = [dim var_Column1] TemplateDef = var_Column1 Template = [var_Column1.Def(18) = 2] endwith var_Column1.Editor.EditType = 7 var_G2antt.Items.AllowCellValueToItemBar = true var_Chart = var_G2antt.Chart var_Chart.AllowCreateBar = 1 // var_Chart.PaneWidth(false) = 256 with (oG2Host) TemplateDef = [dim var_Chart] TemplateDef = var_Chart Template = [var_Chart.PaneWidth(False) = 256] endwith var_Chart.Bars.Item("Task").OverlaidType = 515 /*exOverlaidBarsStackAutoArrange | exOverlaidBarsStack*/ |
42 |
How do I hide the left/items/columns part of the control
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,var_Bar,var_Chart,var_G2antt,var_Items oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject var_Bar = oG2Host.Host.Chart.Bars.Item("Task") var_Bar.Pattern = 1 var_Bar.Color = 0xff0000 // var_Bar.Def(19) = 50 with (oG2Host) TemplateDef = [dim var_Bar] TemplateDef = var_Bar Template = [var_Bar.Def(19) = 50] endwith oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataSource("Tasks") = DataSource("Items")] // oG2Host.DataSource("Tasks") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Tasks") = "EmployeeDetails"] // oG2Host.DataMember("Tasks") = "EmployeeDetails" oG2Host.Template = [DataField(7) = "Tasks"] // oG2Host.DataField(7) = "Tasks" oG2Host.Template = [DataField(8) = "EmployeeID"] // oG2Host.DataField(8) = "EmployeeID" oG2Host.Template = [DataField(9) = "DateStart"] // oG2Host.DataField(9) = "DateStart" oG2Host.Template = [DataField(10) = "DateEnd"] // oG2Host.DataField(10) = "DateEnd" oG2Host.Template = [DataField(14) = "TaskID"] // oG2Host.DataField(14) = "TaskID" oG2Host.Template = [DataField(12) = "Color"] // oG2Host.DataField(12) = "Color" oG2Host.Template = [DataField(13) = "TaskName"] // oG2Host.DataField(13) = "TaskName" // oG2Host.Host.Items.ExpandItem(0) = true var_Items = oG2Host.Host.Items with (oG2Host) TemplateDef = [dim var_Items] TemplateDef = var_Items Template = [var_Items.ExpandItem(0) = True] endwith oG2Host.HostReadOnly = 255 /*exHostReadWrite | exHostAllowAddEmptyItem*/ var_G2antt = oG2Host.Host var_G2antt.OnResizeControl = 129 /*exDisableSplitter | exResizeChart*/ var_Chart = var_G2antt.Chart var_Chart.ColumnsFormatLevel = "1" // var_Chart.PaneWidth(false) = 0 with (oG2Host) TemplateDef = [dim var_Chart] TemplateDef = var_Chart Template = [var_Chart.PaneWidth(False) = 0] endwith var_Chart.ScrollTo("05/27/2017",1) |
41 |
How do I hide the right/chart/tasks part of the control
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,var_Bar,var_Chart,var_G2antt,var_Items oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject var_Bar = oG2Host.Host.Chart.Bars.Item("Task") var_Bar.Pattern = 1 var_Bar.Color = 0xff0000 // var_Bar.Def(19) = 50 with (oG2Host) TemplateDef = [dim var_Bar] TemplateDef = var_Bar Template = [var_Bar.Def(19) = 50] endwith oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataSource("Tasks") = DataSource("Items")] // oG2Host.DataSource("Tasks") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Tasks") = "EmployeeDetails"] // oG2Host.DataMember("Tasks") = "EmployeeDetails" oG2Host.Template = [DataField(7) = "Tasks"] // oG2Host.DataField(7) = "Tasks" oG2Host.Template = [DataField(8) = "EmployeeID"] // oG2Host.DataField(8) = "EmployeeID" oG2Host.Template = [DataField(9) = "DateStart"] // oG2Host.DataField(9) = "DateStart" oG2Host.Template = [DataField(10) = "DateEnd"] // oG2Host.DataField(10) = "DateEnd" oG2Host.Template = [DataField(14) = "TaskID"] // oG2Host.DataField(14) = "TaskID" oG2Host.Template = [DataField(12) = "Color"] // oG2Host.DataField(12) = "Color" oG2Host.Template = [DataField(13) = "TaskName"] // oG2Host.DataField(13) = "TaskName" // oG2Host.Host.Items.ExpandItem(0) = true var_Items = oG2Host.Host.Items with (oG2Host) TemplateDef = [dim var_Items] TemplateDef = var_Items Template = [var_Items.ExpandItem(0) = True] endwith var_G2antt = oG2Host.Host var_Chart = var_G2antt.Chart // var_Chart.PaneWidth(true) = 0 with (oG2Host) TemplateDef = [dim var_Chart] TemplateDef = var_Chart Template = [var_Chart.PaneWidth(True) = 0] endwith var_Chart.OverviewVisible = 0 |
40 |
How do hide the top/overview part of the control
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,var_Chart,var_G2antt oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataField(7) = DataField(0)] // oG2Host.DataField(7) = oG2Host.DataField(0) oG2Host.Template = [DataField(9) = "BirthDate"] // oG2Host.DataField(9) = "BirthDate" oG2Host.Template = [DataField(10) = "HireDate"] // oG2Host.DataField(10) = "HireDate" var_G2antt = oG2Host.Host var_Chart = var_G2antt.Chart var_Chart.OverviewVisible = 0 // var_Chart.PaneWidth(false) = 256 with (oG2Host) TemplateDef = [dim var_Chart] TemplateDef = var_Chart Template = [var_Chart.PaneWidth(False) = 256] endwith var_Chart.ScrollTo("04/27/1969",1) |
39 |
How do I resize the panels
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,var_Bar,var_Chart,var_G2antt,var_Items oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject var_G2antt = oG2Host.Host var_G2antt.VisualAppearance.Add(1,"C:\Program Files\Exontrol\ExG2Host\Sample\EBN\Assorted\wbs-ass.ebn") var_Bar = var_G2antt.Chart.Bars.Item("Task") var_Bar.Height = 15 var_Bar.Color = 0x1ff0000 var_Bar.OverlaidType = 515 /*exOverlaidBarsStackAutoArrange | exOverlaidBarsStack*/ var_Bar.OverlaidGroup = "Task,Progress" oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataSource("Tasks") = DataSource("Items")] // oG2Host.DataSource("Tasks") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Tasks") = "EmployeeDetails"] // oG2Host.DataMember("Tasks") = "EmployeeDetails" oG2Host.Template = [DataField(7) = "Tasks"] // oG2Host.DataField(7) = "Tasks" oG2Host.Template = [DataField(8) = "EmployeeID"] // oG2Host.DataField(8) = "EmployeeID" oG2Host.Template = [DataField(9) = "DateStart"] // oG2Host.DataField(9) = "DateStart" oG2Host.Template = [DataField(10) = "DateEnd"] // oG2Host.DataField(10) = "DateEnd" oG2Host.Template = [DataField(14) = "TaskID"] // oG2Host.DataField(14) = "TaskID" oG2Host.Template = [DataField(12) = "Color"] // oG2Host.DataField(12) = "Color" oG2Host.Template = [DataField(13) = "TaskName"] // oG2Host.DataField(13) = "TaskName" // oG2Host.Host.Items.ExpandItem(0) = true var_Items = oG2Host.Host.Items with (oG2Host) TemplateDef = [dim var_Items] TemplateDef = var_Items Template = [var_Items.ExpandItem(0) = True] endwith var_Chart = oG2Host.Host.Chart // var_Chart.PaneWidth(false) = 128 with (oG2Host) TemplateDef = [dim var_Chart] TemplateDef = var_Chart Template = [var_Chart.PaneWidth(False) = 128] endwith var_Chart.ScrollTo("05/27/2017",1) |
38 |
How do I lock the first column
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,var_G2antt oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" var_G2antt = oG2Host.Host var_G2antt.CountLockedColumns = 1 var_G2antt.BackColorLock = var_G2antt.BackColorAlternate |
37 |
How do I specify a different color for the tasks ( EBN color )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,var_Bar,var_Chart,var_G2antt,var_Items oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject var_G2antt = oG2Host.Host var_G2antt.VisualAppearance.Add(1,"C:\Program Files\Exontrol\ExG2Host\Sample\EBN\Assorted\wbs-ass.ebn") var_Bar = var_G2antt.Chart.Bars.Item("Task") var_Bar.Height = 15 var_Bar.Color = 0x1ff0000 var_Bar.OverlaidType = 515 /*exOverlaidBarsStackAutoArrange | exOverlaidBarsStack*/ var_Bar.OverlaidGroup = "Task,Progress" oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataSource("Tasks") = DataSource("Items")] // oG2Host.DataSource("Tasks") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Tasks") = "EmployeeDetails"] // oG2Host.DataMember("Tasks") = "EmployeeDetails" oG2Host.Template = [DataField(7) = "Tasks"] // oG2Host.DataField(7) = "Tasks" oG2Host.Template = [DataField(8) = "EmployeeID"] // oG2Host.DataField(8) = "EmployeeID" oG2Host.Template = [DataField(9) = "DateStart"] // oG2Host.DataField(9) = "DateStart" oG2Host.Template = [DataField(10) = "DateEnd"] // oG2Host.DataField(10) = "DateEnd" oG2Host.Template = [DataField(14) = "TaskID"] // oG2Host.DataField(14) = "TaskID" oG2Host.Template = [DataField(12) = "Color"] // oG2Host.DataField(12) = "Color" oG2Host.Template = [DataField(13) = "TaskName"] // oG2Host.DataField(13) = "TaskName" // oG2Host.Host.Items.ExpandItem(0) = true var_Items = oG2Host.Host.Items with (oG2Host) TemplateDef = [dim var_Items] TemplateDef = var_Items Template = [var_Items.ExpandItem(0) = True] endwith // oG2Host.Host.Chart.PaneWidth(false) = 256 var_Chart = oG2Host.Host.Chart with (oG2Host) TemplateDef = [dim var_Chart] TemplateDef = var_Chart Template = [var_Chart.PaneWidth(False) = 256] endwith oG2Host.Host.Chart.ScrollTo("05/27/2017",1) |
36 |
How do I specify a different color for the tasks ( solid color, transparent )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,var_Bar,var_Chart,var_Items oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject var_Bar = oG2Host.Host.Chart.Bars.Item("Task") var_Bar.Pattern = 1 var_Bar.Color = 0xff0000 // var_Bar.Def(19) = 50 with (oG2Host) TemplateDef = [dim var_Bar] TemplateDef = var_Bar Template = [var_Bar.Def(19) = 50] endwith oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataSource("Tasks") = DataSource("Items")] // oG2Host.DataSource("Tasks") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Tasks") = "EmployeeDetails"] // oG2Host.DataMember("Tasks") = "EmployeeDetails" oG2Host.Template = [DataField(7) = "Tasks"] // oG2Host.DataField(7) = "Tasks" oG2Host.Template = [DataField(8) = "EmployeeID"] // oG2Host.DataField(8) = "EmployeeID" oG2Host.Template = [DataField(9) = "DateStart"] // oG2Host.DataField(9) = "DateStart" oG2Host.Template = [DataField(10) = "DateEnd"] // oG2Host.DataField(10) = "DateEnd" oG2Host.Template = [DataField(14) = "TaskID"] // oG2Host.DataField(14) = "TaskID" oG2Host.Template = [DataField(12) = "Color"] // oG2Host.DataField(12) = "Color" oG2Host.Template = [DataField(13) = "TaskName"] // oG2Host.DataField(13) = "TaskName" // oG2Host.Host.Items.ExpandItem(0) = true var_Items = oG2Host.Host.Items with (oG2Host) TemplateDef = [dim var_Items] TemplateDef = var_Items Template = [var_Items.ExpandItem(0) = True] endwith // oG2Host.Host.Chart.PaneWidth(false) = 256 var_Chart = oG2Host.Host.Chart with (oG2Host) TemplateDef = [dim var_Chart] TemplateDef = var_Chart Template = [var_Chart.PaneWidth(False) = 256] endwith oG2Host.Host.Chart.ScrollTo("05/27/2017",1) |
35 |
GroupBy
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,var_Bar,var_Column,var_G2antt,var_Items oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataSource("Tasks") = DataSource("Items")] // oG2Host.DataSource("Tasks") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Tasks") = "EmployeeDetails"] // oG2Host.DataMember("Tasks") = "EmployeeDetails" oG2Host.Template = [DataField(7) = "Tasks"] // oG2Host.DataField(7) = "Tasks" oG2Host.Template = [DataField(8) = "EmployeeID"] // oG2Host.DataField(8) = "EmployeeID" oG2Host.Template = [DataField(9) = "DateStart"] // oG2Host.DataField(9) = "DateStart" oG2Host.Template = [DataField(10) = "DateEnd"] // oG2Host.DataField(10) = "DateEnd" oG2Host.Template = [DataField(14) = "TaskID"] // oG2Host.DataField(14) = "TaskID" oG2Host.Template = [DataSource("Links") = DataSource("Items")] // oG2Host.DataSource("Links") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Links") = "EmployeeLinks"] // oG2Host.DataMember("Links") = "EmployeeLinks" oG2Host.Template = [DataField(15) = "Links"] // oG2Host.DataField(15) = "Links" oG2Host.Template = [DataField(16) = "Start"] // oG2Host.DataField(16) = "Start" oG2Host.Template = [DataField(17) = "End"] // oG2Host.DataField(17) = "End" var_G2antt = oG2Host.Host var_G2antt.AllowGroupBy = true var_G2antt.SortBarVisible = true var_G2antt.BackColorSortBar = oG2Host.Host.BackColor var_G2antt.BackColorSortBarCaption = var_G2antt.BackColorSortBar var_G2antt.SortBarCaption = "<sha ;;0><fgcolor=FF0000>Drag a <b>column</b> header here to sort by that column." var_Bar = var_G2antt.Chart.Bars.Item("Task") var_Bar.OverlaidType = 515 /*exOverlaidBarsStackAutoArrange | exOverlaidBarsStack*/ var_Bar.OverlaidGroup = "Task,Progress" // var_G2antt.Items.ExpandItem(0) = true var_Items = var_G2antt.Items with (oG2Host) TemplateDef = [dim var_Items] TemplateDef = var_Items Template = [var_Items.ExpandItem(0) = True] endwith var_G2antt.CountLockedColumns = 1 var_G2antt.BackColorLock = var_G2antt.BackColorAlternate var_Column = var_G2antt.Columns.Item("EmployeeID") var_Column.AllowGroupBy = false // var_Column.Def(7) = oG2Host.Host.BackColorAlternate with (oG2Host) TemplateDef = [dim var_Column] TemplateDef = var_Column Template = [var_Column.Def(7) = Me.Host.BackColorAlternate] endwith var_G2antt.Columns.Item("Title").SortOrder = 1 oG2Host.Host.Chart.ScrollTo("05/27/2017",1) |
34 |
How can I hide a column
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Host.Columns.Item(0).Visible = false |
33 |
Can row errors being highligted until the user correct them, not to clear them as soon a change occurs
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [HostDef(7) = False] // oG2Host.HostDef(7) = false |
32 |
No error is highligthed
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" |
31 |
I've noticed that rows with errors are shown in red. Is it possible to change the colors
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [HostDef(6) = 0] // oG2Host.HostDef(6) = 0 oG2Host.Template = [HostDef(5) = 16777215] // oG2Host.HostDef(5) = 16777215 |
30 |
Is it possible to rename the (New) to something else
local oG2Host,var_G2antt oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [HostDef(1) = "*"] // oG2Host.HostDef(1) = "*" var_G2antt = oG2Host.Host var_G2antt.BeginUpdate() var_G2antt.Items.AddItem("A") var_G2antt.Items.AddItem("B") var_G2antt.EndUpdate() oG2Host.Refresh() |
29 |
How can I hide the (New) item (sample 2)
|
28 |
How can I hide the (New) item (sample 1)
local oG2Host,var_G2antt oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [HostDef(1) = ""] // oG2Host.HostDef(1) = "" var_G2antt = oG2Host.Host var_G2antt.BeginUpdate() var_G2antt.Items.AddItem("A") var_G2antt.Items.AddItem("B") var_G2antt.EndUpdate() oG2Host.Refresh() |
27 |
Read-Only
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.HostReadOnly = 0 |
26 |
How can I prevent user create new /delete tasks ( only move or resize then )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,var_Bar,var_Items oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataSource("Tasks") = DataSource("Items")] // oG2Host.DataSource("Tasks") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Tasks") = "EmployeeDetails"] // oG2Host.DataMember("Tasks") = "EmployeeDetails" oG2Host.Template = [DataField(7) = "Tasks"] // oG2Host.DataField(7) = "Tasks" oG2Host.Template = [DataField(8) = "EmployeeID"] // oG2Host.DataField(8) = "EmployeeID" oG2Host.Template = [DataField(9) = "DateStart"] // oG2Host.DataField(9) = "DateStart" oG2Host.Template = [DataField(10) = "DateEnd"] // oG2Host.DataField(10) = "DateEnd" oG2Host.Template = [DataField(14) = "TaskID"] // oG2Host.DataField(14) = "TaskID" oG2Host.Template = [DataSource("Links") = DataSource("Items")] // oG2Host.DataSource("Links") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Links") = "EmployeeLinks"] // oG2Host.DataMember("Links") = "EmployeeLinks" oG2Host.Template = [DataField(15) = "Links"] // oG2Host.DataField(15) = "Links" oG2Host.Template = [DataField(16) = "Start"] // oG2Host.DataField(16) = "Start" oG2Host.Template = [DataField(17) = "End"] // oG2Host.DataField(17) = "End" var_Bar = oG2Host.Host.Chart.Bars.Item("Task") var_Bar.OverlaidType = 515 /*exOverlaidBarsStackAutoArrange | exOverlaidBarsStack*/ var_Bar.OverlaidGroup = "Task,Progress" // oG2Host.Host.Items.ExpandItem(0) = true var_Items = oG2Host.Host.Items with (oG2Host) TemplateDef = [dim var_Items] TemplateDef = var_Items Template = [var_Items.ExpandItem(0) = True] endwith oG2Host.HostReadOnly = 128 oG2Host.Host.Chart.ScrollTo("05/27/2017",1) |
25 |
How do I get the row/item/task/link from the cursor
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return /* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) HostEvent = class::nativeObject_HostEvent endwith */ // Notifies the application once the host fires an event. function nativeObject_HostEvent(EventID) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? oG2Host.HostContext.ToString return local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.HostReadOnly = 141 /*exHostAllowUpdate | exHostAllowAddNew*/ |
24 |
Disable Delete
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.HostReadOnly = 141 /*exHostAllowUpdate | exHostAllowAddNew*/ |
23 |
Disable AddNew
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.HostReadOnly = 240 /*exHostAllowUpdate | exHostAllowDelete*/ |
22 |
ACCDB sample ( file )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,var_Bar,var_Items oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataSource("Tasks") = DataSource("Items")] // oG2Host.DataSource("Tasks") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Tasks") = "EmployeeDetails"] // oG2Host.DataMember("Tasks") = "EmployeeDetails" oG2Host.Template = [DataField(7) = "Tasks"] // oG2Host.DataField(7) = "Tasks" oG2Host.Template = [DataField(8) = "EmployeeID"] // oG2Host.DataField(8) = "EmployeeID" oG2Host.Template = [DataField(9) = "DateStart"] // oG2Host.DataField(9) = "DateStart" oG2Host.Template = [DataField(10) = "DateEnd"] // oG2Host.DataField(10) = "DateEnd" oG2Host.Template = [DataField(14) = "TaskID"] // oG2Host.DataField(14) = "TaskID" oG2Host.Template = [DataSource("Links") = DataSource("Items")] // oG2Host.DataSource("Links") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Links") = "EmployeeLinks"] // oG2Host.DataMember("Links") = "EmployeeLinks" oG2Host.Template = [DataField(15) = "Links"] // oG2Host.DataField(15) = "Links" oG2Host.Template = [DataField(16) = "Start"] // oG2Host.DataField(16) = "Start" oG2Host.Template = [DataField(17) = "End"] // oG2Host.DataField(17) = "End" var_Bar = oG2Host.Host.Chart.Bars.Item("Task") var_Bar.OverlaidType = 515 /*exOverlaidBarsStackAutoArrange | exOverlaidBarsStack*/ var_Bar.OverlaidGroup = "Task,Progress" // oG2Host.Host.Items.ExpandItem(0) = true var_Items = oG2Host.Host.Items with (oG2Host) TemplateDef = [dim var_Items] TemplateDef = var_Items Template = [var_Items.ExpandItem(0) = True] endwith oG2Host.Host.Chart.ScrollTo("05/27/2017",1) |
21 |
MDB sample ( file )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,var_Bar,var_Items oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.mdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.mdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataSource("Tasks") = DataSource("Items")] // oG2Host.DataSource("Tasks") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Tasks") = "EmployeeDetails"] // oG2Host.DataMember("Tasks") = "EmployeeDetails" oG2Host.Template = [DataField(7) = "Tasks"] // oG2Host.DataField(7) = "Tasks" oG2Host.Template = [DataField(8) = "EmployeeID"] // oG2Host.DataField(8) = "EmployeeID" oG2Host.Template = [DataField(9) = "DateStart"] // oG2Host.DataField(9) = "DateStart" oG2Host.Template = [DataField(10) = "DateEnd"] // oG2Host.DataField(10) = "DateEnd" oG2Host.Template = [DataField(14) = "TaskID"] // oG2Host.DataField(14) = "TaskID" oG2Host.Template = [DataSource("Links") = DataSource("Items")] // oG2Host.DataSource("Links") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Links") = "EmployeeLinks"] // oG2Host.DataMember("Links") = "EmployeeLinks" oG2Host.Template = [DataField(15) = "Links"] // oG2Host.DataField(15) = "Links" oG2Host.Template = [DataField(16) = "Start"] // oG2Host.DataField(16) = "Start" oG2Host.Template = [DataField(17) = "End"] // oG2Host.DataField(17) = "End" var_Bar = oG2Host.Host.Chart.Bars.Item("Task") var_Bar.OverlaidType = 515 /*exOverlaidBarsStackAutoArrange | exOverlaidBarsStack*/ var_Bar.OverlaidGroup = "Task,Progress" // oG2Host.Host.Items.ExpandItem(0) = true var_Items = oG2Host.Host.Items with (oG2Host) TemplateDef = [dim var_Items] TemplateDef = var_Items Template = [var_Items.ExpandItem(0) = True] endwith oG2Host.Host.Chart.ScrollTo("05/27/2017",1) |
20 |
DBF sample ( file )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.dbf"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.dbf" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" |
19 |
DAO sample ( object, DAO.DBEngine.120, multiple tasks, multiple tables )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,rsEmployees,rsLinks,rsTasks,var_Bar,var_Database,var_Items,var_PrivDBEngine oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject var_PrivDBEngine = new OleAutoClient("DAO.DBEngine.120") var_Database = var_PrivDBEngine.OpenDatabase("C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb") rsEmployees = var_Database.OpenRecordset("Employees") rsTasks = var_Database.OpenRecordset("EmployeeDetails") rsLinks = var_Database.OpenRecordset("EmployeeLinks") oG2Host.Template = [DataSource("Items") = rsEmployees] // oG2Host.DataSource("Items") = rsEmployees oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataSource("Tasks") = rsTasks] // oG2Host.DataSource("Tasks") = rsTasks oG2Host.Template = [DataField(7) = "Tasks"] // oG2Host.DataField(7) = "Tasks" oG2Host.Template = [DataField(8) = "EmployeeID"] // oG2Host.DataField(8) = "EmployeeID" oG2Host.Template = [DataField(9) = "DateStart"] // oG2Host.DataField(9) = "DateStart" oG2Host.Template = [DataField(10) = "DateEnd"] // oG2Host.DataField(10) = "DateEnd" oG2Host.Template = [DataField(14) = "TaskID"] // oG2Host.DataField(14) = "TaskID" oG2Host.Template = [DataSource("Links") = rsLinks] // oG2Host.DataSource("Links") = rsLinks oG2Host.Template = [DataField(15) = "Links"] // oG2Host.DataField(15) = "Links" oG2Host.Template = [DataField(16) = "Start"] // oG2Host.DataField(16) = "Start" oG2Host.Template = [DataField(17) = "End"] // oG2Host.DataField(17) = "End" var_Bar = oG2Host.Host.Chart.Bars.Item("Task") var_Bar.OverlaidType = 515 /*exOverlaidBarsStackAutoArrange | exOverlaidBarsStack*/ var_Bar.OverlaidGroup = "Task,Progress" // oG2Host.Host.Items.ExpandItem(0) = true var_Items = oG2Host.Host.Items with (oG2Host) TemplateDef = [dim var_Items] TemplateDef = var_Items Template = [var_Items.ExpandItem(0) = True] endwith oG2Host.Host.Chart.ScrollTo("05/27/2017",1) |
18 |
DAO sample ( file, multiple tasks, multiple tables )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,var_Bar,var_Items oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataTechnology("Items") = "DAO.DBEngine.120;DAO.DBEngine.36"] // oG2Host.DataTechnology("Items") = "DAO.DBEngine.120;DAO.DBEngine.36" oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataTechnology("Tasks") = "DAO.DBEngine.120;DAO.DBEngine.36"] // oG2Host.DataTechnology("Tasks") = "DAO.DBEngine.120;DAO.DBEngine.36" oG2Host.Template = [DataSource("Tasks") = DataSource("Items")] // oG2Host.DataSource("Tasks") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Tasks") = "EmployeeDetails"] // oG2Host.DataMember("Tasks") = "EmployeeDetails" oG2Host.Template = [DataField(7) = "Tasks"] // oG2Host.DataField(7) = "Tasks" oG2Host.Template = [DataField(8) = "EmployeeID"] // oG2Host.DataField(8) = "EmployeeID" oG2Host.Template = [DataField(9) = "DateStart"] // oG2Host.DataField(9) = "DateStart" oG2Host.Template = [DataField(10) = "DateEnd"] // oG2Host.DataField(10) = "DateEnd" oG2Host.Template = [DataField(14) = "TaskID"] // oG2Host.DataField(14) = "TaskID" oG2Host.Template = [DataTechnology("Links") = "DAO.DBEngine.120;DAO.DBEngine.36"] // oG2Host.DataTechnology("Links") = "DAO.DBEngine.120;DAO.DBEngine.36" oG2Host.Template = [DataSource("Links") = DataSource("Items")] // oG2Host.DataSource("Links") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Links") = "EmployeeLinks"] // oG2Host.DataMember("Links") = "EmployeeLinks" oG2Host.Template = [DataField(15) = "Links"] // oG2Host.DataField(15) = "Links" oG2Host.Template = [DataField(16) = "Start"] // oG2Host.DataField(16) = "Start" oG2Host.Template = [DataField(17) = "End"] // oG2Host.DataField(17) = "End" var_Bar = oG2Host.Host.Chart.Bars.Item("Task") var_Bar.OverlaidType = 515 /*exOverlaidBarsStackAutoArrange | exOverlaidBarsStack*/ var_Bar.OverlaidGroup = "Task,Progress" // oG2Host.Host.Items.ExpandItem(0) = true var_Items = oG2Host.Host.Items with (oG2Host) TemplateDef = [dim var_Items] TemplateDef = var_Items Template = [var_Items.ExpandItem(0) = True] endwith oG2Host.Host.Chart.ScrollTo("05/27/2017",1) |
17 |
DAO sample ( object, DAO.DBEngine.120, single task, single table )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,rsEmployees,rsLinks,var_Database,var_PrivDBEngine oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject var_PrivDBEngine = new OleAutoClient("DAO.DBEngine.120") var_Database = var_PrivDBEngine.OpenDatabase("C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb") rsEmployees = var_Database.OpenRecordset("Employees") rsLinks = var_Database.OpenRecordset("EmployeeLinks") oG2Host.Template = [DataSource("Items") = rsEmployees] // oG2Host.DataSource("Items") = rsEmployees oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataField(7) = DataField(0)] // oG2Host.DataField(7) = oG2Host.DataField(0) oG2Host.Template = [DataField(9) = "BirthDate"] // oG2Host.DataField(9) = "BirthDate" oG2Host.Template = [DataField(10) = "HireDate"] // oG2Host.DataField(10) = "HireDate" oG2Host.Template = [DataSource("Links") = rsLinks] // oG2Host.DataSource("Links") = rsLinks oG2Host.Template = [DataField(15) = "Links"] // oG2Host.DataField(15) = "Links" oG2Host.Template = [DataField(16) = "Start"] // oG2Host.DataField(16) = "Start" oG2Host.Template = [DataField(17) = "End"] // oG2Host.DataField(17) = "End" |
16 |
DAO sample ( file, single task, single table )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataTechnology("Items") = "DAO.DBEngine.120;DAO.DBEngine.36"] // oG2Host.DataTechnology("Items") = "DAO.DBEngine.120;DAO.DBEngine.36" oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataField(7) = DataField(0)] // oG2Host.DataField(7) = oG2Host.DataField(0) oG2Host.Template = [DataField(9) = "BirthDate"] // oG2Host.DataField(9) = "BirthDate" oG2Host.Template = [DataField(10) = "HireDate"] // oG2Host.DataField(10) = "HireDate" oG2Host.Template = [DataTechnology("Links") = "DAO.DBEngine.120;DAO.DBEngine.36"] // oG2Host.DataTechnology("Links") = "DAO.DBEngine.120;DAO.DBEngine.36" oG2Host.Template = [DataSource("Links") = DataSource("Items")] // oG2Host.DataSource("Links") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Links") = "EmployeeLinks"] // oG2Host.DataMember("Links") = "EmployeeLinks" oG2Host.Template = [DataField(15) = "Links"] // oG2Host.DataField(15) = "Links" oG2Host.Template = [DataField(16) = "Start"] // oG2Host.DataField(16) = "Start" oG2Host.Template = [DataField(17) = "End"] // oG2Host.DataField(17) = "End" |
15 |
DAO sample ( tree recordset )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataTechnology("Items") = "DAO.DBEngine.120;DAO.DBEngine.36"] // oG2Host.DataTechnology("Items") = "DAO.DBEngine.120;DAO.DBEngine.36" oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" |
14 |
DAO sample ( flat recordset )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,rsEmployees,var_Database,var_PrivDBEngine oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject var_PrivDBEngine = new OleAutoClient("DAO.DBEngine.120") var_Database = var_PrivDBEngine.OpenDatabase("C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb") rsEmployees = var_Database.OpenRecordset("Employees") oG2Host.Template = [DataSource("Items") = rsEmployees] // oG2Host.DataSource("Items") = rsEmployees oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" |
13 |
DAO sample ( flat )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataTechnology("Items") = "DAO.DBEngine.120;DAO.DBEngine.36"] // oG2Host.DataTechnology("Items") = "DAO.DBEngine.120;DAO.DBEngine.36" oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" |
12 |
ADO sample ( object, ADODB.Recordset, multiple tasks )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,rsEmployees,rsLinks,rsTasks,var_Bar,var_Items oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject rsEmployees = new OleAutoClient("ADODB.Recordset") rsEmployees.Open("Employees","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb",3,3) oG2Host.Template = [DataSource("Items") = rsEmployees] // oG2Host.DataSource("Items") = rsEmployees oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" rsTasks = new OleAutoClient("ADODB.Recordset") rsTasks.Open("EmployeeDetails","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb",3,3) oG2Host.Template = [DataSource("Tasks") = rstasks] // oG2Host.DataSource("Tasks") = rstasks oG2Host.Template = [DataField(7) = "Tasks"] // oG2Host.DataField(7) = "Tasks" oG2Host.Template = [DataField(8) = "EmployeeID"] // oG2Host.DataField(8) = "EmployeeID" oG2Host.Template = [DataField(9) = "DateStart"] // oG2Host.DataField(9) = "DateStart" oG2Host.Template = [DataField(10) = "DateEnd"] // oG2Host.DataField(10) = "DateEnd" oG2Host.Template = [DataField(14) = "TaskID"] // oG2Host.DataField(14) = "TaskID" rsLinks = new OleAutoClient("ADODB.Recordset") rsLinks.Open("EmployeeLinks","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb",3,3) oG2Host.Template = [DataSource("Links") = rsLinks] // oG2Host.DataSource("Links") = rsLinks oG2Host.Template = [DataField(15) = "Links"] // oG2Host.DataField(15) = "Links" oG2Host.Template = [DataField(16) = "Start"] // oG2Host.DataField(16) = "Start" oG2Host.Template = [DataField(17) = "End"] // oG2Host.DataField(17) = "End" var_Bar = oG2Host.Host.Chart.Bars.Item("Task") var_Bar.OverlaidType = 515 /*exOverlaidBarsStackAutoArrange | exOverlaidBarsStack*/ var_Bar.OverlaidGroup = "Task,Progress" // oG2Host.Host.Items.ExpandItem(0) = true var_Items = oG2Host.Host.Items with (oG2Host) TemplateDef = [dim var_Items] TemplateDef = var_Items Template = [var_Items.ExpandItem(0) = True] endwith oG2Host.Host.Chart.ScrollTo("05/27/2017",1) |
11 |
ADO sample ( file, multiple tasks, multiple tables )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,var_Bar,var_Items oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataTechnology("Items") = "ADODB.Recordset;ADOR.Recordset"] // oG2Host.DataTechnology("Items") = "ADODB.Recordset;ADOR.Recordset" oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataTechnology("Tasks") = "ADODB.Recordset;ADOR.Recordset"] // oG2Host.DataTechnology("Tasks") = "ADODB.Recordset;ADOR.Recordset" oG2Host.Template = [DataSource("Tasks") = DataSource("Items")] // oG2Host.DataSource("Tasks") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Tasks") = "EmployeeDetails"] // oG2Host.DataMember("Tasks") = "EmployeeDetails" oG2Host.Template = [DataField(7) = "Tasks"] // oG2Host.DataField(7) = "Tasks" oG2Host.Template = [DataField(8) = "EmployeeID"] // oG2Host.DataField(8) = "EmployeeID" oG2Host.Template = [DataField(9) = "DateStart"] // oG2Host.DataField(9) = "DateStart" oG2Host.Template = [DataField(10) = "DateEnd"] // oG2Host.DataField(10) = "DateEnd" oG2Host.Template = [DataField(14) = "TaskID"] // oG2Host.DataField(14) = "TaskID" oG2Host.Template = [DataTechnology("Links") = "ADODB.Recordset;ADOR.Recordset"] // oG2Host.DataTechnology("Links") = "ADODB.Recordset;ADOR.Recordset" oG2Host.Template = [DataSource("Links") = DataSource("Items")] // oG2Host.DataSource("Links") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Links") = "EmployeeLinks"] // oG2Host.DataMember("Links") = "EmployeeLinks" oG2Host.Template = [DataField(15) = "Links"] // oG2Host.DataField(15) = "Links" oG2Host.Template = [DataField(16) = "Start"] // oG2Host.DataField(16) = "Start" oG2Host.Template = [DataField(17) = "End"] // oG2Host.DataField(17) = "End" var_Bar = oG2Host.Host.Chart.Bars.Item("Task") var_Bar.OverlaidType = 515 /*exOverlaidBarsStackAutoArrange | exOverlaidBarsStack*/ var_Bar.OverlaidGroup = "Task,Progress" // oG2Host.Host.Items.ExpandItem(0) = true var_Items = oG2Host.Host.Items with (oG2Host) TemplateDef = [dim var_Items] TemplateDef = var_Items Template = [var_Items.ExpandItem(0) = True] endwith oG2Host.Host.Chart.ScrollTo("05/27/2017",1) |
10 |
ADO sample ( object, ADODB.Recordset, single task, single table )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,rsEmployees,rsLinks oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject rsEmployees = new OleAutoClient("ADODB.Recordset") rsEmployees.Open("Employees","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb",3,3) oG2Host.Template = [DataSource("Items") = rsEmployees] // oG2Host.DataSource("Items") = rsEmployees oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataField(7) = DataField(0)] // oG2Host.DataField(7) = oG2Host.DataField(0) oG2Host.Template = [DataField(9) = "BirthDate"] // oG2Host.DataField(9) = "BirthDate" oG2Host.Template = [DataField(10) = "HireDate"] // oG2Host.DataField(10) = "HireDate" rsLinks = new OleAutoClient("ADODB.Recordset") rsLinks.Open("EmployeeLinks","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb",3,3) oG2Host.Template = [DataSource("Links") = rsLinks] // oG2Host.DataSource("Links") = rsLinks oG2Host.Template = [DataField(15) = "Links"] // oG2Host.DataField(15) = "Links" oG2Host.Template = [DataField(16) = "Start"] // oG2Host.DataField(16) = "Start" oG2Host.Template = [DataField(17) = "End"] // oG2Host.DataField(17) = "End" |
9 |
ADO sample ( file, single task, single table )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataTechnology("Items") = "ADODB.Recordset;ADOR.Recordset"] // oG2Host.DataTechnology("Items") = "ADODB.Recordset;ADOR.Recordset" oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" oG2Host.Template = [DataField(7) = DataField(0)] // oG2Host.DataField(7) = oG2Host.DataField(0) oG2Host.Template = [DataField(9) = "BirthDate"] // oG2Host.DataField(9) = "BirthDate" oG2Host.Template = [DataField(10) = "HireDate"] // oG2Host.DataField(10) = "HireDate" oG2Host.Template = [DataTechnology("Links") = "ADODB.Recordset;ADOR.Recordset"] // oG2Host.DataTechnology("Links") = "ADODB.Recordset;ADOR.Recordset" oG2Host.Template = [DataSource("Links") = DataSource("Items")] // oG2Host.DataSource("Links") = oG2Host.DataSource("Items") oG2Host.Template = [DataMember("Links") = "EmployeeLinks"] // oG2Host.DataMember("Links") = "EmployeeLinks" oG2Host.Template = [DataField(15) = "Links"] // oG2Host.DataField(15) = "Links" oG2Host.Template = [DataField(16) = "Start"] // oG2Host.DataField(16) = "Start" oG2Host.Template = [DataField(17) = "End"] // oG2Host.DataField(17) = "End" |
8 |
ADO sample ( tree recordset )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataTechnology("Items") = "ADODB.Recordset;ADOR.Recordset"] // oG2Host.DataTechnology("Items") = "ADODB.Recordset;ADOR.Recordset" oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" oG2Host.Template = [DataField(1) = "EmployeeID"] // oG2Host.DataField(1) = "EmployeeID" oG2Host.Template = [DataField(2) = "ReportsTo"] // oG2Host.DataField(2) = "ReportsTo" |
7 |
ADO sample ( flat recordset )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,rsEmployees oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject rsEmployees = new OleAutoClient("ADODB.Recordset") rsEmployees.Open("Employees","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb",3,3) oG2Host.Template = [DataSource("Items") = rsEmployees] // oG2Host.DataSource("Items") = rsEmployees oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" |
6 |
ADO sample ( flat table )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataTechnology("Items") = "ADODB.Recordset;ADOR.Recordset"] // oG2Host.DataTechnology("Items") = "ADODB.Recordset;ADOR.Recordset" oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.accdb" oG2Host.Template = [DataMember("Items") = "Employees"] // oG2Host.DataMember("Items") = "Employees" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" |
5 |
XML sample ( object, MSXML.DOMDocument )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,var_G2antt,xml oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject xml = new OleAutoClient("MSXML.DOMDocument") xml.async = false xml.load("C:\Program Files\Exontrol\ExG2Host\Sample\sample.xml") oG2Host.Template = [DataSource("Items") = xml] // oG2Host.DataSource("Items") = xml oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" var_G2antt = oG2Host.Host var_G2antt.LinesAtRoot = -1 var_G2antt.SingleSel = false var_G2antt.AutoDrag = 3 |
4 |
XML sample ( file tree )
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) Error = class::nativeObject_Error endwith */ // Fired when an internal error occurs. function nativeObject_Error(Error,Description) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(Error) ? Str(Description) return local oG2Host,var_G2antt oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject oG2Host.Template = [DataTechnology("Items") = "MSXML.DOMDocument"] // oG2Host.DataTechnology("Items") = "MSXML.DOMDocument" oG2Host.Template = [DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.xml"] // oG2Host.DataSource("Items") = "C:\Program Files\Exontrol\ExG2Host\Sample\sample.xml" oG2Host.Template = [DataField(0) = "Items"] // oG2Host.DataField(0) = "Items" var_G2antt = oG2Host.Host var_G2antt.LinesAtRoot = -1 var_G2antt.SingleSel = false var_G2antt.AutoDrag = 3 |
3 |
How can I let user create new items/bars when clicking the empty area of the control
|
2 |
How do I handle events of the host
/* with (this.EXG2HOSTACTIVEXCONTROL1.nativeObject) HostEvent = class::nativeObject_HostEvent endwith */ // Notifies the application once the host fires an event. function nativeObject_HostEvent(EventID) oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? Str(oG2Host.HostEventParam(-2)) return local oG2Host,var_G2antt oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject var_G2antt = oG2Host.Host var_G2antt.BeginUpdate() var_G2antt.Columns.Add("new column") var_G2antt.EndUpdate() |
1 |
How can I get the version of the host/exg2antt control
local oG2Host oG2Host = form.EXG2HOSTACTIVEXCONTROL1.nativeObject ? oG2Host.Version ? "Host" ? oG2Host.Host.Version |