Column store errors during runtime
Hi,
I created a HANA instance in the trial landscape and directed my application to use the HANA instance schema. Over time, I get errors:
SAP DBTech JDBC: [2048]: column store error: search table error: [29] attribute not defined for physical index;internal error: attribute 'NEO_29J91OPIP2IAEWXFUZRHT093R:CA_EV_VENUEen/PK_EVENT_VENUE_ID' not found in indexInfoMap
I'm using the HANA instance instead of the default schema created from the application because I need to run spatial queries, which is currently only available in the HANA instance.
Does anyone know what's wrong?
Additional errors from the HCP logs:
javax.persistence.PersistenceException: Exception [EclipseLink-4002] (Eclipse Persistence Services - 2.5.0.v20130507-3faac2b): org.eclipse.persistence.exceptions.DatabaseException
Internal Exception: com.sap.db.jdbc.exceptions.JDBCDriverException: SAP DBTech JDBC: [2048]: column store error: search table error: [10000008] exception 10000008:
ims_search_api/Delta/impl/DeserializerContext.cpp:2099
Failed to write data into NEO_95BOXA4K094KH5V4JNKE5KDPZ:CA_EV_VENUE$delta_1$en: Attribute engine failed(6900); $function$=writeDataIntoDelta
Error Code: 2048
Call: SELECT PK_EVENT_VENUE_ID, ADDRESS, DESCRIPTION, EMAIL, EXTERNAL_ID, FAX, LATITUDE, LONGITUDE, NAME, PHONE, WEBSITE, FK_EVENT_DATA_PROVIDER_ID FROM CA_EV_VENUE WHERE ((FK_EVENT_DATA_PROVIDER_ID = ?) AND (EXTERNAL_ID = ?))
bind => [2 parameters bound]
Query: ReadAllQuery(name="EventVenue.findByProvider" referenceClass=EventVenue sql="SELECT PK_EVENT_VENUE_ID, ADDRESS, DESCRIPTION, EMAIL, EXTERNAL_ID, FAX, LATITUDE, LONGITUDE, NAME, PHONE, WEBSITE, FK_EVENT_DATA_PROVIDER_ID FROM CA_EV_VENUE WHERE ((FK_EVENT_DATA_PROVIDER_ID = ?) AND (EXTERNAL_ID = ?))")
The table CA_EV_VENUE contains spatial column and only this table is "failing". Other tables doesn't contain spatial columns are fine.
I'm trying to get HANA DB traces from the HCP team and was wondering which traces will be helpful for the HANA team.
Similar Messages
-
SAP HANA XSODATA service (Service exception: column store error.)
Hi all,
i have a problem with my calculation view using xsodata service on it. (There's an input parameter called P
_SWERK)
In my calculation view, the data origin are two analytic views (on which the input parameter P_SWERK should be filter data at beginning of the sql script code).
First i read the analytic views with function CE_OLAP_VIEW and after i do a CE_PROJECTION function on them using the input parameter P_SWERK like a filter on field SWERK.
But when i run my application on browser the following error occurs :
<message xml:lang="en-US">Service exception: column store error.</message>
The link is this :
http://host:port/Project_DM/services/Test/TEST_ZIIG_PDM_CALC_VIEW_FINAL_service.xsodata/PianiDiManutenzioneParameters(P_SWERK='CO05')/Results
The service definition is :
service {
"EricssonItalgas/TEST_ZIIG_PDM_VIEW_FINAL.calculationview" as "PianiDiManutenzione" keys generate local "ID"
parameters via entity;
The SAP HANA AWS revision is 60.
Someone could you help me,please?
Thanks in advance.
Dario.Hi Dario,
Does the calculation view work without xsodata service? From the URL, your XS project name should be Project_DM, but from the xsodata source, the project name is EricssonItalgas. I'm confused with this. Did you use rewrite_rules or?
Best regards,
Wenjun -
Hi All,
I get the below error when i load my xsjs file in browser,
Error while executing query: [dberror(PreparedStatement.executeQuery): 2048 - column store error: column store error: [2950] user is not authorized : at ptime/session/dist/RemoteQueryExecution.cc:1354]
I am able to execute the same query in HANA SQL editor
Please note that ,No Analytical privileges are applied to the view.
Could you please help solving this issue.
Regards,
Logesh Kumar.Hay,
are you using the same Database user for both SQL Editor and XSJS ?
try the following.
Before executing the query , display it and copy the same from browser and execute in SQL editor.
Put the statement in a try catch block and analyse the exception .
Sreehari -
Hi Experts,
We got a problem here.
We have a query ran without any problems in RSRT. But when I try to put it as data sources(infoprovider) in APD.
I got following error:
column store error: fail to create scenario: [340 2048
We are in BW731006 & ABAP731006.
Any advise?
Thanks in advance!
TengranHi,
Can you check this part in error mentioned by clicking as highlighted in red box. It will give you a correct idea about the issue ::
Also share the detailed error with us as well.
Best Regards,
Arpit -
Error during Runtime: Mapping : RESOURCE_NOT_FOUND
<b>Hello everybody,
I get the following error during runtime while mapping:</b>
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
- <!-- Mapping der Request-Message
-->
- <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="">
<SAP:Category>Application</SAP:Category>
<SAP:Code area="MAPPING"><u><b>RESOURCE_NOT_FOUND</b></u></SAP:Code>
<SAP:P1>com/sap/xi/tf/_MM_FILE_REQUEST_2_RESPONSE_.class</SAP:P1>
<SAP:P2>http://mm_file_2_file</SAP:P2>
<SAP:P3>7c57acd0-19fa-11da-a907-fba1c22dd3ca</SAP:P3>
<SAP:P4>-1</SAP:P4>
<SAP:AdditionalText />
<SAP:ApplicationFaultMessage namespace="" />
<SAP:Stack>The Resource com/sap/xi/tf/_MM_FILE_REQUEST_2_RESPONSE_.class (http://mm_file_2_file, 7c57acd0-19fa-11da-a907-fba1c22dd3ca, -1) could not be found.</SAP:Stack>
<SAP:Retry>M</SAP:Retry>
</SAP:Error>
<b>Does anybody have an idea?
Thanks a lot
regards Mario</b>Could the reason be a wrong "file content convert"?
The payload:
<?xml version="1.0" encoding="utf-8" ?>
<ns:TEST.TXT xmlns:ns="http://mm_file_2_file">
<Record>
<Row>
<FirstName>Mario</FirstName>
<LastName>Mueller</LastName>
<City>Mannheim</City>
<Country>Deutschland</Country>
</Row>
</Record>
</ns:TEST.TXT>
Structure of corresponding Data-Type
Record 1..unbounded
Row 1
FirstName 1
LastName 1
City 1
Country 1
Regards Mario -
Hi,
I have scenario like JDBC sender and file receiver.
I am able to poll with JDBC sender adapter and message has success in adapter engine.
but i am getting following error while mapping runtime.In sxmb_moni status error during mapping runtime.
Below i am giving the trace file:
<Trace level="1" type="T">Interface Mapping urn:iwaysoftware:adapter:iworacle:tablerequest jdbc_im</Trace>
<Trace level="1" type="T">RuntimeException during appliction Java mapping com/sap/xi/tf/_jdbc_mp_</Trace>
<Trace level="1" type="T">com.sap.aii.utilxi.misc.api.BaseRuntimeException: RuntimeException in Message-Mapping transformation: Cannot produce target element /ns0:PO_HEADER/PO_HEADERS_INTERFACE/INTERFACE_HEADER_ID. Check xml instance is valid for source xsd and target-field mapping fulfills requirements of target xsd at com.sap.aii.mappingtool.tf3.AMappingProgram.start(AMappingProgram.java:303) at com.sap.aii.mappingtool.tf3.Transformer.start(Transformer.java:63) at com.sap.aii.mappingtool.tf3.AMappingProgram.execute(AMappingProgram.java:77) at com.sap.aii.ibrun.server.mapping.JavaMapping.executeStep(JavaMapping.java:64) at com.sap.aii.ibrun.server.mapping.Mapping.execute(Mapping.java:91) at com.sap.aii.ibrun.server.mapping.MappingHandler.run(MappingHandler.java:90) at com.sap.aii.ibrun.sbeans.mapping.MappingRequestHandler.handleMappingRequest(MappingRequestHandler.java:94) at com.sap.aii.ibrun.sbeans.mapping.MappingRequestHandler.handleRequest(MappingRequestHandler.java:67) at com.sap.aii.ibrun.sbeans.mapping.MappingServiceImpl.processFunction(MappingServiceImpl.java:79) at com.sap.aii.ibrun.sbeans.mapping.MappingServiceObjectImpl0.processFunction(MappingServiceObjectImpl0.java:131) at sun.reflect.GeneratedMethodAccessor414.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at com.sap.engine.services.ejb.session.stateless_sp5.ObjectStubProxyImpl.invoke(ObjectStubProxyImpl.java:187) at $Proxy153.processFunction(Unknown Source) at sun.reflect.GeneratedMethodAccessor413.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.call(RFCDefaultRequestHandler.java:219) at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.handleRequest(RFCDefaultRequestHandler.java:169) at com.sap.engine.services.rfcengine.RFCJCOServer.handleRequest(RFCJCOServer.java:156) at com.sap.mw.jco.JCO$Server.dispatchRequest(JCO.java:7650) at com.sap.mw.jco.MiddlewareJRfc$Server.dispatchRequest(MiddlewareJRfc.java:2275) at com.sap.mw.jco.MiddlewareJRfc$Server.listen(MiddlewareJRfc.java:1614) at com.sap.mw.jco.JCO$Server.listen(JCO.java:8009) at com.sap.mw.jco.JCO$Server.work(JCO.java:8129) at com.sap.mw.jco.JCO$Server.loop(JCO.java:8076) at com.sap.mw.jco.JCO$Server.run(JCO.java:7992) at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37) at java.security.AccessController.doPrivileged(Native Method) at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100) at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170) Root Cause: com.sap.aii.mappingtool.tf3.IllegalInstanceException: Cannot produce target element /ns0:PO_HEADER/PO_HEADERS_INTERFACE/INTERFACE_HEADER_ID. Check xml instance is valid for source xsd and target-field mapping fulfills requirements of target xsd at com.sap.aii.mappingtool.tf3.AMappingProgram.processNode(AMappingProgram.java:178) at com.sap.aii.mappingtool.tf3.AMappingProgram.processNode(AMappingProgram.java:204) at com.sap.aii.mappingtool.tf3.AMappingProgram.processNode(AMappingProgram.java:204) at com.sap.aii.mappingtool.tf3.AMappingProgram.start(AMappingProgram.java:298) at com.sap.aii.mappingtool.tf3.Transformer.start(Transformer.java:63) at com.sap.aii.mappingtool.tf3.AMappingProgram.execute(AMappingProgram.java:77) at com.sap.aii.ibrun.server.mapping.JavaMapping.executeStep(JavaMapping.java:64) at com.sap.aii.ibrun.server.mapping.Mapping.execute(Mapping.java:91) at com.sap.aii.ibrun.server.mapping.MappingHandler.run(MappingHandler.java:90) at com.sap.aii.ibrun.sbeans.mapping.MappingRequestHandler.handleMappingRequest(MappingRequestHandler.java:94) at com.sap.aii.ibrun.sbeans.mapping.MappingRequestHandler.handleRequest(MappingRequestHandler.java:67) at com.sap.aii.ibrun.sbeans.mapping.MappingServiceImpl.processFunction(MappingServiceImpl.java:79) at com.sap.aii.ibrun.sbeans.mapping.MappingServiceObjectImpl0.processFunction(MappingServiceObjectImpl0.java:131) at sun.reflect.GeneratedMethodAccessor414.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at com.sap.engine.services.ejb.session.stateless_sp5.ObjectStubProxyImpl.invoke(ObjectStubProxyImpl.java:187) at $Proxy153.processFunction(Unknown Source) at sun.reflect.GeneratedMethodAccessor413.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.call(RFCDefaultRequestHandler.java:219) at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.handleRequest(RFCDefaultRequestHandler.java:169) at com.sap.engine.services.rfcengine.RFCJCOServer.handleRequest(RFCJCOServer.java:156) at com.sap.mw.jco.JCO$Server.dispatchRequest(JCO.java:7650) at com.sap.mw.jco.MiddlewareJRfc$Server.dispatchRequest(MiddlewareJRfc.java:2275) at com.sap.mw.jco.MiddlewareJRfc$Server.listen(MiddlewareJRfc.java:1614) at com.sap.mw.jco.JCO$Server.listen(JCO.java:8009) at com.sap.mw.jco.JCO$Server.work(JCO.java:8129) at com.sap.mw.jco.JCO$Server.loop(JCO.java:8076) at com.sap.mw.jco.JCO$Server.run(JCO.java:7992) at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37) at java.security.AccessController.doPrivileged(Native Method) at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100) at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)</Trace>
I tried with all options using mapping functions.But the same eror is coming.
When i tested my mapping program its successfully running in map bulider without any errors.
The error occuring at runtime.
Source strcture :
<?xml version="1.0" encoding="UTF-8"?>
<ns0:resultset xmlns:ns0="urn:iwaysoftware:adapter:iworacle:tablerequest">
<row>
<interface_header_id>928822</interface_header_id>
</row>
</ns0:resultset>
Target structure:
<?xml version="1.0" encoding="UTF-8"?>
<ns0:PO_HEADER xmlns:ns0="urn:iwaysoftware:adapter:iworacle:tablerequest"><PO_HEADERS_INTERFACE><INTERFACE_HEADER_ID>928822</INTERFACE_HEADER_ID></PO_HEADERS_INTERFACE></ns0:PO_HEADER>
Can any body suggest what causing the problem.
Regards
UsmanHi Usman,
Test your mapping in IR with the payload from SXMB_MONI. You can refer michal's weblog on <a href="/people/michal.krawczyk2/blog/2005/09/16/xi-how-to-test-your-mapping-in-real-life-scenarios to test your mapping (in real life scenarios)</a>
In other words you copy the XML message from monitoring and exectute the mapping in Integration Builder with maximal trace to get the reason.
So what you can do is check ur runtime payload in sxmb_moni with,
IR>message mapping>test tab>give values>test-->source xml
Also i thought i will give you some details on what ur doing, so maybe you can compare it with what uhave done and see where you have gone wrong.
A JDBC sender adapter has 2 essential fields,
1. SQL Statement
2. Update Statement
Your SQL statement will contain your SELECT statement and once your SQL statement is executed, UPDATE statement is executed. This is done so that records that have been selected by the SQL statement should not be selected again as the JDBC sender adapter will poll over the database for every poll interval.
If you want to SELECT something from your Database, then you will have to go for a JDBC sender adapter.
This is how a SENDER JDBC Adapter works,
When you are using your JDBC as a sender, then your JDBC will poll over your database and select the rows that satisfy your Select Query.
In your case, as you are dealing with multiple tables, you can write a stored proceudre for your Database, and call this stored procedure in your Sender JDBC adapter in the SELECT field of your JDBC adapter.
Go through this blog for stored procedures.
/people/sriram.vasudevan3/blog/2005/02/14/calling-stored-procs-in-maxdb-using-sap-xi
For Configuring the Sender JDBC Adapter refer go through <a href="http://help.sap.com/saphelp_nw04/helpdata/en/7e/5df96381ec72468a00815dd80f8b63/content.htm">Configuring the Sender JDBC Adapter</a>
Also go through this blog and see if it helps you.
/people/prasadbabu.nemalikanti3/blog/2006/02/27/collecting-and-bundling-vendor-records-from-different-multiple-interfaces-file-systempeoplesoft-and-sending-to-sap-r3-system-part-2
To access any Database from XI, you will have to install the corresponding Driver on your XI server.
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/3867a582-0401-0010-6cbf-9644e49f1a10
I hope this helps...
Regards,
Abhy
Message was edited by: Abhy Thomas -
ABAP Proxy error during runtime but success for manuall test ?
Hi,
I got scenario using inbound ABAP proxy. The problem is when i test the inbound proxy manually, it was sucessfully, but then if i run directly from sender got problem :
Error during proxy processing An exception with the type CX_SY_DYN_CALL_ILLEGAL_TYPE occurred, but was neither handled locally, nor declared in a RAISING clause The function call of ZPSCD_CTRACCOMOBJECT_CREA failed; a field may have been assigned to the parameter ZCOM_COMPDHDR whose type is not compatible with this parameter
Please help
RegardsFernand,
As stated in the exception, there is a compatibility issue between source and target fields, but without further details (msg definitions etc), we can't tell you exactly what's wrong ...
What's the ABAP type of ZCOM_COMPDHDR field in your RFC function module ?
Rgds
Chris
PS : also check the msg content to make sure generated field is compatible with the expected type (manual test was successful because you set it to the suitable value, whereas in "real" situation there is discrepancy)
Edited by: Christophe PFERTZEL on Apr 28, 2008 1:22 PM -
SQL Expressions in RAD -Getting error during runtime while generating rpt
Hi
We have just migrated from WSAD to RAD Version: 7.0.0.7.
The issue is: I am getting the error at the runtime when I am trying to use the SQL expression in my one of the report. The SQL Expression feature is not supported by this version of RAD. I checked the Help contents. It says
Field Objects: SQL expression fields
This report contains SQL Expression fields. These fields are not visible in this version of the Crystal Reports designer, but they will be evaluated by the system when the report is executed. New SQL Expression fields cannot be created by the designer. SQL Expression fields will remain in the .rpt file after saving and can be edited by other Crystal Reports designers
To me it seems you can use the 'SQL Expressions' in the report using some Crystal Reports designers and at the runtime it will be evaluated. So I edited my report with some Crystal Reports Designer and tested it on WSAD. It worked fine. Now since we have migrated to RAD, this is an issue since I am getting the following error:
ERROR [WebContainer : 0] com.crystaldecisions.reports.formatter.formatter.objectformatter - com.crystaldecisions.reports.dataengine.be: Failed to parse expression.
[12/17/08 15:12:14:750 EST] 0000001c SystemOut O 15:12:14,671 ERROR [WebContainer : 0] com.businessobjects.reports.sdk.JRCCommunicationAdapter - Failed to export report
com.crystaldecisions.reports.exportinterface.exceptions.ExportException: Failed to parse expression.
at com.crystaldecisions.reports.formatter.a.c.if(Unknown Source)
at com.crystaldecisions.reports.formatter.a.c.a(Unknown Source)
at com.businessobjects.reports.sdk.b.b.int(Unknown Source)
at com.businessobjects.reports.sdk.JRCCommunicationAdapter.request(Unknown Source)
at com.crystaldecisions.proxy.remoteagent.x.a(Unknown Source)
at com.crystaldecisions.proxy.remoteagent.q.a(Unknown Source)
at com.crystaldecisions.sdk.occa.report.application.dd.a(Unknown Source)
When I remove the expression fields, it works fine on RAD too.
I am using following versions:
RAD Version: 7.0.0.7
Crystal Reports for Rational Application Developer Version: 11.5.6.v20080304.
Crystal Report Runtime Support version is 11.8.4.v1094
Please let me know if somebody has faced the similar issue.
Any help/suggestions would be appreciated.
Thanks,
KamalHi
We have just migrated from WSAD to RAD Version: 7.0.0.7.
The issue is: I am getting the error at the runtime when I am trying to use the SQL expression in my one of the report. The SQL Expression feature is not supported by this version of RAD. I checked the Help contents. It says
Field Objects: SQL expression fields
This report contains SQL Expression fields. These fields are not visible in this version of the Crystal Reports designer, but they will be evaluated by the system when the report is executed. New SQL Expression fields cannot be created by the designer. SQL Expression fields will remain in the .rpt file after saving and can be edited by other Crystal Reports designers
To me it seems you can use the 'SQL Expressions' in the report using some Crystal Reports designers and at the runtime it will be evaluated. So I edited my report with some Crystal Reports Designer and tested it on WSAD. It worked fine. Now since we have migrated to RAD, this is an issue since I am getting the following error:
ERROR [WebContainer : 0] com.crystaldecisions.reports.formatter.formatter.objectformatter - com.crystaldecisions.reports.dataengine.be: Failed to parse expression.
[12/17/08 15:12:14:750 EST] 0000001c SystemOut O 15:12:14,671 ERROR [WebContainer : 0] com.businessobjects.reports.sdk.JRCCommunicationAdapter - Failed to export report
com.crystaldecisions.reports.exportinterface.exceptions.ExportException: Failed to parse expression.
at com.crystaldecisions.reports.formatter.a.c.if(Unknown Source)
at com.crystaldecisions.reports.formatter.a.c.a(Unknown Source)
at com.businessobjects.reports.sdk.b.b.int(Unknown Source)
at com.businessobjects.reports.sdk.JRCCommunicationAdapter.request(Unknown Source)
at com.crystaldecisions.proxy.remoteagent.x.a(Unknown Source)
at com.crystaldecisions.proxy.remoteagent.q.a(Unknown Source)
at com.crystaldecisions.sdk.occa.report.application.dd.a(Unknown Source)
When I remove the expression fields, it works fine on RAD too.
I am using following versions:
RAD Version: 7.0.0.7
Crystal Reports for Rational Application Developer Version: 11.5.6.v20080304.
Crystal Report Runtime Support version is 11.8.4.v1094
Please let me know if somebody has faced the similar issue.
Any help/suggestions would be appreciated.
Thanks,
Kamal -
Error during runtime when using BULK collect
Hi
CREATE OR REPLACE TYPE VAR_ROW AS OBJECT
VAR_1 VARCHAR2(20),
VAR_2 VARCHAR2(20)
CREATE OR REPLACE TYPE V_TAB AS table of VAR_ROW
CREATE OR REPLACE FUNCTION get_id RETURN var_tbl
PIPELINED AS
/* declaration */
i INTEGER;
--TYPE x_t IS TABLE OF VAR_ROW;
x_t V_TAB;
c_wip sys_refCursor;
BEGIN
c_wip := getTable('abc'); --the result return: 10 rows with 2 columns.
LOOP
FETCH c_wip BULK COLLECT
INTO x_t LIMIT 20; <-- error seems to come from this line
FOR i IN x_t.FIRST .. x_t.LAST LOOP
PIPE ROW(x_t(i).VAR_1);
--PIPE ROW(x(i).VAR_1);
END LOOP;
exit when c_wip%NOTFOUND;
end loop;
RETURN;
END;
SELECT *
FROM TABLE(get_id)
Error msg: ORA-00932:inconsistent datatypes:expected UDT got CHARWhat could be the cause of the error?In addition, if your cursor returns two separate columns, you'll have to call an appropriate object constructor to create a VAR_ROW object from the two columns. The easiest solution would be to do this in your getTable method. Where you have
SELECT column1, column2in getTable today, you'd want
SELECT var_row( column1, column2 )Otherwise, Oracle cannot construct the VAR_ROW object from the cursor, so you cannot bulk collect it into an array of VAR_ROW.
Justin
Distributed Database Consulting, Inc.
http://www.ddbcinc.com/askDDBC -
In Flash Builder 4.6 I get an error for this:
var testVector:Vector.<*> = new Vector.<*>();
trace(testVector.length);
Sometimes the error shows up in the "Problems" panel and pointing at the trace it says something about byte code. Other times it just shows the "?" symbol next to the trace command that says "Access of undefined property length".
When I test the movie there are no runtime errors.
Can someone explain this?
cheers.OK, I take that back, I read up on the docs and see that Math.random() returns 0 <= n < 1 where I thought it was <=1.
I also ran a test bed on the Math.random() thing and I see what your man means. My method of calculating the index gave a slight imbalance towards the end of letter distributions, but I can't see why!
Have reverted to yours for the below, on first run it looked good, but I am seeing a cluster around the original letter position? (EG: Follow position 0 for a, position 1 for b etc. and you will see they have a disproportionate number there.)
G
[code]
protected function doTheTest():void {
var iterations:uint = 100000;
var index:Dictionary = new Dictionary;
var i:int = 0;
var letter:String;
var pos:int;
var currentLetterIndex:Vector.<uint>;
var toSort:Vector.<String>;
var testSource:Vector.<String> = Vector.<String>(["a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r", "s","t","u","v","w","x","y","z"]);
testSource.fixed = true;
var posIndex:Vector.<uint> = new Vector.<uint>;
posIndex.length = testSource.length;
posIndex.fixed = true;
// Build the index using a copy of the posIndex input.
for(i=0;i<testSource.length;i++) index[testSource[i]] = posIndex.concat();
// TEST USING JUST RANDOM
for(i=0;i<iterations;i++) {
// Use a concat to prevent sort changing inputs
toSort = testSource.concat();
toSort = toSort.sort(function (a:*,b:*):int { return Math.random()>0.5?1:-1; });
for(pos=0;pos<toSort.length;pos++) {
letter = toSort[pos];
currentLetterIndex = index[letter] as Vector.<uint>;
currentLetterIndex[pos]++;
trace("@@@@@ USING RANDOM @@@@");
for(i=0;i<testSource.length;i++) {
letter = testSource[i];
currentLetterIndex = index[letter] as Vector.<uint>;
trace("POSITION COUNT OF "+letter+" is:"+index[letter].join(","));
// Test using function
for(i=0;i<iterations;i++) {
// Use a concat to prevent sort changing inputs
toSort = testSource.concat();
randomSortArrayOrVector(toSort);
for(pos=0;pos<toSort.length;pos++) {
letter = toSort[pos];
currentLetterIndex = index[letter] as Vector.<uint>;
currentLetterIndex[pos]++;
trace("@@@@@ USING SORT FUNCTION @@@@");
for(i=0;i<testSource.length;i++) {
letter = testSource[i];
currentLetterIndex = index[letter] as Vector.<uint>;
trace("POSITION COUNT OF "+letter+" is:"+index[letter].join(","));
protected static function randomSortArrayOrVector(a:Object):void {
if(a.hasOwnProperty('length')) {
var l:int = a['length'];
for (var i:int = l-1; i >=0; i--)
var randomIndex:int = Math.floor(Math.random()*(i+1));
var itemAtIndex:Object = a[randomIndex];
a[randomIndex] = a[i];
a[i] = itemAtIndex;
[/code]
@@@@@ USING RANDOM @@@@
POSITION COUNT OF a is:3150,3207,3010,2741,2653,3063,4174,2606,2674,2991,3172,3889,4872,18865,3851,3356,3219, 2971,2732,3930,3319,2814,2944,3058,3222,3517
POSITION COUNT OF b is:6815,7482,2634,2925,3023,2921,3107,3416,3459,3508,3444,3387,3212,3170,3331,3439,3444,3 375,3312,3158,3180,3339,3776,4356,5441,7346
POSITION COUNT OF c is:6149,5382,8320,2133,2209,2931,3224,3274,3427,3438,3290,3114,2888,2859,2997,3180,3431,3 493,3551,3416,3732,3906,4336,4864,5206,5250
POSITION COUNT OF d is:4516,4382,4620,9761,2966,2096,2555,3285,3365,3274,3083,2785,2603,2759,2730,3145,3469,3 706,3752,3890,4169,4343,4888,4868,4797,4193
POSITION COUNT OF e is:3418,3385,4878,4681,11058,3387,2456,2421,2769,3163,2892,2596,2457,2390,2622,2934,3392, 3813,4177,4334,4471,4700,4857,4672,4364,3713
POSITION COUNT OF f is:3178,3193,4506,4454,5179,11514,3753,2834,2303,2027,2308,2454,2275,2290,2466,2960,3444, 3941,4292,4489,4647,4824,4686,4498,4058,3427
POSITION COUNT OF g is:3035,3073,3577,4665,4627,5549,11737,4087,3112,2132,1750,1557,1789,2331,2568,2930,3469, 3979,4324,4564,4606,4686,4468,4278,3757,3350
POSITION COUNT OF h is:3194,3121,3219,4018,3595,4356,5302,12154,3533,3078,2513,2009,1867,1874,2414,2967,3466, 4079,4251,4441,4409,4535,4436,3912,3792,3465
POSITION COUNT OF i is:3460,3486,3287,3430,3748,3089,3875,4449,12535,3322,2844,2694,2401,2421,2671,2886,3405, 3980,4252,4225,4137,4181,4016,3803,3734,3669
POSITION COUNT OF j is:3757,3675,3415,3147,4020,2644,2855,3510,4389,13514,3192,2865,2896,2833,2905,3039,3367, 3740,4102,3909,3678,3859,3672,3624,3666,3727
POSITION COUNT OF k is:3634,3707,3409,3020,3141,3712,2390,2780,3514,4322,15026,3388,3034,3047,3165,3287,3290, 3432,4098,3759,3514,3279,3497,3508,3484,3563
POSITION COUNT OF l is:3564,3493,3382,2775,2990,4085,2299,2409,2970,3430,4434,17142,3665,3362,3419,3301,3245, 3115,3767,3581,3318,3031,3144,3187,3385,3507
POSITION COUNT OF m is:3213,3343,3112,2871,2789,3128,3887,2504,2607,3228,3750,4587,18391,3865,3430,3379,3078, 3046,2858,4219,3164,2925,2877,3176,3151,3422
POSITION COUNT OF n is:73,81,150,308,571,1106,2135,3639,6189,9115,11788,13690,14242,12757,9894,6957,4005,2012 ,880,292,98,14,4,0,0,0
POSITION COUNT OF o is:3096,3174,2864,2839,2678,2966,3400,3826,2849,2956,3121,3355,4061,5195,18308,3599,3090, 2907,2645,2548,4380,3016,2836,3255,3371,3665
POSITION COUNT OF p is:3396,3317,3083,3026,2878,3017,3400,4197,3156,3107,3039,3140,3521,4147,5073,16486,3221, 2919,2523,2535,3989,3072,3056,3430,3474,3798
POSITION COUNT OF q is:3650,3640,3377,3409,3183,3283,3465,3721,3714,3292,3057,2977,2999,3334,3963,4776,15045, 2912,2596,2421,2562,4140,3361,3570,3714,3839
POSITION COUNT OF r is:3639,3711,3590,3727,3646,3596,3739,3887,3812,3216,3058,2854,2705,2849,3179,3988,4711,1 3457,2936,2571,2689,3802,3523,3555,3687,3873
POSITION COUNT OF s is:3769,3828,3832,4172,4138,3880,4010,3987,3798,3504,2908,2438,2318,2291,2679,3553,4241,5 000,12631,3288,2755,2763,3986,3206,3509,3516
POSITION COUNT OF t is:3692,3761,4099,4493,4484,4423,4251,4218,3815,3462,2883,2494,2145,1895,2182,2630,3651,4 920,5611,11928,3719,2874,3380,2906,3053,3031
POSITION COUNT OF u is:3786,3809,4243,4633,4804,4607,4425,4106,3902,3223,2869,2511,2216,2122,2143,2393,2793,3 626,4956,5761,11321,3847,2805,3621,2702,2776
POSITION COUNT OF v is:3901,3834,4447,4785,4917,4857,4395,4187,3765,3338,2876,2482,2254,2217,2257,2467,2729,2 997,3305,4342,5305,11215,3445,3708,3008,2967
POSITION COUNT OF w is:4119,4132,4657,4947,4837,4714,4345,3984,3689,3328,2887,2500,2417,2350,2516,2622,2755,2 857,3133,3557,3844,5094,10545,3286,3921,2964
POSITION COUNT OF x is:4535,4515,4916,4866,4544,4190,4010,3721,3610,3279,3126,2740,2661,2682,2797,2887,3123,3 077,2954,2817,3418,4208,4645,10185,3771,2723
POSITION COUNT OF y is:5207,5053,4972,4476,3983,3699,3593,3462,3441,3348,3283,3049,2903,2899,3145,3336,3343,3 236,3066,2914,2709,2771,4125,4476,9639,3872
POSITION COUNT OF z is:6054,6216,4401,3698,3339,3187,3218,3336,3603,3405,3407,3303,3208,3196,3295,3503,3574,3 410,3296,3111,2867,2762,2692,2998,4094,10827
@@@@@ USING SORT FUNCTION @@@@
POSITION COUNT OF a is:7048,6896,6922,6642,6495,6966,8035,6402,6483,6809,7073,7718,8670,22643,7736,7221,7116, 6875,6623,7677,7131,6625,6800,6941,7063,7390
POSITION COUNT OF b is:10633,11230,6457,6756,6792,6692,6971,7303,7370,7371,7234,7276,7067,7033,7248,7380,7193 ,7317,7085,6973,7032,7294,7618,8184,9211,11280
POSITION COUNT OF c is:9963,9370,12206,6047,6121,6835,6944,7120,7334,7346,7046,6967,6800,6727,6815,6963,7207, 7300,7433,7250,7650,7631,8173,8698,9006,9048
POSITION COUNT OF d is:8432,8347,8465,13595,6812,6018,6390,7084,7266,7053,6926,6559,6392,6570,6602,6871,7326, 7609,7478,7807,7926,8172,8807,8827,8576,8090
POSITION COUNT OF e is:7275,7183,8780,8527,14854,7144,6158,6350,6632,7002,6750,6560,6352,6330,6366,6728,7262, 7660,8003,8206,8152,8471,8854,8506,8241,7654
POSITION COUNT OF f is:7028,7011,8403,8289,8987,15354,7533,6746,6212,5784,6127,6470,6030,6054,6297,6828,7380, 7775,8164,8296,8457,8726,8496,8283,7984,7286
POSITION COUNT OF g is:6759,6885,7316,8482,8489,9464,15543,7935,6885,6009,5649,5328,5699,6170,6360,6837,7325, 7786,8223,8485,8597,8552,8240,8130,7605,7247
POSITION COUNT OF h is:6992,7025,7100,7814,7429,8068,9226,15944,7358,6918,6299,5845,5777,5802,6294,6767,7369, 7877,8173,8285,8309,8292,8280,7700,7691,7366
POSITION COUNT OF i is:7266,7242,7153,7312,7722,6900,7608,8355,16314,7192,6621,6512,6248,6231,6543,6751,7332, 7841,8109,8013,7993,8191,7756,7744,7567,7484
POSITION COUNT OF j is:7598,7575,7144,6972,7850,6484,6684,7355,8206,17234,7042,6845,6888,6612,6761,6778,7155, 7588,8040,7917,7627,7615,7505,7441,7594,7490
POSITION COUNT OF k is:7442,7647,7303,6735,6972,7552,6286,6572,7308,8254,18843,7258,6883,6913,6986,7113,7195, 7365,7984,7558,7411,7179,7291,7275,7324,7351
POSITION COUNT OF l is:7428,7376,7194,6669,6800,7895,6185,6135,6817,7225,8293,20967,7465,7239,7274,7260,7071, 6900,7610,7371,7239,6850,6968,7002,7329,7438
POSITION COUNT OF m is:7087,7165,6896,6675,6676,6871,7747,6262,6431,7058,7537,8384,22213,7716,7419,7231,6931, 6900,6726,8026,7101,6751,6706,7166,6983,7342
POSITION COUNT OF n is:3852,3871,3988,4172,4429,4956,6124,7441,9986,12986,15719,17590,18088,16635,13686,10935 ,7846,5889,4687,4236,3881,3785,3829,3802,3872,3715
POSITION COUNT OF o is:6866,7064,6615,6767,6480,6823,7323,7696,6676,6793,7023,7350,7849,9114,22166,7449,6926, 6765,6495,6341,8193,6843,6709,7071,7135,7468
POSITION COUNT OF p is:7193,7026,6895,6964,6695,6943,7216,8137,7037,7075,6934,6906,7501,8031,8943,20305,6953, 6805,6349,6270,7931,6920,6861,7205,7249,7656
POSITION COUNT OF q is:7579,7429,7228,7229,7031,7111,7503,7598,7564,7129,7008,6713,6773,7245,7856,8638,18874, 6647,6369,6336,6377,7991,7262,7386,7458,7666
POSITION COUNT OF r is:7569,7512,7489,7561,7480,7480,7618,7714,7643,7139,6896,6714,6584,6672,7008,7773,8468,1 7287,6842,6296,6471,7707,7444,7382,7555,7696
POSITION COUNT OF s is:7631,7652,7786,8035,8000,7669,7883,7832,7641,7318,6793,6215,6080,6106,6473,7478,8088,8 843,16527,7221,6594,6627,7894,6995,7238,7381
POSITION COUNT OF t is:7595,7565,7976,8352,8392,8295,8161,8123,7658,7288,6726,6284,5956,5719,6024,6433,7496,8 705,9380,15755,7497,6850,7208,6746,6893,6923
POSITION COUNT OF u is:7607,7682,8120,8468,8687,8454,8236,8038,7677,7142,6790,6347,5983,5960,6010,6198,6692,7 389,8731,9681,15085,7692,6747,7415,6649,6520
POSITION COUNT OF v is:7788,7658,8249,8635,8874,8696,8176,8027,7656,7193,6633,6322,6027,6004,6098,6352,6614,6 844,7214,8105,9286,15075,7225,7629,6908,6712
POSITION COUNT OF w is:7993,8006,8534,8767,8664,8648,8203,7935,7597,7150,6682,6337,6295,6167,6251,6448,6626,6 782,6968,7390,7561,8914,14369,7148,7760,6805
POSITION COUNT OF x is:8353,8453,8780,8724,8248,8011,7825,7651,7523,7215,6993,6612,6547,6523,6587,6704,6916,6 945,6794,6680,7174,7993,8508,14019,7617,6605
POSITION COUNT OF y is:9123,8969,8834,8331,7764,7516,7413,7130,7263,7153,7058,6787,6792,6720,7020,7295,7271,7 054,6897,6784,6544,6638,7950,8492,13483,7719
POSITION COUNT OF z is:9900,10161,8167,7480,7257,7155,7009,7115,7463,7164,7305,7134,7041,7064,7177,7264,7368, 7252,7096,7041,6781,6616,6500,6813,8009,14668
Message was edited by: Gaius Coffey -
I'm fairly new to Java, and admittedly not that great, considering I map my programs out the wrong way - in a VB style procedural basis, so my program probably has newbie "bad programming" things here and there, but that's not the problem.
My program compiles okay in JDK v1.2, but then I try to execute it and it gives me the "main" error message - but I don't have ANYTHING called main - what IS it talking about? All assistance would be greatly appreciated.
Code is below.
Taki
import javax.swing.*;
import java.awt.*;
import java.awt.event.*;
public class Assignment1 extends JFrame implements ActionListener
//container components
JLabel introLbl, gameStatusLbl;
JTextField userInputTxt;
JButton enter,
begin;
int x,
userGuess,
guessCounter;
randomNumber y = new randomNumber();
public Assignment1()
x = y.getNumber();
//setup the container
Container c = getContentPane();
c.setLayout( new FlowLayout() );
introLbl = new JLabel( "Guess my number, between 1 and 1,000 inclusive:" );
c.add( introLbl );
userInputTxt = new JTextField( 4 );
userInputTxt.setEditable( true );
c.add( userInputTxt );
enter = new JButton( "Guess!" );
enter.setActionCommand( "enterCommand" );
enter.addActionListener(this);
c.add( enter );
gameStatusLbl = new JLabel( " " );
c.add( gameStatusLbl );
begin = new JButton( "Begin the game again!" );
begin.setActionCommand( "beginCommand" );
enter.addActionListener(this);
c.add( begin );
public class randomNumber
private int x;
public randomNumber()
x = (int)((Math.random() * 999) + 1);
public int getNumber()
return x;
public void actionPerformed ( ActionEvent e )
String command = e.getActionCommand();
if ( command == "beginCommand" )
x = y.getNumber();
gameStatusLbl.setText( " " );
if ( command == "enterCommand" )
userGuess = Integer.parseInt( userInputTxt.getText() );
if ( userGuess == x )
if ( guessCounter < 10 )
gameStatusLbl.setText( "Well done! " );
else
gameStatusLbl.setText( "You took your time! " );
else
if ( userGuess < x )
if ( guessCounter >= 10 )
gameStatusLbl.setText( "Stop guessing and start thinking! (Too low) " );
else
gameStatusLbl.setText( "Too low. Try again. " );
else
if ( guessCounter >= 10 )
gameStatusLbl.setText( "Stop guessing and start thinking! (Too high)" );
else
gameStatusLbl.setText( "Too high. Try again. " );
guessCounter = guessCounter + 1;
}This will get you going!
To run a Java app you need a Class whith a 'public static void main(String [] args)' method.
Your window will probably be small, just pull the corner until you figure out hor to get it to display correctly.
import javax.swing.*;
import java.awt.*;
import java.awt.event.*;
public class Assignment1 extends JFrame implements ActionListener
//container components
JLabel introLbl, gameStatusLbl;
JTextField userInputTxt;
JButton enter,
begin;
int x,
userGuess,
guessCounter;
randomNumber y = new randomNumber();
public Assignment1() {
x = y.getNumber();
//setup the container
Container c = getContentPane();
c.setLayout( new FlowLayout() );
introLbl = new JLabel( "Guess my number, between 1 and 1,000 inclusive:" );
c.add( introLbl );
userInputTxt = new JTextField( 4 );
userInputTxt.setEditable( true );
c.add( userInputTxt );
enter = new JButton( "Guess!" );
enter.setActionCommand( "enterCommand" );
enter.addActionListener(this);
c.add( enter );
gameStatusLbl = new JLabel( " " );
c.add( gameStatusLbl );
begin = new JButton( "Begin the game again!" );
begin.setActionCommand( "beginCommand" );
enter.addActionListener(this);
c.add( begin );
public class randomNumber {
private int x;
public randomNumber() {
x = (int)((Math.random() * 999) + 1);
public int getNumber() {
return x;
public void actionPerformed ( ActionEvent e ) {
String command = e.getActionCommand();
if ( command == "beginCommand" ) {
x = y.getNumber();
gameStatusLbl.setText( " " );
if ( command == "enterCommand" ) {
userGuess = Integer.parseInt( userInputTxt.getText() );
if ( userGuess == x ) {
if ( guessCounter < 10 ) {
gameStatusLbl.setText( "Well done! " );
} else {
gameStatusLbl.setText( "You took your time! " );
} else if ( userGuess < x ) {
if ( guessCounter >= 10 ) {
gameStatusLbl.setText( "Stop guessing and start thinking! (Too low) " );
} else {
gameStatusLbl.setText( "Too low. Try again. " );
} else {
if ( guessCounter >= 10 ) {
gameStatusLbl.setText( "Stop guessing and start thinking! (Too high)" );
} else {
gameStatusLbl.setText( "Too high. Try again. " );
guessCounter = guessCounter + 1;
public static void main(String [] args) {
Assignment1 a = new Assignment1();
a.show();
} -
Getting "The Lead selection has not been set in view"Error during runtime
Hi Guys,
I'm getting this error " The Lead Selection has not been set in view " . If any one has faced the same problem , then please guide me . I am new to WD ABAP so finding it difficult to track the reason.
TIA
Moderator Message: Please search the forum before posting basic messages. Thread locked
Edited by: Neil Gardiner on Oct 1, 2010 3:48 PMHi Pradeep,
I have already checked "Initialisation Lead Selection" property . I have faced the same problem in another view also there it got solved by changing the cardinality. In this case, I had tried both cardinality and Lead selection property but nothing is working.
Thanx. -
SAP HANA Spatial Features (Store Error)
I've been stumbling with an the folowing error : "Error: SAP DBTech JDBC: [2048]: column store error: search table error: " over and over again. Every time I add a spatial column to a table it becomes unsuable (can't query, edit, add, update) so I have to delete the whole table and repopulate it, which is really annoying. Sometimes it doesn't happen right away, sometimes it works just fine at first but after a few minutes or hours the table just stops "working". It has happened several times with different tables.
If anyone can tell me why is that happening or how to solve it I would be very grateful.
I'm using Hana Version 1.00.74.00.390550.
Thanks in advance.Hi Dario,
Does the calculation view work without xsodata service? From the URL, your XS project name should be Project_DM, but from the xsodata source, the project name is EricssonItalgas. I'm confused with this. Did you use rewrite_rules or?
Best regards,
Wenjun -
Object Referenced Error When calling the Windows Form during Runtime
Hi,
I am getting Object reference errors when running windows form during runtime. In debugging mode in MS Visual studio 2005, I am not getting this error. I'm calling the window form from menu and called the window in a thread as suggested in one of forums . I don't see anyone in the forum mentioned this problem I have. Any help would be deeply appreciated. Below are the error and code samples.
ERROR Message
Exception Text **************
System.NullReferenceException: Object reference not set to an instance of an object.
at Project1.Loadxml.Loadxml_Load(Object sender, EventArgs e)
at System.Windows.Forms.Form.OnLoad(EventArgs e)
at System.Windows.Forms.Form.OnCreateControl()
at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
at System.Windows.Forms.Control.CreateControl()
at System.Windows.Forms.Control.WmShowWindow(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ContainerControl.WndProc(Message& m)
at System.Windows.Forms.Form.WmShowWindow(Message& m)
at System.Windows.Forms.Form.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
Edited by: Albert Tio on Feb 16, 2011 9:55 AMHere is the code.
Option Strict Off
Option Explicit On
Friend Class GetEvents
Public WithEvents SBO_Application As SAPbouiCOM.Application
Public SboGuiApi As SAPbouiCOM.SboGuiApi
Public oForm As SAPbouiCOM.Form
Public oDBDataSource As SAPbouiCOM.DBDataSource
Public oCompany As SAPbobsCOM.Company
Public RS As SAPbobsCOM.Recordset
Public oPrev_Bank As String, oPrev_AcctType As String
Public oLoadXml As Loadxml
Public Sub SetApplication()
'Dim SboGuiApi As SAPbouiCOM.SboGuiApi
Dim sConnectionString As String
SboGuiApi = New SAPbouiCOM.SboGuiApi
' by following the steps specified above, the following
' statment should be suficient for either development or run mode
sConnectionString = Environment.GetCommandLineArgs.GetValue(1)
' connect to a running SBO Application
SboGuiApi.Connect(sConnectionString)
' get an initialized application object
SBO_Application = SboGuiApi.GetApplication()
End Sub
Public Sub SetCompany()
Dim ret As Long
Dim MsgStr As String
Dim Cookie As String
Dim ConnStr As String
Try
oCompany = New SAPbobsCOM.Company
Cookie = oCompany.GetContextCookie
ConnStr = SBO_Application.Company.GetConnectionContext(Cookie)
'//before setting the SBO login context make sure the company is not connected
If oCompany.Connected = True Then
oCompany.Disconnect()
End If
ret = oCompany.SetSboLoginContext(ConnStr)
If Not ret = 0 Then
Exit Sub
End If
ret = oCompany.Connect
Catch ex As Exception
SBO_Application.MessageBox(ex.Message)
End Try
MsgStr = ""
If Not ret = 0 Then
oCompany.GetLastError(ret, MsgStr)
SBO_Application.MessageBox(MsgStr)
Else
End If
End Sub
Public Sub New()
MyBase.New()
' set SBO_Application with an initialized application object
SetApplication()
SetCompany()
AddMenuItems()
End Sub
Private Sub SBO_Application_MenuEvent(ByRef pVal As SAPbouiCOM.MenuEvent, ByRef BubbleEvent As Boolean) Handles SBO_Application.MenuEvent
Dim myThread As New System.Threading.Thread(New System.Threading.ThreadStart(AddressOf LoadXmlMainThread))
Try
If (pVal.MenuUID = "MySubMenu") And (pVal.BeforeAction = False) Then
'SBO_Application.MessageBox("My sub menu item was clicked")
'// Create a form to be launched in response to a click on the
'// new sub menu item
myThread.SetApartmentState(System.Threading.ApartmentState.STA)
myThread.Start()
'Loadxml.ShowDialog()
End If
Catch ex As Exception
SBO_Application.MessageBox("1." & ex.Message)
End Try
'If (pVal.MenuUID = "MyGoToMenu") And (pVal.BeforeAction = False) Then
' SBO_Application.MessageBox("My GoTo Menu was clicked")
'End If
'If (pVal.MenuUID = "MySecondGoToMenu") And (pVal.BeforeAction = False) Then
' SBO_Application.MessageBox("My Second GoTo Menu was clicked")
'End If
End Sub
Private Sub LoadXmlMainThread()
'Dim lLoadxml As New Loadxml
Try
oLoadXml = New Loadxml
oLoadXml.WindowState = FormWindowState.Maximized
oLoadXml.ShowInTaskbar = True
oLoadXml.TopMost = True
oLoadXml.Activate()
Application.Run(oLoadXml)
Catch ex As Exception
SBO_Application.MessageBox("2." & ex.Message)
End Try
End Sub
Private Sub AddMenuItems()
'// Let's add a separator, a pop-up menu item and a string menu item
Dim oMenus As SAPbouiCOM.Menus
Dim oMenuItem As SAPbouiCOM.MenuItem
Dim i As Integer '// to be used as counter
Dim lAddAfter As Integer
Dim sXML As String
'// Get the menus collection from the application
oMenus = SBO_Application.Menus
'Save an XML file containing the menus...
'sXML = SBO_Application.Menus.GetAsXML
'Dim xmlD As System.Xml.XmlDocument
'xmlD = New System.Xml.XmlDocument
'xmlD.LoadXml(sXML)
'xmlD.Save("c:
mnu.xml")
Dim oCreationPackage As SAPbouiCOM.MenuCreationParams
oCreationPackage = SBO_Application.CreateObject(SAPbouiCOM.BoCreatableObjectType.cot_MenuCreationParams)
oMenuItem = SBO_Application.Menus.Item("43520") 'moudles'
Dim sPath As String
sPath = Application.StartupPath
'sPath = sPath.Remove(sPath.Length - 3, 3)
If sPath.EndsWith("\") = False Then
sPath = sPath & "\"
End If
'// find the place in wich you want to add your menu item
'// in this example I chose to add my menu item under
'// SAP Business One.
oCreationPackage.Type = SAPbouiCOM.BoMenuType.mt_POPUP
oCreationPackage.UniqueID = "MyMenu01"
oCreationPackage.String = "Unbridle Menu"
oCreationPackage.Enabled = True
oCreationPackage.Image = sPath & "unbridle.bmp"
oCreationPackage.Position = 15
oMenus = oMenuItem.SubMenus
Try ' If the manu already exists this code will fail
oMenus.AddEx(oCreationPackage)
'// Get the menu collection of the newly added pop-up item
oMenuItem = SBO_Application.Menus.Item("MyMenu01")
oMenus = oMenuItem.SubMenus
'// Create s sub menu
oCreationPackage.Type = SAPbouiCOM.BoMenuType.mt_STRING
oCreationPackage.UniqueID = "MySubMenu"
oCreationPackage.String = "Unbridle Monitoring"
oMenus.AddEx(oCreationPackage)
Catch er As Exception ' Menu already exists
'SBO_Application.MessageBox("Menu Already Exists")
End Try
End Sub
End Class
Public Class Loadxml
'Inherits System.Windows.Forms.Form
Public sBPpath As String
Public sGLpath As String
Public sBillpath As String
Public bRun As Boolean
Private Sub Loadxml_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Me.TextGL.Text = System.Configuration.ConfigurationSettings.AppSettings("GLAcctDownloadPath").ToString()
Me.TextBP.Text = System.Configuration.ConfigurationSettings.AppSettings("BPAcctUPloadPath").ToString()
Me.TextBill.Text = System.Configuration.ConfigurationSettings.AppSettings("BillUPloadPath").ToString()
Me.NotifyIcon1.Visible = False
End Sub
End Class -
Error in FTP sender -Error during STOR/APPE
Hi,
I am working on IDOC- File.
I am getting the following error in Communication channel,
Error occurred while connecting to the FTP server "server name": java.io.IOException: Error during STOR/APPE epilogue: com.sap.aii.adapter.file.ftp.FTPEx: 550 STOR fails: /Filename. User not authorized.
Please advise me.
Regards,
ManojManoj,
Please refer the thread, the same issue has been solved.
Re: FTP: File receiver cc error...Looks pretty simple...Can U solve this
Best regards,
raj.
Maybe you are looking for
-
How do i get music that i have put into my itunes folder, i.e. it was not purchased in itunes but from another source, onto my ipod? I have looked at a number of different discussions and none have given me the solution. I have recently had to do a
-
CC will not allow After Effects CS6 to Update
I am a frequent After Effects CS6 user; not so long ago I started a subsciption with Adobe Creative Cloud and I've had nothing but issues with it. The CC desktop would crash my whole system on launch, so I cancelled my subsciption and uninstalled any
-
Installer failed to initialize
I am getting an "Installer failed to initialize" error while trying to install PSE 9 from a DVD and PSE 10 from a download. I download Adobe Support Advisor but it crashes without giving any error message. Located PDApp.log for the failed PSE 9 insta
-
Entity-Named Query Caching - Need live results from DB not Cached
I've developed an application EJB3 web application which uses Entity Beans and NamedQueries to retrieve my results. Aswell as my main EJB3 web application I also have an external interface (Oracle Stored Procedure) which is updating data in my databa
-
I have a column of conductivity measurements overtime at 1/10 s intervals. In preparation for data analysis I isolate each individual event which begins when at the point dye is introduced to the system, the pulse then travels to the measuring device