How to set af:column child element as partial trigger?
Hi all...
I have put a check box in side <af:column> tag inside <af:table> like below:
<af:table id="applications" var="b" value="#{YourApplicationsandProgressMPB.productBasket}"
rendered="#{!YourApplicationsandProgressMPB.productBasketEmpty}"
width="100%" >
<af:column gridVisible="false" width="20%">
<af:selectBooleanCheckbox id="[b]checkBox" value="#{b.selected}" autoSubmit="true" />
</af:column>
</af:table>
I required to enable a button when any of these check bobes is selected.
I could do everything except refreshing the form button.
I mentioned this check box name as partial trigger but it is not refreshing the form like other elements.
<af:panelForm partialTriggers="[b]checkBox productSelection1 ">
I think the problem occurs because the checkbox is inside a loop. So it is assigning its own names to each checkbox like formname:0:chceckBox
Could anybody please help me out in this?
How can I refresh the page when any check box is selected?
Thanks in advance....
You posted this in the wrong forum - this is the Designer forum. Try the JDeveloper forum at JDeveloper and ADF However, I happen to have seen a blog entry today that may help. Take a look at http://www.it-eye.nl/weblog/2007/08/02/jsf-partial-page-rendering-hell/
Similar Messages
-
Unable to set Labelfield for child element in List
Hi All,
Below is code I am trying to execute
<?xml version="1.0" encoding="utf-8"?>
<mx:Application
xmlns:mx="http://www.adobe.com/2006/mxml" verticalGap="0" xmlns:local="*" height="500" creationComplete="init()" >
<mx:Script>
<![CDATA[
private var arr:Array = [{ firstName: "Alex", children:{lastName: "Abc"}}]
private function init():void{list.dataProvider=arr;
]]>
</mx:Script>
<mx:List variableRowHeight="true" wordWrap="
true" id="list" labelField="
chidren.lastName" /></mx:Application>
I basically want to access the children.lastName on my List. Please let me know how exactly can I do it.
labelFunction is the best way to do this. The attached code also shows how to do it with an itemRenderer, though that would not be as efficient.
<?xml version="1.0" encoding="utf-8"?>
<mx:Application
xmlns:mx="http://www.adobe.com/2006/mxml"
layout="horizontal"
creationComplete="init()" >
<mx:Script>
<![CDATA[
private var arr:Array = [{ firstName: "Alex", children:{lastName: "Abc"}}]
private function init():void{
list1.dataProvider=arr;
list2.dataProvider=arr;
private function createLabels(item:Object):String{
return item.children.lastName;
]]>
</mx:Script>
<mx:List variableRowHeight="true"
wordWrap="true" id="list1">
<mx:itemRenderer>
<mx:Component>
<mx:Label text="{data.children.lastName}"/>
</mx:Component>
</mx:itemRenderer>
</mx:List>
<mx:List variableRowHeight="true"
wordWrap="true" id="list2"
labelFunction="createLabels"/>
</mx:Application>
If this post answers your question or helps, please mark it as such. Thanks!
http://www.stardustsystems.com
Adobe Flex Development and Support Services
labelFunction is the best way to do this. The attached code also shows how to do it with an itemRenderer, though that would not be as efficient.
<?xml version="1.0" encoding="utf-8"?>
<mx:Application
xmlns:mx="http://www.adobe.com/2006/mxml"
layout="horizontal"
creationComplete="init()" >
<mx:Script>
<![CDATA[
private var arr:Array = [{ firstName: "Alex", children:{lastName: "Abc"}}]
private function init():void{
list1.dataProvider=arr;
list2.dataProvider=arr;
private function createLabels(item:Object):String{
return item.children.lastName;
]]>
</mx:Script>
<mx:List variableRowHeight="true"
wordWrap="true" id="list1">
<mx:itemRenderer>
<mx:Component>
<mx:Label text="{data.children.lastName}"/>
</mx:Component>
</mx:itemRenderer>
</mx:List>
<mx:List variableRowHeight="true"
wordWrap="true" id="list2"
labelFunction="createLabels"/>
</mx:Application>
If this post answers your question or helps, please mark it as such. Thanks!
http://www.stardustsystems.com
Adobe Flex Development and Support Services
Silent Config: How do I create a child element
Hello,
I want to now how to refer to a child element of a new created object. The I want
to be able to set some of the parameters of the child object:
i.e.
create Server "myserver" as s1;
create Server.WebServer "myserver.mywebserver" as ws1; (???)
How is this done?? Is it mandatory that I previously define the child element
in the template or I can create it on the fly.
Regards
Cristina
Cristina,
Did you manage to solve this issue? I am facing the same situation.
Best,
Oscar
Dear SharePoint Developers,
Please help.
I need to know How to set the column order of a sealed column in a custom Content Type for the new item form NewDocSet.aspx?
I think this is a "sealed column", whatever that is, which is shown in SPD 2013 as a column of content type "document, folder, MyCustomContentType".
I know when I set the column order in my custom Content Type settings page, it is correct.
But, when I load the NewDocSet.aspx page, the column order that I set in the settings page is NOT used for this "sealed column" which is bad.
Can you help?
Please advise.
Thanks.
Mark Kamoski
-- Mark Kamoski
Hi,
According to your post, my understanding is that you want to set the column order of a sealed column in a custom Content Type for the new item form NewDocSet.aspx.
Per my knowledge, if you have Content Type management enabled for the list or library (if you see a list of content type with the option to add more), the display order of columns is set for each content type.
Drill down into one of them and you'll see the option under the list of columns for that content type.
To apply the column order in the NewDocSet.aspx page, you need to:
Select Site Settings, under Site Collection Administration, click Content type publishing. In the Refresh All Published
Content Types section, choose Refresh all published content types on next
update.
Run two timer jobs(Content Type Hub, Content Type Subscriber) in central admin(Central Administration--> Monitoring--> Review timer jobs).
More information:
http://sharepoint.stackexchange.com/questions/95028/content-types-not-refreshing-on-sp-online
Best Regards,
Linda Li
Linda Li
TechNet Community Support
How to set displayed column width for a search help
I have created an elementary search help for a custom field with a value table behind it.
The search help functions correctly, but when displayed the column widths are all 10 characters. The user has to adjust the column to view the descriptive text.
Can anyone tell me how to set default column widths for the help?
Please open you Elementary search help and see the Column width behind the Fields of your ...there increase the width of the fields
"Activate it and refresh
reward points if it is usefull .....
Girish
How to set focus on UI Element
Hi All,
I am using the below code to set the focus on the first row of the table given in the link [How to set focus at UI element ? ] on enter of an event.
data: lr_elem type ref to if_wd_view_element.
lr_elem = view->get_element( <ID of the Link to Action field>).
if lr_elem is bound.
view->request_focus_on_view_elem( lr_elem ).
endif.
I am getting "Cannot use NULL reference as object error at view".
Can you please tell me how to get the reference of the "view".
Thanks
Praveen
>
praveenkumar_81 wrote:
> Hi All,
>
> I am using the below code to set the focus on the first row of the table given in the link [How to set focus at UI element ? ] on enter of an event.
>
>
data: lr_elem type ref to if_wd_view_element.
> lr_elem = view->get_element( <ID of the Link to Action field>).
>
> if lr_elem is bound.
> view->request_focus_on_view_elem( lr_elem ).
> endif.
>
> I am getting "Cannot use NULL reference as object error at view".
>
> Can you please tell me how to get the reference of the "view".
>
> Thanks
> Praveen
Hallo Praveen,
have you controlled that id of the Linktoaction ? there you made error.
See it in the ViewElement designer .
should be something like this
lr_elem = view->get_element( 'LTA_name ' ).
How to set focus on an element inside a datatable on load
How to set focus on an element inside a datatable on load
Check out https://blogs.oracle.com/groundside/entry/ever_wondered_how_uncommitteddatawarning_works and
Decompiling ADF Binaries: Checking for dirty data
Timo
How to set unequal columns using master pages in InDesign CS3?
How to set unequal columns using master pages in InDesign CS3?
I don't have CS3 anymore but I don't think this has substantially changed in the last few versions of InDesign.
Choose View > Grids & Guides > uncheck Lock Column Guides. Then drag the column guides to the position you want.
How to set the column table so it can not be moved !
how to set the column table so it can not be moved !
m_table.getTableHeader().setReorderingAllowed(false);
m_table.getTableHeader().setResizingAllowed(false);
How to set multiple operating units in before report trigger
hi all
can any one help me out in getting clear in how to set multiple operating units in before report trigger in oracle report.
as we set single operating unit (mo_global.set_policy.context('S',81); as 81 is my operating unit).then who to set for multiple operating unit at run time.
Sounds like eBusiness Suite, right? Better ask this in the appropriate forum.
OLE2 how to set a column width of an excel file i'm creating?
how can i set the column width in an excel file i'm creating with ole?
or even, haw can i set the auto-fix properties?
Hallo !
SORRY MY ENGLISH is very BAD.
I tried to set page header and footer in Excel sheet with abap ole
DATA : BEGIN OF enter,
x(1) TYPE x VALUE '0D',
END OF enter.
DATA : format(255) TYPE c.
FORM set_page_sheet.
CALL METHOD OF excel 'ActiveSheet' = sheet.
CALL METHOD OF sheet 'PageSetup' = pagesetup.
SET PROPERTY OF pagesetup 'Orientation' = xllandscape.
SET PROPERTY OF pagesetup 'PrintTitleRows' = '$9:$12'.
CLEAR format.
ERROR
CONCATENATE 'PAGESHEET' enter-x 'PAGE &P/&N' INTO format.
ERROR
SET PROPERTY OF pagesetup 'RightHeader' = format.
CLEAR format.
CONCATENATE ' Text 1 ' enter-x 'Text 2'
enter-x 'Text 3 ' INTO format.
SET PROPERTY OF pagesetup 'RightFooter' = format.
FREE OBJECT pagesetup.
ENDFORM. " set_page_sheet
Activate report -
ERROR - The enter-x must by data type c or another then data type x
Thanks for answer.
How programmatically set size of report element in Java
In topic
[How programmaticaly set size of some field?|How programmaticaly set size of some field?]
someone changing programmatically report element, but I think this part of code
is in .NET framework
For example I mean something like following snippet
BoxObject box = (BoxObject) reportClientDocument
.getReportDefController().findObjectByName("headerBox");
BoxObject newBoxObject=new BoxObject(box);
Border border=new Border();
border.setBorderColor(new Color(255,255,255));
newBoxObject.setBorder(border);
newBoxObject.setFillColor(new Color(255,255,255));
reportClientDocument
.getReportDefController().getReportObjectController().modify(box, newBoxObject);
Why I think this is in .NET framework because java object "ReportClientDocument" don't have "getReportDefController()" method (I donu2019t know .NET).
What I want to do, I want to take "Details" (part of report) and change size.
If there is no way to take "Details" how can I take other report element e.g. Text Object
Ernest,
What enviroment are you working in? Because my ReportClientDocument object does have the getReportDefController method. How are you declaring your object?
Try something like:
private static com.crystaldecisions.sdk.occa.report.application.ReportClientDocument myRCD;
BoxObject box = (BoxObject) myRCD.getReportDefController().findObjectByName("headerBox");
Cheers
Darren
HOw to check for the Child Elements USing only SAX Parsr?
HI Guyz,
How to check whether there are any Child Elements in an XML file using ONLY SAX parser ??? I have a requirement of checking first whether there is any Child Elements exists for a Element or not and based on that I have to take certain actions. Can anyone suggest me How to do that ???
Thanx
KK
Since SAX is event controlled, you wont know if there's a child element unless you actually bump into it with the Parser. You'll simply get another startElement event after your current one.
/Tom
How To Set Excel Column Format Latebinding
private void WriteToExcel(ref System.Data.DataTable dtExcel)
//Microsoft.Office.Interop.Excel.Application oXL = null;
//Microsoft.Office.Interop.Excel._Workbook oWB;s
//Microsoft.Office.Interop.Excel._Worksheet oSheet;
//SaveFileDialog SFD = new SaveFileDialog();
//SFD.Filter = "Excel 97-2003 Workbook(*.xls)|*.xls|Excel Workbook(*.xlsx)|*.xlsx|Excel Binary Workbook(*.xlsb)|*.xlsb|" +
//"Excel Macro-Enabled Workbook(*.xlsm)|*.xlsm";
//SFD.ShowDialog();
/*Cell Format Text,
Format Excel cells to store values as text
Formating Excel cells to text format will solve the problem of losing leading zeo values when you export data from other data sources to excel.
Excel.Range formatRange;
formatRange = xlWorkSheet.get_Range("a1", "b1");
formatRange.NumberFormat = "@";
xlWorkSheet.Cells[1, 1] = "098";
if (dgvData.RowCount == 0)
MessageBox.Show("GridView is Empty.");
return;
tlsStatus.Text = "Export To Excel Strats.... ";
tlsStatus.ForeColor = System.Drawing.Color.DeepPink;
prbExcelGen.Value = 0;
prbExcelGen.Minimum = 0;
prbExcelGen.Maximum = dgvData.RowCount;
prbExcelGen.Step = 1;
prbExcelGen.Refresh();
object objApp_Late;
object objBook_Late;
object objBooks_Late;
object objSheets_Late;
object objSheet_Late;
object objRange_Late;
object[] Parameters;
string[] headers = new string[dgvData .ColumnCount];
string[] columns = new string[dgvData.ColumnCount];
int i = 0;
int c = 0;
for (c = 0; c <= dgvData.ColumnCount - 1; c++)
headers[c] = dgvData.Rows[0].Cells[c].OwningColumn.Name.ToString();
//Convert Cell Names To A,B,C...Z , 65+C=CHR(C)=>A WHEN C=0
i = c + 65;
columns[c] = Convert.ToString((char)i);
try
// Get the class type and instantiate Excel.
Type objClassType;
objClassType = Type.GetTypeFromProgID("Excel.Application");
objApp_Late = Activator.CreateInstance(objClassType);
//Get the workbooks collection.
objBooks_Late = objApp_Late.GetType().InvokeMember("Workbooks",BindingFlags.GetProperty, null, objApp_Late, null);
//Add a new workbook.
objBook_Late = objBooks_Late.GetType().InvokeMember("Add",BindingFlags.InvokeMethod, null, objBooks_Late, null);
//Get the worksheets collection.
objSheets_Late = objBook_Late.GetType().InvokeMember("Worksheets",BindingFlags.GetProperty, null, objBook_Late, null);
//Get the first worksheet.
Parameters = new Object[1];
Parameters[0] = 1;
objSheet_Late = objSheets_Late.GetType().InvokeMember("Item",
BindingFlags.GetProperty, null, objSheets_Late, Parameters);
//if (true)
// Create the headers in the first row of the sheet
for (c = 0; c <= dgvData.ColumnCount - 1; c++)
//Get a range object that contains cell.
Parameters = new Object[2];
Parameters[0] = columns[c] + "1";
Parameters[1] = Missing.Value;
objRange_Late = objSheet_Late.GetType().InvokeMember("Range",
BindingFlags.GetProperty, null, objSheet_Late, Parameters);
//Write Headers in cell.
Parameters = new Object[1];
Parameters[0] = headers[c];
objRange_Late.GetType().InvokeMember("Value", BindingFlags.SetProperty,
null, objRange_Late, Parameters);
// Now add the data from the grid to the sheet starting in row 2
for (i = 0; i < dgvData.RowCount - 1; i++)
prbExcelGen.PerformStep();
prbExcelGen.Refresh();
for (c = 0; c <= dgvData.ColumnCount - 1; c++)
//Get a range object that contains cell.
Parameters = new Object[2];
Parameters[0] = columns[c] + Convert.ToString(i + 2);
Parameters[1] = Missing.Value;
objRange_Late = objSheet_Late.GetType().InvokeMember("Range",
BindingFlags.GetProperty, null, objSheet_Late, Parameters);
//Write Headers in cell.
Parameters = new Object[1];
Parameters[0] = dgvData.Rows[i].Cells[headers[c]].Value.ToString();
objRange_Late.GetType().InvokeMember("Value", BindingFlags.SetProperty,
null, objRange_Late, Parameters);
//if (i == 0)
// BoldRow(i, c, (EXL._Worksheet)objSheet_Late);
tlsStatus.Text = "Exporting Records...." + i;
//Return control of Excel to the user.
Parameters = new Object[1];
Parameters[0] = true;
tlsStatus.Text = "Exporting Completed.";
objApp_Late.GetType().InvokeMember("Visible", BindingFlags.SetProperty,
null, objApp_Late, Parameters);
objApp_Late.GetType().InvokeMember("UserControl", BindingFlags.SetProperty,
null, objApp_Late, Parameters);
* oWB.SaveAs(fileName, Excel.XlFileFormat.xlOpenXMLWorkbook,
missing, missing, missing, missing,
Excel.XlSaveAsAccessMode.xlNoChange,
missing, missing, missing, missing, missing);
//oWB = (Microsoft.Office.Interop.Excel._Workbook)objBook_Late;
//oWB.SaveAs("file", EXL.XlFileFormat.xlXMLSpreadsheet, Type.Missing, Type.Missing, Type.Missing, Type.Missing, EXL.XlSaveAsAccessMode.xlNoChange, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing);
//oWB.Save();
catch (Exception theException)
String errorMessage;
errorMessage = "Error: ";
errorMessage = String.Concat(errorMessage, theException.Message);
errorMessage = String.Concat(errorMessage, " Line: ");
errorMessage = String.Concat(errorMessage, theException.Source);
MessageBox.Show(errorMessage);
finally
using the above code i am writing to excel sheet can some one help me to tell how can i set a column type as text
Thanks Forum,
i got the answer here
https://social.msdn.microsoft.com/Forums/windows/en-US/36340ada-e13b-41cb-a31d-fb76121aa0d2/c-exporting-text-file-to-excel-and-column-formatting-problem?forum=csharpgeneral
How to set JTable column's color?
How can I set JTable Columns' color? I only found this class DefaultTableCellRenderer
which can set cell's color.
rmalina wrote:
You are going to need to derive a renderer class for your Column from DefaultTableCellRenderer and override the following function with something like this:
@Override
public Component getTableCellRendererComponent(JTable jTable, Object oValue, boolean isSelected, boolean hasFocus, int nRow, int nColumn) {
super.setForeground(Color.GREEN);
super.setBackground(Color.GREEN);
}That would set your column to green.
Edited by: rmalina on Jul 28, 2008 8:47 AMHow can I know I only change the columns' color instead of other cells?
Maybe you are looking for
-
Ipod Touch Recovery Mode Loop - Error Code 14
I attempted to update my Ipod Touch (3rd Gen 32 GB) to the latest firmware (IOS 5 i think). It froze during the process and has since been stuck in a Recovery Mode loop. I have followed all recommendations on their website, called Apple support and r
-
Archive Link and external URL Link
Hi, we use Archive Link, NO own documents (like CV01N,..). We want to define different document types (oac2) and link them to via url to an external webserver, the user should see the doc in the normal attachment list. Doc Typ url DOC1 http
-
Why do my images on iWeb look shinny when they look fine in iPhoto? On some computers the image looks better than on my MacBook Pro. I am using doteasy as my host company. Any thoughts?
-
Disable BI Publisher options on dashboard
Hello Anyone know how to disable some of the options that appear when a BI Publisher report is added to a dashboard. I want to be able to keep "view", "send","analyze" and the templates but lose "Schedule" and "Export". Can't see anything obvious in
-
Using a thread to write a file from a servlet
Does anyone have some code that can help out my problem: I am writing a file from a servlet, but the servlet completes and loads another page prior to the file writing to disk being completed. I have tried using threads to stop the serlvet until the