Problem in populating a tree
Hi,
I am trying to populate a tree with the value from R3 backend. The tree has one root node and 3 child nodes under it. when i run this webdynpro application, i am getting the root node but the child nodes come as one entity i.e the values in the 3 child nodes comes directly under the root node instead of 3 seperate nodes.
can someone suggest what could be the cause of the problem.
Thanks and Regards,
Chander
Hi,
I have used Tree Node type to get the nodes.
The model that I use has the following structure:
There is a top node called <b>Ot_Publ_Details</b>. It has 3 child nodes <b>RepObjects, Subagenobjects and Subscrobjects</b>. These child objects internally has two attributes each.
The tree that i have created has Four Treenode types and 3 TreeItem types.
I have bound the data source of the tree node to Ot_Publ_Details. The first TreeNode is also bound to Ot_Publ_Details. The second tree node is bound to the RepObejcts, the third node to the Subagenobjects and the fourth node to Subscrobjects. The 3 treeitem types are mapped to the corresponding child attributes.
when i execute this application, I get a tree with the topnode taking the value from the first treenode while the other 3 nodes doesnt come as node. instead they come as leaf attributes and they display the values present in the attributes.
Hope the model structure and the UI structure is clear.
Regards,
Chander
Similar Messages
-
Problem in populating lookup values based on the lookup query from database
HI all
I have problem of population look-up values based on look-up query
I am giving the details what i am trying
I need to populate the values from the UD_LDAP_USR table into the field of UD_USRGRPC_NisNetTriple of type lookup
i planned to set the properties of lookup as like this
look up query as select UD_LDAP_USR_COMMON_NAME as NisNetTriple from UD_LDAP_USR
ColumnNames as UD_LDAP_USR_COMMON_NAME
Column captions as UD_LDAP_USR_COMMON_NAME
Column width as 30
Lookup Column Name as UD_LDAP_USR_COMMON_NAME
But when i try to add ColumnName as wht i mentioned above i m getting invalid property exception,update failed
I am not sure about that are we able to use other Connector table prefix with UD into the another processFrom
Let me give update on this issue
Urgent,struck my work here
thanks
NagarajThanks for the reply raghav
I tried but it was not working
I gave like what u specified but no use
It is throwing exception like set look-up query for the field
Any one help me out on this issue
Edited by: Nagaraju Chowdary on Jan 21, 2013 3:41 AM
Edited by: Nagaraju Chowdary on Jan 21, 2013 3:42 AM -
Problem of refreshing a tree in web dynpro java
hi all,
I'm facing a problem for refreshing a tree in web dynpro java for SAP HR.
I created a viewset with 2 cells( 1 view for each).
In the 1st view I created a droplistbyindex to select the unit ID and in the 2nd view ( defaut=false) I called a method to populate my tree according to my selection in the 1st view ( method called in wdInit).
When I make the first selection everything is ok.
But when I select another unit ID, the tree is not changed and I know the context is well changed according to my selection.
So I think the method is executed only the first the view is called.
In this case, how can I refresh my tree on real-time?
Thanks for your help
YiminMay be u can write the code wdDoModify instead.
-Ashutosh -
Problem Clearing a hierarchical tree
Is there a better way to clear a tree without deleting all the nodes. I want to clear the tree and not display anything.
If you have populated the tree manually, and the Record Group and Data Query columns are null, then you can use ftree.Populate_Tree to populate the tree with a null tree. This effectively clears it.
-
Problem pre-populating a combo box
Hello,
I am having problems pre-populating a combo box from a process.
This combo box field exists in the OIM User Form and in another process form.
Both combo box fields are populated from the same Lookup Definition: Lookup.Jazztel.TipoDeDocumento which looks like this:
Code Key Decode
1 DNI (NIF)
2 Pasaporte
4 Visado
6 Nº Identificación de Extranjero
9 C.I.F.
I've tried these methods to pre-populate the combo box:
* Using an adapter with a SET VARIABLE Logic Task (this adapter returns the code key that is selected in the OIM User form).
* Using an adapter that returns the decode field from the code key and pass it to the Process combo box.
In these cases, the process form combo box is not pre-populated correctly. It always shows C.I.F.
I tried modifying the combo box in the following way:
Code Key Decode
DNI (NIF) DNI (NIF)
Pasaporte Pasaporte
Visado Visado
Nº Identificación de Extranjero Nº Identificación de Extranjero
C.I.F. C.I.F.
and it get pre-populated correctly.
I need the code keys to be numbers. Does anyone know how can a combo like this be pre-populated?
Moreover and curiously, the process form combo box appears ordered alphabetically (according to the decode fields):
Code Key Decode
9 C.I.F.
1 DNI (NIF)
6 Nº Identificación de Extranjero
2 Pasaporte
4 Visado
and the OIM User Form Combo box, appears ordered numerically (according to the code key numerical order):
Code Key Decode
1 DNI (NIF)
2 Pasaporte
4 Visado
6 Nº Identificación de Extranjero
9 C.I.F.
Does anyone know why?
Thank you very muchTry prepopulate combobox by lookup code.
But it must displayed as decode. -
Problem while populating a field on process form- Values truncated
Hi,
I am facing a strange problem.
I have a requirement to populate Country field on AD process form based on the value of country code on the same process form which should eventually go to 'co' attribute in AD. So for eg. if the Country Code has value- 'US' then the Country field should be populated with 'United States'. This value is picked from lookup- Lookup.Locations.Country.
My adapter code works perfectly fine (checked using sysouts) it gets the proper values from the lookup but the country filed gets populated only with partial value. So instead of United States it only shows 'UNIT'. Same is for any country having more than 4 charatcters. It truncates the rest of the string and populates the field with only first 4 characters. I tried manually populating the Country field with complete country name on the process form and it works fine and the same value goes to AD also but when I run the adapter it only populates it with 4 charactetrs.
This is strange and I have no clue what could be stopping it. Any idea/experiences?
Thanks in advance,
-AbhiHi Abhi,
Can you tell me how you have implemented populating an UDF based on Prepopulation of another UDF. I have a similar kind of requirement. It would be great if you share your code or relevant part of it.
Regards,
Sunny Ajmera -
Problem when printing Alv Tree Report in back ground
Hi,
I am using SUBMIT ...TO SAP-SPOOL WITHOUT SPOOL DYNPRO with GET_PRINT_PARAMETERS FM.Its working fine.
My problem is that my SUBMIT report have TREE STRUCTURE as output so when i am running my program one blank screen is coming with heading DISPLAY LOG TREE because of TREE STRUCTURE.when i click on back button then only further processing happens.
How to avoid this TREE STRUCTURE SCREEN ???
Is there any other way to pass your list o/p to SPOOL other than .....TO SAP-SPOOL..?
Thanks in advance.in foreground when u run ALV report it holds maximum fields and displays in 1 single row, but the case is not in back ground...When any report is run in background, the default size for a line is 255 chars...So, if it more it gets splitted into 2 line item....This is how back ground job works for a report though it is a normal report or alv report.
-
Problem in populating field of same name in main & sub screen
Hi Guys,
I have a problem in my BDC program where the same field name appear in main screen and subscreen. Everytime i run the BDC program it will only populate to the field in main screen but not in the subscreen.
Below are the result of my BDC recording: Where PKHD-LGNUM, PKHD-LGTYP and PKHD-LGPLA exist in main screen 0110 and also sub screen.
SAPMMPKR 0110 X
BDC_OKCODE =SAVE
<b><i> PKHD-LGPLA KB
PKHD-LGNUM 100
PKHD-LGTYP 150</i></b>
PKHD-BEHAZ 10
PKHD-SIGAZ 8
PKHD-BEHMG 50
BDC_SUBSCR SAPMMPKR 0813INCLUDE8XX
PKHD-UMLGO S020
<b><i> PKHD-LGNUM 100
PKHD-LGTYP 150
PKHD-LGPLA KB</i></b>
BDC_SUBSCR SAPMMPKR 0820INCLUDE820
BDC_CURSOR PKHD-KOSTL
PKHD-KOSTL 8441
BDC_SUBSCR SAPMMPKR 0830INCLUDE830
This is the actual extract from SAP standard recording program, i even re-run the recording and it is not able to populate the value back into the subscreen fields of the same.
Any one encounter the same problem and solve it? please help me please.
Many thanks,
JayThe transaction i'm dealing with is PK01, control cycle creation. There is a screen where we specified the control cycle data and there is a subscreen to specify stock transfer location. Problem when both these main and subscreen have fields tied to the same name and structure.
If the screen fields name are the same, logically the BDC suppose to populate both field at the same time, however in my case the BDC only populate to the one in the main screen while the fields in subscreen are left empty. I have tried to specify the subscreen before populating the screen field, the value just won;t go in. I suspect it is still the problem in specifying the subscreen in populating the BDCDATA. I just dont know how, i have tried every possible way of specifying the subscreen. -
Problem in building swing tree
I am trying to build a tree with the values obtained from the database.
I have clearly explained the steps i have followed and the problem i am facing
Please look at the below code, where i have given step by step explanation
can any one help me i n solving my problem?
//global variables
String ioGlobalDesc = null;
TransferObject transObj = null;
ObjVO[] ioObjVO = null; //holds the values to build the intial tree
ObjVO[] ioObjExpTree;//hold the child value of the every expansion
pv.jfcx.PVNode root;
1) I have a root node PVNode which inturn extends DefaultMutableTreeNode
pv.jfcx.PVNode root;
2) createIntialTree()
This is the first method i call to obtain the values from the database .This method inturns
call the setRootNode method to build my initial tree where i am passing the root and the ioObjVO[] which has the
values obtained from the database
/******************createInitial Tree starts here****************************/
public void createIntialTree(TransferObject poTransferObject)
Hashtable output = poTransferObject.getResponseData();
ioObjVO = (ObjVO[]) output.get("ObjVO");
setRootNodes(root,ioObjVO);
3) After the setRootNode method is called from the createIntial tree,I am setting the values obtained
from the database to the root node.Here i am using my own class called MyNode which extends the PVNode,
This i am creating to set the desc and id for the particular node.
If you see the setRootNode method, I have created a node called ioCategory where i am setting the id and
description for the particular node. i have added ioCategory Node to the HashMap where desc is set as key and ioCategory itself is the value.
Now ioCategory node is added to the root node.
I am finiding the childcount for the obtained values from the database.while building the intial tree itself,if the child count is greater than zero,i am creating a subNode with empty values, this i am creating to denote that the particular node has the child.
i am adding the subNode to the ioCategory.
Now i am able to see the intial tree and also if node has childcount>0 then i am able to see the node handle.
Now if i click any of the node which has the childcount>0,it has take the particular node id and fetch the relavant child values
for the id i send,This is done when i expand my tree
Now i have expanded a node Which has childcount>0 and retrieved the values from the database
please see the treeExpand method,where the Expansion event is triggered and every expansion i am sending the
id to the database.
Here i have a global vairable called [ioGlobalDesc = e.getPath().getLastPathComponent().toString();]
where i am holding the current event triggered.
In the expandTree method , this is the method which is being called for every expansion i make ,
Here i will be gettig the values for the node expansion.Now i am setting this value to the
subnode where i am tryting identity the same parent to fix all the child to the same.
for this i have stored my current expansion path and made that as node so that i can fix my childvalues to
this.temp node should actually denote my ioCategory node for which i need to fix the child values.
MyNode temp =(MyNode) loHashMap.get(ioGlobalDesc);
I have another method called createnode to set my child values to the parentnode.Here i am passing the temp as the parameter
which holds the current parent for which i have to fix the values that i have already obtained in the
expandTree method.ioObjExpTree[] holds the childvalues for every expansion i make
My problem is, i am unable to find the same parent for which expansion is made and unable to fix the child nodes.Is there any way to do this?
How do i create both the parent and the child as a dynamic node?
ie is the way i proceeded is right or wrong???????????? i am totally confused.
can any one please help me in solving my problem??????????????
Tell me where i have misunderstood???????????????.or my approach itself is wrong in creating the dynamic tree??
if so how should i do it??????????????????????????????
/****************************setRootNodes start*******************************/
private void setRootNodes(pv.jfcx.PVNode root,ObjVO[] poObjVO) {
int loCount=1;
for (int i = 0; i < poObjVO.length; i++)
if (poObjVO.getInHierarchyLevel() > 0)
MyNode ioCategory = new MyNode(poObjVO[i].getIsHierarchyDesc(), poObjVO[i]. getIsObjID());
loHashMap.put(poObjVO[i].getIsHierarchyDesc(),ioCategory);
root.add(ioCategory);
if (ioObjVO[i].inChildrenCount > 0)
MyNode subNode = new MyNode("","");
ioCategory.add(subNode);
loCount++;
/****************************treeExpanded*************************************/
public void treeExpanded(TreeExpansionEvent e) {
AssMO loAssMO = new AssMO();
for (int i = 0; i < ioObjVO.length; i++)
if (ioObjVO[i].inChildrenCount > 0 && ioObjVO[i].getIsHierarchyDesc().equals(e.getPath().getLastPathComponent().toString()))
ioFirstHit++;
ioGlobalDesc = e.getPath().getLastPathComponent().toString();
e.getPath().getLastPathComponent().toString();
loAssMO.setPID(ioObjVO[i].getPID());
break;
if(ioGlobalDesc!=null)
// code goes here for sending the Id to the database which in turn calls my expandTree method which retrieves the
/************************************expandTree Ends here**********************/
public void expandTree(TransferObject poTransferObject) {
Hashtable output = poTransferObject.getResponseData();
ioObjVOExpTree = null;
ioObjVOExpTree = (ObjVO[]) output.get("ExpandTree");
MyNode temp =(MyNode) loHashMap.get(ioGlobalDesc);
ioUCSLogger.debug("<--END OF EXPAND tree method-->");
createNodes(temp);
/************************************expandTree Ends here**********************/
/****************************createNodes start*************************************/
private void createNodes(MyNode poParent) {
for(int x=0; x<ioObjVOExpTree.length; x++)
MyNode iosubNode = new MyNode(ioObjVOExpTree[x].getIsHierarchyDesc(),ioObjVOExpTree[x].getIsObjID());
loHashMap.put(ioObjVOExpTree[x].getIsHierarchyDesc(),iosubNode);
poParent.add(iosubNode);
iosubNode.setButton(1,false);Hi,
I have used Tree Node type to get the nodes.
The model that I use has the following structure:
There is a top node called <b>Ot_Publ_Details</b>. It has 3 child nodes <b>RepObjects, Subagenobjects and Subscrobjects</b>. These child objects internally has two attributes each.
The tree that i have created has Four Treenode types and 3 TreeItem types.
I have bound the data source of the tree node to Ot_Publ_Details. The first TreeNode is also bound to Ot_Publ_Details. The second tree node is bound to the RepObejcts, the third node to the Subagenobjects and the fourth node to Subscrobjects. The 3 treeitem types are mapped to the corresponding child attributes.
when i execute this application, I get a tree with the topnode taking the value from the first treenode while the other 3 nodes doesnt come as node. instead they come as leaf attributes and they display the values present in the attributes.
Hope the model structure and the UI structure is clear.
Regards,
Chander -
Problem in populating 2nd combo box depending upon the selection of 1st
Hi all,
I have 2 combo boxes on my jsp page ,say continent and country . obviously the data in 2nd box is dependant on selection made in the 1st . I'm using MySQL with tomcat 5.0.7 . and JSP.
The first combo box in one form and the 2nd in another. After submitting first i 'm populating the second combo also.
But the problem is after submitting the first form the page gets refreshing and i can't see the selected continent in the first combo box.
The javascript code used follows:
function callCapture(form)
var item = continent.cmbContinent.selectedIndex;
document.country.hidContId.value=continent.cmbContinent.options[item].value;
document.continent.action="country.jsp?hidContId="+document.country.hidContId.value+"&buttName="+document.country.buttName.value+"";
document.continent.target="_self";
document.continent.submit();
some one pls help me asap !Hi Reegz,
that's what i'm also doing and i'm successfull till populating the second combo box but how do I keep the previous inputs on the page and reload the page based on the change of a selection box?
Is their any mistake in the javascript code:
Here is the code:
function callCapture(form)
var item = continent.cmbContinent.selectedIndex;
document.country.hidContId.value=continent.cmbContinent.options[item].value;
document.continent.action="country.jsp?hidContId="+document.country.hidContId.value+"&buttName="+document.country.buttName.value+"";
document.continent.target="_self";
document.continent.submit();
Pls help me... -
Problem using a WebDynpro-tree in the Portal
Hi All,
I've created an Abap WebDynpro showing a recursive tree. The application works fine when I test it from the SAP server. But when I try implementing it in the portal (EP 6.0) via an IVIEW it won't run.
I don't get any type of error - the result just never appears on the page... It seems like the frame calls the WD in an endless loop or something, I can se the status line in the bottom of the browser is 'blinking' as if the page gets called over and over.
Any ideas ?
-Tonnihi Tonni,
by looking at the line" it seems like the frame calls the WD in an endless loop or something, I can se the status line in the bottom of the browser is 'blinking' as if the page gets called over and over. ", it seems that there is a problem with the recursive calls in your application.
please make sure that your applicaition is not getting into infinite loop.
regards,
Sujay
consider rewarding points if you find this useful -
Problem with populating setup tables for purchasing
I'm working on NW2004s.
Problem: Setup tables are not getting populated for 2lis_02_hdr, 2lis_02_item..
what all i've done so far:
1. Activated Data Sources in RSA5.
2. In LO Data Extraction, all the extract structure are active. (btw in job control i'm not sure what it does, i did make job parameter start date immediate, didnt set the print parms, schedule job gives an error.. anything here i may be messing it up?)
3. In SBIW initialization Deleted the contents of setup table and executed the 'Purchasing - perform setup'.
4. In NPRT i can see the log, the name of the source table EKKO, duration of run is 0.0 and no of docs 130.
5. In RSA3 for 2lis_02_hdr extraction process 0 records.
6. I look at SE11 for 'MC02M_0HDRSETUP' and table contents gives 0 records.
Any help is appreciated what i'm missing why the setup tables are not populating. I went thru the forum and did what was said but no sucess yet. I'm not an expert in SAP BW just been working for a year so pl dont be cryptic, explain u'r answers. Thanks for your time
MayilHi,
All the active datasources will be available in RSA6, after that go to LBWE ,maintain Ex Stru, Maintain DS and make that active, then we go for statistical setup
have you done these things?
Did you put any filters while filling up the setup tables?
what is the transaction you used for Setup.
cheers
RK -
Problem while populating table dynamically
Hi,
I am facing a strange problem when I execute a search component (custom developed component).
<b>Problem summary:</b>
I am getting first 5 empty rows (default visible row count, when I set the table's visible row count to "n" then the data in the first "n" rows are not visible) from the SAP R/3 when we fetch the data using this component. The data is available for the next consecutive rows starting 6th {(n+1)th} row. Here I am facing another strange behavior, I moved the table row position using the table paginator and viewing the data in the next consecutive rows and reset the view (invalidating the context and setting the visibility of the table to NONE), when I invoke the search again the data is missing in the 6-10 rows(the table data is paginated to the 6-10 records automatically), now the data is visible in the first 5 rows.
<b>The details of softwares:</b>
SAP WebAS 6.40 SP9
SAP NetWeaver Developer Studio Version: 2.0.9
JDK version - j2sdk1.4.2_06
<i>Note:</i>
1. The table creation and data population are done dynamically.
2. The same code works fine for SAP WebAS 6.40 SP8
3. When I tried fetching some data from SAP R/3 and displaying it in a table (table is created during design time and data population is achieved through standard context binding), it works fine.
If any of you get any clue in solving this issue, please do let me know.
Thanks in advance.
Thanks & Regards,
Santhosh.CHi Thomas,
I am running the application from the NDS and the URL look like the below URL
http://<<machine_name>>:50000/webdynpro/dispatcher/sap.com/parentgenericsearchhelpcomponent/PerentSearchDemo?SAPtestId=1
I am using IE6.0 SP2
Yes the application is working fine in SP8 and giving problem in SP9.
I have a parent component which calls another component(childcomponent), which has this dynamically populated table. I am using window.open() to open the window in the child component.
To answer your last question,
I don't see full of empty rows, I see empty rows for the first visble row counts(5 or 10, if the total fetched row count might atleast 1 more than the visble row count). The data is available from the first visible row count+1. If I come back and see the first vible row count, still the rows are blank.
Thanks & Regards,
Santhosh.C -
Problem with populating ROWSET
Hi ,
I have a problem with ROWSET.
I have a table with 6 columns and approximately more than 200 records.
I reterive them in a ResultSet and resultset gets populated.
But I populate Rowset with that ResultSet then it hangs for atleast 1 minuate and then it comes back to its original state.
Can anyone have thge idea why it happens....?
Is therer any issue with the Rowset ?
Why it takes too much time to populate the rowset..?
Thanks
TariqHere it is....
CachedRowSetImpl crs = new CachedRowSetImpl();
Statement stmt = con.createStatement(ResultSet.TYPE_SCROLL_SENSITIVE, ResultSet.CONCUR_READ_ONLY);
ResultSet result = stmt.executeQuery(sql); // Here we have 250 records in ResultSet
crs.populate(result); // This is the problem. This line takes atleast 1min to executeAny solution u gurus have .... -
Populating a Tree data provider dynamically
Hi,
I have made an XMLLIstCollection as the data provider of a
Tree control. I want to add the tree nodes dynamically. Now the
problem is that I am able to add a node to the collection but not a
sub-node. Can anybody plz tell me the way to do it?
Thanks,
ChereeI tried with your code the following mxml program:
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="
http://www.adobe.com/2006/mxml"
creationComplete="initApp()">
<mx:Script>
<![CDATA[
import mx.collections.XMLListCollection;
[Bindable]
public var a:XMLList=new XMLList();
[Bindable]
public var xml:XML;
[Bindable]
public var coll:XMLListCollection=new XMLListCollection(a);
public var xmlIn:String = "<node label='new'/>";
public var xmlNode:XML=new XML(xmlIn);
public function initApp():void{
xml= <node label="sdf" isBranch="true"/>;
coll.addItem(xml);
xml=<node label="sdf">{xml}</node>;
coll.addItem(xml);
xml=<node label="goi">{a}</node>;
//xml.node[0].subnode[0].appendChild(xmlNode);
coll.addItemAt(xml,0);
]]>
</mx:Script>
<mx:Tree id="myTree" dataProvider="{coll}"
labelField="@label"/>
</mx:Application>
If I uncomment the line that you suggested, I get the error :
TypeError: Error #1010: A term is undefined and has no
properties.
at TestFile2/initApp()
at TestFile2/___Application1_creationComplete()
at
flash.events::EventDispatcher/flash.events:EventDispatcher::dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at mx.core::UIComponent/set initialized()
at mx.managers::LayoutManager/::doPhasedInstantiation()
at Function/
http://adobe.com/AS3/2006/builtin::apply()
at mx.core::UIComponent/::callLaterDispatcher2()
at mx.core::UIComponent/::callLaterDispatcher()
Maybe you are looking for
-
Hi, I am doing re-development,while doing data loading I am getting some fields value truncated but as i had checked the transfer rule and update rules are all mapped correct and the field lengh is also correct . Like our Company Code is 1000 and in
-
Material Transaction and Move Transaction Managers are Going Inactive
hi it was running previously but currently it becomes inactive.can any one tell in which table to look for the error related to this problem? Kind Regards Sayantan
-
Aaack. Adding a PC to my Happy Mac Family, adding a router?
Okay, I have 3 Macs connected to a DSL modem via Airport Express, WEP encrypted network. Two Macs run 10.4.8, one runs 10.2.8, all have Airport cards. Hubby's new job comes with an IBM Thinkpad running latest version of Windows. New Co. insists he us
-
Cisco ACS 4.2.1.15 for Windows and Network Access Profiles
We are attempting to configure ACS 4.2.1.15 on Windows Server 2008 Member Server. Initially I only have the need to authenticate Network Admins for device administration and authenticate Windows AD groups using PEAP authentication. The general proble
-
Query on BDT: Business Data toolset
Hi, I wanted to know, how to determine that a particular transaction is BDT(business data toolset) enabled? Or Let me know the list of transactions for which i can enhance/modify using the concept of BDT. Regards Shiva