Active reports textbox control - activereports

I am using Active reports 6 as Report Control in my .Net application.
How will I get the value of a data bound text box control after the control is initialized?

You can get the value after the data binding of each row which happens immediately before the section's Format event is fired.
In detail_Format event. you can retrieve the value using the textbox value or text properties
txtMyTextbox.Text (returns the formatted text that would render in the report)
txtMyTextbox.Value (returns the bound value, without formatting)
hope this helps.
http://activereports.grapecity.com

Related

Access form / textbox default value problem

I have an access continous form:
I placed a unbound text box txt1 in the header where user enters the number of the assignment. I want all rows in the form to have the same assignement number - entered only once in the header. (Later, txt2 would be hidden).
In the form, i added a another textbox and placed default value as =[txt1].
My problem is that this text is being populated only in the second row, when i start typing in the first row.
As this:
Refreshing does not help.
Any ideas?
Thank you!
Textbox 2 does not populate because the default value is not available when record edit is initiated by input into unbound textbox 1. Code will have to set Value of textbox 2 with the textbox 1 input. So with textbox 1 AfterUpdate event:
Me.textbox2 = Me.textbox1.
Alternative is to not use unbound textbox. Instead, use AfterUpdate event of textbox 2 to set its DefaultValue property. Subsequent records will populate with that value until user enters another and the DefaultValue will be reset.

Reference Table to fill calendar form

In Access 2010, I've built a calendar Form that I want to be able to display who is off in a given month.
Each box of the calendar obviously represents a different day. I've got a table called "Separated" set up that ultimately stores the associate name and the date they are off -- one day per record.
Here's what I've done so far to try to test it on just one of the boxes (representing a day):
Private Function fillDays()
Dim rsNames As DAO.Recordset
Set rsNames = CurrentDb.OpenRecordset("SELECT * FROM Separated")
If Not rsNames.EOF Then
b0.Text = rsNames![Associate]
End If
Set rsNames = Nothing
End Function
I get the following debug note:
"Run-Time Error '2185"
"You can't reference a property or method for a control unless the control has the focus."
The debugger highlights the line with "b0.text = rsNames![Associate]
Is there some whay that I need to reference an index number from my "Separated" table?... or perhaps using a query method of some sort would be more effecient.
Assuming b0 is a textbox, the error you are getting is due to the fact that you can't use it's Text property when said textbox hasn't got the focus.
As stated in MSDN, «While the control has the focus, the Text property contains the text data currently in the control; the Value property contains the last saved data for the control. When you move the focus to another control, the control's data is updated, and the Value property is set to this new value. The Text property setting is then unavailable until the control gets the focus again» (emphasis mine).
Try using Value (help here) instead:
b0.Value = rsNames![Associate]

GWT DataTable TextInputCell is not showing the correct value

I have a DataGrid with a TextInputCell column, using a ListDataProvider. When the value in a cell is changed I am creating a RequestContext and calling RequestContext#edit with the original entity for the row that is being edited. I then set the field in the mutable version of the proxy to the value from the edited cell. This all works nicely, and I can save the change successfully to the database. However, on the server I modify the value before saving the change, and send the modified entity (DTO) back to the client. In the Receiver#onSuccess method I store the new entity in the list data provider, and then call ListDataProvider#refresh. But the value that is shown in the DataGrid doesn't change to reflect the modification on the server. I've looked at the value that is supplied to the TextInputCell#getValue method, and it is correct, that is, it is the value that contains the modification applied on the server.
I tried creating another column in the grid that is just a TextCell, and supplied the same value in getValue for that cell; in this case the displayed value is correctly updated by the refresh, reflecting the modified value that was returned from the server.
So, my question is: where does the cell get its value? When I look at the value returned by my TextInputCell#getValue method it appears to be the correct value, but that value is not being shown on the screen (the value shown on the screen is the value that was in the proxy object prior to sending the request to the server).
Note: I looked at this question, but it did not work in my situation.
I have a very similar problem.
I have a page showing a grid with two column: the first one has check boxes instead of text.
The value of the check box is given by:
public Boolean getValue(Item item) {
return selectedItems.contains(item);
}
When the user checks a check box, I store the value in a map (selectedItems).
At the bottom of the page there is a "Clear" button that reset the map and calls the table redraw, but the status of the check boxes does not revert to the original status (i.e. the check boxes stay selected).
Debugging the code I've found that getValue() returns the correct value, but is like the table caches the cells.
The only workaround I have found, without rebuilding the whole table, was to remove the check boxes' cell and add it again on "Clear".
itemsTable.removeColumn(0);
itemsTable.insertColumn(0, makeSelectionColumn());
The method makeSelectionColumn() must return a new cell.

Update/Refresh a hidden parameter in SSRS after action operation in line chart

I am new to SSRS report. I have a SSRS report in which have a main report with Line chart and a sub report to show the detail.
In line chart on click of the data point(series property) have to update the sub report detail on the basis of the data point value. For getting the value of the selected line chart have used a hidden parameter and which is then passed to the sub report to get the respective data..
I have some parameters also so on selection of one of the parameter's i have to reset the hidden parameter value but the value is not reset and showing the last value set using the line chart action property.
Is there any way I can reset the hidden parameter after updating the drill down report. I am using web service to show the data in the report.
Thanks in advance
Supriya Khamesra
Assuming you whishing to reset a parameter that you getting from a main report into a subreport, you can do as following:
From the sub-report you can send the parameter back to the main report and put in the action screen/parameters - hard coded value which will "reset" your parameter. that way the parameter in the main report always be reset according to the hard-coded value you putted in the subreport.

GWT: How to know if my listbox selected index changed

I have a listbox ,which have two values value1 and value 2 ..
Now my listbox values got change programatically (I dont change the values Manually)
I want to get a prompt prompt whenever a value get changes / index get changed, inside my listbox
ListBox listBox = new LisBox();
if i use
listBox.addClickHandler
or
listBox.addChangeListener
or
listBox.addChangeEvent
They all only shows me a prompt when i manually change my listbox selected Index.But how will i get a prompt when my listbox selectedIndex changed programatically
Thanks
I am assuming that you are using
setSelectedIndex
The javadoc says explicitly states that it will not send an event. You could overwrite setSelectedIndex and send your own event. A good explaination of doing so can be found here.