Get selected InCopy story
Hi
How do I get a hold of the InCopy story (an UID) selected in the Assignment Panel ?
Kind Regards
Anne
Hi Anne,<br /><br />I had a similar task when I needed to find selected datalink UIDs in the Links panel. Without error checking, the solution lookes like the following (you will definitely have to modify it):<br /><br />InterfacePtr<IPanelControlData> pPanel( Utils<IPalettePanelUtils>()->QueryPanelByWidgetID(kLinksPanelWidgetID) );<br /><br />//...<br />IControlView* pLView = pPanel->FindWidget(kLinksListWidgetID);<br />if (!pLView || !pLView->IsVisible())<br /> pLView = pPanel->FindWidget(kLinksListSmallWidgetID);<br /><br />//.... <br /><br />InterfacePtr<IListBoxController> pLBController(pLView, UseDefaultIID());<br />//.... <br /><br />K2Vector<int32> vSelection;<br />pLBController->GetSelected(vSelection);<br /><br />InterfacePtr< IListControlDataOf<IDataLink*> > pListData(pLView, UseDefaultIID());<br /><br />// now iterate through pListData using vSelection
Similar Messages
-
Saving InCopy Story with Font and Style information...
Dear All,
Can anyone can shed any light on an InCopy story export problem I'm having?
I've got two versions of a function in a shared library, one for CS4 and one for CS5, which is used for both InCopy and InDesign.
The story export works okay and normally outputs the font and style information which is used by the story.
I've just added code to include all font and style resources dependent on a system setting.
The CS4 version works fine and I get a satisfying amount of file bloat if I turn the option on.
The CS5 version works as expected in InDesign but not when it's called from InCopy.
In fact if I turn the setting on in InCopy I get no font information at all, if I turn it off then I get the font info used by the story.
The call to SetInCopyInterchangeExportOptions returns kNoError(nil), so I imagine it's worked...
Is there anyway I can trace what's going on in the export in InCopy.
Is this the right call to acheive my aim?
Thanks in advance for any help forthcoming.
Regards
Caerwyn
#if (CREATIVE_SUITE_VERSION == CS4)
ErrorCode PrSnippetUtils::ExportInCopyStory( IPMStream *s , const UIDRef& storyUIDRef )
ErrorCode nResult = kFailure;
Utils<IINXExportOptionsUtils> wsExportOptions;
if ( !wsExportOptions )
return kFailure;
bool16 oldIncludeGraphicProxyData = wsExportOptions->GetOutputInCopyGraphicProxyData();
bool16 oldIncludeAllResources = wsExportOptions->GetInCopyIncludeAllResources();
InterfacePtr<IInCopyInterchangeExportOptions> storyExportOptions( storyUIDRef, UseDefaultIID() );
if ( storyExportOptions )
wsExportOptions->SetOutputInCopyGraphicProxyData( storyExportOptions->GetIncludeGraphicProxyData() );
wsExportOptions->SetInCopyIncludeAllResources( SaveAllStoryResources() );
INXOptions options = kINXExpanded;
nResult = Utils<ISnippetExport>()->ExportInCopyInterchange( s, UIDList( storyUIDRef ), options );
// restore export options
wsExportOptions->SetOutputInCopyGraphicProxyData( oldIncludeGraphicProxyData );
wsExportOptions->SetInCopyIncludeAllResources( oldIncludeAllResources );
return nResult;
#endif
#if (CREATIVE_SUITE_VERSION == CS5)
ErrorCode PrSnippetUtils::ExportInCopyStory( IPMStream *s , const UIDRef& storyUIDRef )
InterfacePtr<IWorkspace> ws(PrIDContextUtils::GetExecutionContextSession()->QueryWorkspace());
if ( !ws )
return kFailure;
InterfacePtr<IInCopyInterchangeExportOptions> wsExportOptions( ws, UseDefaultIID() );
if ( !wsExportOptions )
return kFailure;
ErrorCode nResult = kFailure;
UIDRef wsUIDRef = ::GetUIDRef( ws );
bool16 oldIncludeProxies = wsExportOptions->GetIncludeGraphicProxyData();
bool16 oldIncludeAllResources = wsExportOptions->GetIncludeAllResources();
InterfacePtr<IInCopyInterchangeExportOptions> storyExportOptions( storyUIDRef, UseDefaultIID() );
Utils<IInCopySharedUtils> iInCopySharedUtils;
// set workspace export options
if ( storyExportOptions && iInCopySharedUtils )
bool16 bIncludeProxies = storyExportOptions->GetIncludeGraphicProxyData();
bool16 bIncludeAllResources = SaveAllStoryResources();
nResult = iInCopySharedUtils->SetInCopyInterchangeExportOptions( wsUIDRef,
kTrue, bIncludeProxies, kTrue, bIncludeAllResources );
nResult = Utils<ISnippetExport>()->ExportInCopyInterchange( s, UIDList( storyUIDRef ) );
// restore workspace export options
if ( iInCopySharedUtils )
iInCopySharedUtils->SetInCopyInterchangeExportOptions( wsUIDRef,
kTrue, oldIncludeProxies, kTrue, oldIncludeAllResources );
return nResult;
#endifThat is a sign that your preference files are becoming corrupt. Something is wrong with your system if this is happening regularly.
Bob -
[CS3] Custom Data Links for InCopy story
Hi,
I want to create custom data links for InCopy story.
I am retrieving incopy story from the database and importing it on the document. I have created custom data link as shown in the samples but if I open the indesign document in InCopy I get message - no incopy story found - galley and story view are not avaiable.
Also when I import InCopy file it is also added in Assignment Panel. I want to handle check-in/check-out on my own.
Is there any special thing for creating InCopy Data Links ?
Thanks in Advance.
AndersonHi Norio
Thanks a lot for your help and your hints.
Its my first time to solve a problem like this. And I have no idea what I have to do exactly. I mean I see the samples in the SDK, see the properties and so on. And I suppose I have to add my property to kINXScriptManagerBoss. But thats all at the moment.
I don't know what I have to do exactly. I don't know what elements I have to add. I don't know how I can add a custom defined variable type as a property.
I have a structure defined for my slugs:
struct structTabFlowTableModelSlug
int32 iUIDTableModel; // ID des Tabellenmodells
int32 iLinkPASHID; // Entspricht der ID der Produktion LinkPASHID
int32 iDtpTableID; // Entspricht der ID der DTP Tabelle (Tabelle DtpTable)
void reset() {
iUIDTableModel = -1;
iLinkPASHID = -1;
iDtpTableID = -1;
typedef structTabFlowTableModelSlug stTabFlowTableModelSlug;
And I think I have to add this structure as a property. But does this work? How?
In my plugin the slugs are added to a ITableModel interface. So I suppose I have to add the property to this scripting element. But I am not sure.
Its a bit tricky for me to implement this.
But anyway, thanks for your help.
Regards
Hans -
Default hierarchy not getting selected in the GOTO report.
Hi friends,
I am facing a weird problem in a jump query(GoTo query). I am giving an input for the main query. The input values are week and Organization(it is a hierarchy). I am executing the report and after that i am going into the jump query through the main query.
In the GoTo Query, when i right click on the Organization -> properties -> Chacteristics -> i could find that the hierarchy is not getting selected by default. I need to go and select from the dropdown manually.
If i execute the same GOTO report directly without going through main query, I am able to see the default hierarchy. I would like to see the same in my first case as well(i.e when i run the query through the Main Query).
Can somebody help me in achieving this.
Thank you
Sunil@ is a default value as per ALV internal process. This is used in icons .
I think this is causing the confusion.
Check in the fieldcat if there is any adjsutment to be made to handle this.
Br,
Vijay -
The ToC node is not getting selected although the help result pane displays the correct help page
I have followed steps given below for a merged project system:-
1. I created 3 projects Module_1 and Module_2.
2. Created the CHM output for the above 2 projects.
3. Created a Main project.
4. Merged the above 2 CHM in the project.
5. Created a new window and added Main.hhc in the TOC option under advance properties.
6. Generated html output for entire project Main.chm.
7. Decompile the ‘Main.chm’ and extracted the ToC file ‘Main.hhc’.
8. For each module project, imported ‘Main.hhc’ as a Baggage File, created window definitions same as Main project and with reference to ‘Main.hhc’.
9. Again generated html output for all the modules and copied both the CHM at the same place.
10. Now regardless of my entry point I am able to see entire ToC.
Issue: When I open Module_1.chm, the chm is displayed as follows, but Main book is highlighted instead of module 2 Book. As I have selected both the options, i.e. Auto-synchronize ToC and Always Show Selection option (when generating chm), Module 1 book should get selected.
Is there a way to control the selection in the LHS pane? I am working on a project which has 15 module chms and the chms are integrated with the application. When I press F1 on a module, the default topic is getting displayed and the respective module is not selected in the LHS pane.
Best regards,
/VikasI have followed steps given below for a merged project system:-
1. I created 3 projects Module_1 and Module_2.
2. Created the CHM output for the above 2 projects.
3. Created a Main project.
4. Merged the above 2 CHM in the project.
5. Created a new window and added Main.hhc in the TOC option under advance properties.
6. Generated html output for entire project Main.chm.
7. Decompile the ‘Main.chm’ and extracted the ToC file ‘Main.hhc’.
8. For each module project, imported ‘Main.hhc’ as a Baggage File, created window definitions same as Main project and with reference to ‘Main.hhc’.
9. Again generated html output for all the modules and copied both the CHM at the same place.
10. Now regardless of my entry point I am able to see entire ToC.
Issue: When I open Module_1.chm, the chm is displayed as follows, but Main book is highlighted instead of module 2 Book. As I have selected both the options, i.e. Auto-synchronize ToC and Always Show Selection option (when generating chm), Module 1 book should get selected.
Is there a way to control the selection in the LHS pane? I am working on a project which has 15 module chms and the chms are integrated with the application. When I press F1 on a module, the default topic is getting displayed and the respective module is not selected in the LHS pane.
Best regards,
/Vikas -
How to get selected value from selectOneRadio ???
Hi...i want to how to get selected value from selectOneRadio and use it in another page and in backing bean.
Note i have about 10 selectOneRadio group in one page i want to know value of each one of them.
Plzzzzzzzz i need helpYou have a datatable in which each row is a question, correct?
Also in each row you have 5 possible answers that are in a radio, correct?
So,
You need to put in your datatable model, a question, and a list of answers (5 in yor case) and the selected one.
So you will have a get to the question, an SelectItem[] list to populate the radios and another get/set to the selected question.
ex:
<h:selectOneRadio value="#{notas.selectedString}" id="rb">
<f:selectItem itemValue="#{notas.valuesList}"/>
</h:selectOneRadio>
Search the web for examples like yours. -
How to get selected value from OADefaultListBean.
Hi All,
How to get selected value from OADefaultListBean ?
Thanks,Hi,
To identify the user's selection(s) when the page is submitted, you would add the following logic to your processFormRequest() method:
OADefaultListBean list =
(OADefaultListBean)webBean.findChildRecursive("positionsList");
String name = list.getName();
String[] selectedValues = pageContext.getParameterValues(name);
To retrieve all the values in the list box, call list.getOptionsData().
--Prasanna -
How to get selected value from one choice list
Hi All,
i want to get selected value in onechoice list.how to achive this
Regards,
Smarancheck these
http://groundside.com/blog/DuncanMills.php?title=adf_the_list_binding_value_problem&more=1&c=1&tb=1&pb=1
http://blogs.oracle.com/jdevotnharvest/2010/12/reading_the_selected_value_of_an_adf_bound_select_list_in_java.html
http://www.oracle.com/technetwork/developer-tools/jdev/listbindingvalue-088449.html -
How to get selected value from SelectOneChoice
Hi,
I'm facing a problem to get selected value from SelectOneChoice. I have valueChangeListener event on a (SelectOneChoice)item. After user makes a choice I want to store selected value in a bean property to pass it to a method.
For example List item shows dname from dept table after user makes a choice I want to get deptno and populate into bean which I use to pass into my method.
If I use valueChangeEvent.getNewValue() I always get negative value instead I want deptno selected. Sample code pasted below.
public void setDeptno(ValueChangeEvent valueChangeEvent) {
BindingContainer b = getBindings();
OperationBinding oB = b.getOperationBinding("setDeptno");
//Checking instance of because same method is called from another text inputText item.
if (valueChangeEvent.getSource() instanceof CoreSelectOneChoice){
CoreSelectOneChoice cN = (CoreSelectOneChoice)valueChangeEvent.getSource();
if (columnName.getId().toString().equals("deptDname")){
JSFUtils.setManagedBeanValue("dept.deptDeptno",valueChangeEvent.getNewValue());
}if your selectOneChoice has value equal to #{bindings.deptno} bound to the iterator Dept1Iterator,
then the backing code will look more like
public void setDeptno(ValueChangeEvent valueChangeEvent) {
BindingContainer b = getBindings();
OperationBinding oB = b.getOperationBinding("setDeptno");
//Checking instance of because same method is called from another text inputText item.
if (valueChangeEvent.getSource() instanceof CoreSelectOneChoice){
CoreSelectOneChoice cN = (CoreSelectOneChoice)valueChangeEvent.getSource();
if (columnName.getId().toString().equals("deptDname")){
FacesContext ctx = FacesContext.getCurrentInstance();
Application app = ctx.getApplication();
ValueBinding bind = app.createValueBinding("#{bindings.Dept1Iterator.currentRow}");
Row row = (Row)bind.getValue(ctx);
JSFUtils.setManagedBeanValue("dept.deptDeptno", row.getAttribute("deptno"));
} I haven't tested it, so it could perfectly not work at all -
Dvt:pivotFilterBar - how to get selected values from filter
Hi all,
I have a question: how to programmatically get selected values from pivot table's filter bar?
I have tried to use
pivotTable.getDataModel().getDataAccess().getValueQDR(startRow, startCol, DataAccess.QDR_WITH_PAGE);but for page edge dimensions it returns BAD DATA, it seems that it returns some cached values.
Environment: JDev 11.1.1.3.0 without any patches.
thanks,
MiroslawHi,
You can retrieve the selected value in the PivotFilterBar through the model of PivotFilterBar, instead of dataaccess:
// get the model from the pivot filter bar instance
QueryDescriptior queryDescriptor = (QueryDescriptor)pivotFilterBar.getValue();
// retrieve a list of criterion, each one is used to populate each lov within the pivot filter bar
ConjunctionCriterion conjunctionCriterion = queryDescriptor.getConjunctionCriterion();
List<Criterion> criterionList = conjunctionCriterion.getCriterionList();
for (int i=0; i<_criterionList.size(); i++) {
AttributeCriterion criterion = (AttributeCriterion)criterionList.get(i);
// _selected is the currently selected value
Object selected = criterion.getValues().get(0);
System.out.println(_selected);
Hope that helps,
Chadwick -
Get selected elements from a table
Hi all,
I have a requirement like i m enhancing standard component in that i have added one button on click of that i want fetch the selected line item from the table ( which is a normal table). selection mode is auto.
i tried with the following code.
DATA:lr_element TYPE REF TO if_wd_context_element,
lv_index TYPE i.
*--Get selected element
lr_element = wdevent->get_context_element( name = 'CONTEXT_ELEMENT' ).
****Here itself its throughing dump because lr_element is initial***************
*--get selected element index.
lv_index = lr_element->get_index( ).
can any one help me what is the wrong.. else suggest me how to get the selected elements from a table....
Thanks in advance.*--Get selected element
lr_element = wdevent->get_context_element( name = 'CONTEXT_ELEMENT' ).
if lr_element is bound.
lv_index = lr_element->get_index( ).
endif.
Instead you can directly read the node if that row is a lead selected one.
lo_node = wd_context->get_child_node( name = 'EMP' ). "Emp is node name
lo_ele = lo_node->get_lead_selection( ).
or
lv_index = lo_node->get_lead_selection_index( ).
where is the above code written..is it written in OnLeadSelect event of the TABLE..
can any one help me what is the wrong.. else suggest me how to get the selected elements from a table....
As the selection mode is Auto there is no multiple selection..hence try to use the lead selection only.
Edited by: Lekha on Jan 3, 2012 6:47 PM -
Getting selected values from a data table
My data table gets values directly from a result set.
I went through http://balusc.blogspot.com/2006/06/using-datatables.html#top ,
however, the data table shown in this example takes values from a simple list. I have trouble in getting selected values.
Can anyone suggest how to select multiple values. here is a small code sample of what I have
SessionBean
ResultSet rs= db.retrieve_draft();
datamodel = new ResultSetDataModel();
datamodel.setWrappedData(rs);This is the JSF
<h:dataTable binding="#{Engineer.dataTable1}" headerClass="list-header" id="dataTable1"
rowClasses="list-row-even,list-row-odd" style="left: 144px; top: 192px; position: absolute"
value="#{SessionBean1.datamodel}" var="currentRow">
<h:column id="column1">
<h:outputText id="outputText77" value="#{currentRow['report_number']}"/>
<f:facet name="header">
<h:outputText id="outputText78" value="Report Number"/>
</f:facet>
</h:column>Edited by: ktip on Jul 29, 2008 11:04 AMHere is what I was doing :
This is my Session Bean (viz. SessionBean1)
private CachedRowSetDataProvider draft_infoDataProvider;
private CachedRowSetXImpl draft_RowSet;
public CachedRowSetDataProvider getDraft_info() {
return draft_infoDataProvider;
public void setDraft_info(CachedRowSetDataProvider draft_info) {
this.draft_info = draft_infoDataProvider;
public CachedRowSetXImpl getDraft_RowSet() {
return draft_RowSet;
public void setDraft_row(CachedRowSetXImpl draft_row) {
this.draft_row = draft_RowSet;
public void get_drafts()
Class.forName("com.mysql.jdbc.Driver");
String url = "jdbc:mysql://localhost:3308/test";
String dbUser = "root";
String dbPassword = "adminadmin";
con = DriverManager.getConnection(url, dbUser, dbPassword);
String sql="SELECT report_id from reports WHERE status='Draft' ";
ResultSet rs=null;
try
Statement stmt1=con.createStatement(ResultSet.TYPE_SCROLL_INSENSITIVE,ResultSet.CONCUR_READ_ONLY);
rs=stmt1.executeQuery(sql);
draft_RowSet=new CachedRowSetXImpl();
draft_RowSet.populate(rs);
draft_infoDataProvider=new CachedRowSetDataProvider(draft_RowSet);
result="ok";
catch(SQLException e)
System.out.println(e);
result="fail";
Here is my jsp page (developed in Netbeans 6.1) showing the data table
<webuijsf:table augmentTitle="false" binding="#{Engineer.table1}" clearSortButton="true" deselectMultipleButton="true"
id="table1" selectMultipleButton="true" sortPanelToggleButton="true"
style="left: 48px; top: 144px; position: absolute; width: 450px" title="Table" width="0">
<webuijsf:tableRowGroup id="tableRowGroup1" rows="10" sourceData="#{SessionBean1.draft_infoDataProvider}" sourceVar="currentRow">
<webuijsf:tableColumn headerText="report_number" id="tableColumn1" sort="test_report.report_number">
<webuijsf:staticText id="staticText1" text="#{currentRow.value['reports.report_id]}"/>
</webuijsf:tableColumn>
</webuijsf:tableRowGroup>
</webuijsf:table>Doing all this just resulted in a javax.Naming.Exception : Data Source is null
I tested this piece of code to give me the number of rows in the underlying rowset and it worked well. But somehow I could not get to display the data. Am I missing something?
Edited by: ktip on Jul 31, 2008 1:21 PM -
Hi
I use JDev 11.1 with ADF, i have grid, i need to get selected row of grid when i press buttom, how can i do that?
ThanksHi,
You have a table in your page that is based on a viewObject iterator and you need to get the selected row in your backing bean when you click on a button.
Did I get this right?
If so then you need to add an actionListener on this button that executes a method in the backing bean.
the button code:
<af:commandButton text="commandButton 1" id="cb1"
actionListener="#{myBean.buttonActionListener}"/>In this method you need to add code like this:
public void buttonActionListener(ActionEvent actionEvent) {
BindingContext bindingctx=BindingContext.getCurrent();
DCBindingContainer bindings=(DCBindingContainer)bindingctx;
DCIteratorBinding iter= bindings.findIteratorBinding("iteratorName");
Row currentRow=iter.getCurrentRow();
}If this is not what you need give some more details.
Gabriel -
How can I get selection screen values from outside of program?
Hi. all.
Now. I'm developing moritoring systems and I have problems. for getting selection screen values in runtime. Is there any function, methods or structure to know this?
I'd like to get selection screen values while several programs working in runtime and update these values to table to show current system's status and input values for users in real time.
For example.
Now. 3 PGMs are working on systems.
each PGM is ZAAA01, ZAAA02, ZAAA03.
and ZAAA01 needs input parameter P01, ZAAA02 needs input parameter P02, ZAAA03 needs input parameter P03.
In this case, I have to know values of P01, P02 and P03.
The mornitoring systems will show current working status of PGMs(ZAAA01~03)' and these PGMs' input values.
As fas as I know, the structure 'SCREEN' can be used in each PGM for runtime. Is there any SAP system structure or something else for this purpose?
I hope your hopeful repsponse.
Thanks.Umm..I need to explain more about this.
of course I know SET, GET PARAMETERS.
But I'd like to minimize coding for each PGM level.
I have over hundreds PGMs and I have to develop the PGM(including tables and structures) that mornitor
all of those PGMs on a report in real-time.
This PGM is kind of Process Manager.
First I should know dialogue job PGM and background job that pass parameters using SAP(ABAP) Memory.
And then I have to update those PGMs' input values via screens into tables in real-time.
So, I couldn't use SET,GET PARAMETERS for this PGM.
I want to know methods that can be used for getting information about runtime PGMs' selection screen field values in SAP systems wide.
Please help me some one knows this. -
How to get selected items from a tree in backing bean without adfbc
Hi ADF Experts,
Below is my code for af:tree. My question is how can I get selected Items from the selectionListener (without adf bc) this uses formation of tree from backing bean.
Using Jdev 11.1.1.7.0
<af:tree var="node" value="#{pageFlowScope.MerchandizeBean.model}"
binding="#{pageFlowScope.MerchandizeBean.treeModel}" id="tree" immediate="true" autoHeightRows="0"
styleClass="AFStretchWidth" rowSelection="multiple"
selectionListener="#{pageFlowScope.MerchandizeBean.treeNodeSelection}">
<f:facet name="nodeStamp">
<af:commandLink text="#{node.classDescription}"
actionListener="#{pageFlowScope.MerchandizeBean.createListManyItemForMerchandise}" id="displayTable" partialSubmit="true">
</af:commandLink>
</f:facet>
</af:tree>
public void treeNodeSelection(SelectionEvent selectionEvent) {
// Add event code here...
RichTree tree = (RichTree)selectionEvent.getSource();
TreeModel model = (TreeModel)tree.getValue();
//get selected value
Thanks
RoyHi,
in a multi select case, try
RowKeySet rks = tree.getSelectedRowKeys();
Iterator iter = rks.iterator();
while(iterator.hasNext()){
Object aKey = iterator.next();
tree. setRowKey(aKey);
Object rowData ? tree.getRowData();
.... do something with the data here ...
Frank
Maybe you are looking for
-
Installing Oracle 8.1.7 on RedHat 7.1 (kernel 2.4.5)
Hi: When I untar the gunzipped file and try to run the "runInstaller" program, the jre process eats up 99.6% of the CPU and does not start the installer. I have a gut feeling that it has something to do with IBM's JDK. Is there a way to use a differe
-
How can I scroll down with Mavericks OSX10.9.4? The right-hand scroll bar is missing.
-
Using IPOD nano with multiple PC - song no longer working
I have 2 nanos and 2 PCs. If IPOD 1 buys a song from PC 1 and then buys a song from PC 2, certain songs bought from PC 1 no longer play on NANO 1 --This happens on just one nano, not both. I can then go to PC 1 and drag the song onto Nano 1 again, th
-
Panasonic PV-GS250 used to work great with my MAC
In 2007 I purchased a a Panasonic Digital Camcorder (PV-GS250) and it worked like a dream with my Macbook Pro. Purchased an IMAC (Oct 07) with Leopard OS, the dream continued for both. I hadn't edited for a while and had a new project I was working o
-
How to automate dates in a Quest Powershell script?
Hi I have this script: Add-PSSnapin Quest.ActiveRoles.ADManagement Get-QADUser -SizeLimit 0 -CreatedAfter (Get-Date 12/12/2013) -CreatedBefore (Get-Date 13/12/2013) -IncludedProperties Name,WhenCreated,DisplayName,EMail,EmployeeID,StreetAddress,WebPa