Help me to display result
this is my class that i want to get result from :
class QuickSorter
long StartTime, EndTime,Compare=0, Move=0;
int[] array;
public QuickSorter(int[] unSorted)
array=unSorted;
public void quickSort(int lowIndex, int highIndex)
int lowToHighIndex;
int highToLowIndex;
int pivotIndex;
int pivotValue;
int lowToHighValue;
int highToLowValue;
int parking;
int newLowIndex;
int newHighIndex;
int compareResult;
lowToHighIndex = lowIndex;
highToLowIndex = highIndex;
pivotIndex = (lowToHighIndex + highToLowIndex) / 2;
pivotValue = array[pivotIndex];
newLowIndex = highIndex + 1;
newHighIndex = lowIndex - 1;
while ((newHighIndex + 1) < newLowIndex) // loop until partition complete
{ // loop from low to high to find a candidate for swapping
lowToHighValue = array[lowToHighIndex];
while ((lowToHighIndex < newLowIndex)&& (pivotValue>lowToHighValue ))
newHighIndex = lowToHighIndex; // add element to lower part
lowToHighIndex ++;
lowToHighValue = array[lowToHighIndex];
// loop from high to low find other candidate for swapping
highToLowValue = array[highToLowIndex];
while (newHighIndex <= highToLowIndex && pivotValue<highToLowValue)
newLowIndex = highToLowIndex; // add element to higher part
highToLowIndex --;
highToLowValue = array[highToLowIndex];
// swap if needed
if (lowToHighIndex == highToLowIndex) // one last element, may go in either part
{ newHighIndex = lowToHighIndex; // move element arbitrary to lower part
else if (lowToHighIndex < highToLowIndex) // not last element yet
{ compareResult = array[highToLowValue];
if (compareResult >= 0) // low >= high, swap, even if equal
{ parking = lowToHighValue;
array[lowToHighIndex]=highToLowValue;
array[highToLowIndex]=parking;
newLowIndex = highToLowIndex;
newHighIndex = lowToHighIndex;
lowToHighIndex ++;
highToLowIndex --;
if (lowIndex < newHighIndex)
quickSort(lowIndex, newHighIndex); // sort lower subpart
if (newLowIndex < highIndex)
quickSort(newLowIndex, highIndex); // sort higher subpart
then i want to get the result from call the method quickSort to a JPanel
public void actionPerformed(ActionEvent evt)
if(evt.getActionCommand().equals("3")&&passed3!=true)
QuickSorter QSort=new QuickSorter(array);
QSort.quickSort(0,array.length-1);
TF3.setText(""+QSort.EndTime);
CF3.setText(""+QSort.Compare);
MF3.setText(""+QSort.Move);
passed3=true;
int[] sortedarray=array;
System.out.println("the list sorted by Quicksort is:");
display(sortedarray);
array=getBack(n);
but the run time error is display when i run it, plz help
1) Use the code tags when posting code
2) So there's a runtime error. Do you expect us to guess what it is or will you tell us?
Similar Messages
-
Http Service : Help required in displaying result
Hi All,
I have created a http service and i'm trying to post the http request. the result is Successful but i'm not able to display the result in the alert window.
This is what I'm trying to do on the result event handler function.
protected function postRequestResult_resultHandler(event:ResultEvent):void
var srt:String = event.result.nodeValue;
Alert.show(srt , "Result");
but I'm getting an output something like [object object ]
Please help. All I need is to do is, display the complete soap envelop ( soap header and body ) present in the result.
Is there a way to do it ?
Thanks and regards,
adewrnHi,
Thanks for all your replies. I was able to solve it by making the resultFormat property of http service object as text, This returned the entire result as a string. And i was able to display it.
Regards,
adewrn -
Need Help Urgently For Displaying RESULTS PER PAGE
i am comiling a serch engine throgh JSDK servlets and using a personal Oracle database. i currently have over 2000 records and when they are returned they are all being returned in one big table. i am trying to get the servlet to display so many results per page, for example 30 per page. I am at a loss on how to do this and have tried a number of methods, i urgently need to find a way of doing this as it is for a Major school project. I hope someone can help me i would be extremly greatful if someone could. Please
ThanksHello --
One way to do this would be something like this:
1. Start out with a page where filtering parameters could be entered, submit to the servlet with a starting position of 0.
2. Grab all the rows from the oracle database, toss them in an array.
3. Draw items in a table from the starting position to the number of entries per page from the array.
4. Put a Previous and Next button on the results page to submit back to the servlet in step 2 where the starting position is the current position - number of results per page for previous, next is the has a starting position of current position + number of results per page. You'll want to do range checking, etc on this.
The key trick is to ask one servlet to do steps 2-4. I've used hidden variables on the form with some javascript to set the new starting parameter for previous and next. You could assemble a URL in javascript also.
There are probably slicker ways to do this, but for 2000 rows, it should probably work well enough.
Good luck.
Donn -
Hi All,
I am crawling documents from a file server. I created a new content source and crawled the documents. All documents are crawled successfully.
Then I went to my enterprise search center site collection and created a new result source. I have added the query to use above content source.
After that, on a page I am trying to configure the search results web part to display documents using this result source. Now the problem is:
It displays all the documents that are crawled without searching for anything. I mean first it should not display any results. If a user searches for something , then according to that search it should display results.
Any idea how to do this in the web part? I am using SharePoint 2013 on premise enterprise edition. No code. Totally OOTB.Hi Mohan,
What did you use for the Query text in the result source?
I could reproduce this issue when I used Query text like: {searchTerms} Path:”http://sps2k13sp/sites/First/Shared%20Documents”
Then I changed the Query to
{?{searchTerms}
Path:"http://sps2k13sp/sites/First/Shared%20Documents"}
, then Search result web part didn’t return results without searching.
So , check your result source, and use the Query like the above(adding "{?...}").
I hope this helps.
Thanks,
Wendy
Wendy Li
TechNet Community Support -
Unable to display results of multiple query in grid in Oracle SQL Developer
Hi, I am a newbie to this forum and couldn't find the Oracle SQL Developer forum so posting it here.
My question: How to display multiple query results in grid in Oracle SQL Developer.
Example:
select * from Employee;
select * from Department;
- when I select both the queries and hit F5 in Oracle sql developer. By default it displays in output window.
- How to display result of both the queries in Grid.
Any thoughts on this would be really helpful.
Thanks in advance.
HarshHi Harsh,
I'd say that the Results grid is designed to only show the results of 1 query at a time. I don't know/can't see how it would display multiple queries at a time.
I would suggest either joining your tables to create a single query or opening another SQL Worksheet for one of the queries so that you can display the results side-by-side.
Maybe you could explain what you're trying to do. Why are you trying to display multiple results in the same query grid? -
Display results of MySQL query from AMFPHP by ArrayCollection in AS3 (Flash CS4)
Hi, i am using Flash CS4 (AS3) + AMFPHP + MySQL to do own flash frontend for Wordpress CMS. Everything is going fine but i`ve got one problem. Problem with properly display of result of query in AS3 by using ArrayCollection.
When i check my service in "amfphp/browser/" in web browser i`ve got this (with all needed data):
(mx.collections::ArrayCollection)#0
filterFunction = (null)
length = 2
list = (mx.collections::ArrayList)#1
length = 2 source = (Array)#2
That is the reason that i suppose that service work fine. Problem is when i try to display result in AS3. In actionscript i have got this:
function getNewsListHandler(result:Object):void{
trace(result);
This function displays: [object Object].
I know that "result" is an ArrayCollection type but i don`t know how to get rows and columns from this. I know that my data is there but i have no idea how to get it.
Clarify: I don`t know how to get to Arrays and simple data variables which are in ArrayCollection.
Could anyone help me with that problem. I would be gratefull
P.S. I tried also change query type in service.PHP for mysql_fetch_query but in that case i`ve got only one row (not all data).Thanks for fast reply,
arr_coll:ArrayCollection = new ArrayCollection ({col1:"data1",col2:"data2"}, {col1:"data3",col2:"data4"});
you would get the data like
var resultstr:String = arr_coll[1][1].col2;
trace(resultstr);
//results in data4
could you explain me how it was happen (arr_coll[1][1].col2)? It`s not clear to me. I thought in this case rather something like this :
var resultstr:String = arr_coll[1]['col2'];
It should give me "data4". I know it wasn`t but i don`t understand ArrayCollection in level which is needed to use your advice in my case. Could you clarify "arr_coll[1][1].col2" a bit?
What would it look like when you would have something like this:
arr_coll:ArrayCollection = new ArrayCollection ({col1:"data1",col2:"data2"}, {col1:"data3",col2:"data4"},{col1:"data5",col2:"data6"},{col1:"data7",col2:"data8"});
and you would want know f.e. position in ArrayCollection of "data6". How would you code this? arr_coll[1][2].col2? -
How to simply display resulting text in a dialog Box
Is there a way to simply display resulting text in a dialog Box - not a text edit document?
Doug_Thanks that's very helpful
What I am trying to to is to create a workflow that opens mail and displays iCal TO DO's that I have created throughout the day tagged with the word MAIL so they can be filtered.
At the moment the ACTIONS are:
Launch Mail
Get New Mail
Find TO DOs in iCal (Who's SUMMERY includes MAIL)
I get iCal To Do's as a result
But then...I can find no options to display the iCal Events that result.
Putting in the Applescript you posted displays a blank dialog box. This tells me that there is no text in the result.
Yet if I put a SPEAK TEXT in after find TO DOs it dutifully speaks my filtered TO DO's
I thought I might just try a NEW MAIL MESSAGE action.
This works great in the workflow. The content of the new mail is the filtered TO DOs.
But if I save it as an application (the form I need it in), mail simply opens blank when it reached that part of the work flow.
What would you recommend?
Thank again for your help,
Doug_
Message was edited by: Douglas Suiter
Message was edited by: Douglas Suiter
Message was edited by: Douglas Suiter -
After displaying result of report, my report goes back to source code edito
Hello experts,
I am currently having a big problem with my report. Here is the problem, after displaying the
result(write), when I press BACK button it is not going back to my selection-screen which is the
usual for reports. Now, what happens is that it goes back to the source code or worse, to the main menu of SAP.
What I want to do is that when I press BACK button it should go to either selection-screen 500 or
selection-screen 1500.
Here's a rough flow of what is happening in my report:
start report -> fetch records based on user input -> display results(not in ALV) ->
after displaying report, click 'BACK' button -> it goes back to source code
Now, here's what I want to do:
start report -> fetch records based on user input -> display results(not in ALV) ->
after displaying report, click 'BACK' button -> go back to either selection-screen 500 or 1500
or call again the transaction of my report.
Help would be greatly appreciated here.Hi guys,
Thanks again for the quick replies.Here is the source code:
REPORT zdealer_contacts NO STANDARD PAGE HEADING
LINE-COUNT 0
LINE-SIZE 255
MESSAGE-ID zz.
TYPE-POOLS: slis.
Data Dictionary Tables
TABLES: zts0001,
zsoemailid,
kna1,
zts_stpgeoloc.
Includes
*INCLUDE zun_globe_header. " Globe Telecom Report Header
Structures, internal tables and data declarations
TYPES: BEGIN OF t_upload,
kunnr LIKE zts0001-kunnr,
zaddress(100),
zcperson(30),
zcnumber(18),
END OF t_upload.
TYPES: BEGIN OF t_error,
kunnr LIKE zts0001-kunnr,
zaddress(100),
zcperson(30),
zcnumber(18),
END OF t_error.
TYPES: BEGIN OF t_kna1,
name1 LIKE kna1-name1,
END OF t_kna1.
TYPES: BEGIN OF t_zts0001,
kunnr LIKE zts0001-kunnr,
cdseq LIKE zts0001-cdseq,
zaddress LIKE zts0001-zaddress,
zcperson LIKE zts0001-zcperson,
zcnumber LIKE zts0001-zcnumber,
zactivated LIKE zts0001-zactivated,
name1 LIKE kna1-name1,
END OF t_zts0001.
DATA: it_upload TYPE STANDARD TABLE OF t_upload WITH HEADER LINE,
it_error TYPE STANDARD TABLE OF t_error WITH HEADER LINE,
it_kna1 TYPE STANDARD TABLE OF t_kna1 WITH HEADER LINE,
it_zts0001 TYPE STANDARD TABLE OF t_zts0001 WITH HEADER LINE.
DATA: it_ztstemp LIKE zts0001 OCCURS 100 WITH HEADER LINE,
it_ztstemp_gloc LIKE zts_stpgeoloc OCCURS 100 WITH HEADER LINE.
*AVH - start of insertion - 04/18/06
FIELD-SYMBOLS: <fs_zts0001> LIKE LINE OF it_zts0001.
**ALV Declarations
DATA: gt_fieldcat TYPE slis_t_fieldcat_alv,
g_repid LIKE sy-repid,
gs_layout TYPE slis_layout_alv,
gt_list_top_of_page TYPE slis_t_listheader,
gt_events TYPE slis_t_event WITH HEADER LINE,
gt_print TYPE slis_print_alv.
CONSTANTS: gc_top TYPE slis_formname VALUE 'TOP_OF_PAGE',
gc_topsum TYPE slis_formname VALUE 'TOP_OF_LIST',
gc_ucomm TYPE slis_formname VALUE 'USER_COMMAND'.
*AVH - end of insertion
Variables
DATA: v_kunnr LIKE zts0001-kunnr,
v_title(100) TYPE c,
gc_kunnr(06) TYPE c,
v_compflag(1) TYPE c,
v_flag(1).
Selection Screen
*AVH - start of modification - 06/27/06
*if user is controller, selection-screen 500 will be called else,
*selection-scren 1500 will be called.
*selection-screen for controllers
SELECTION-SCREEN BEGIN OF SCREEN 500.
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS: pr_upld RADIOBUTTON GROUP grp2 USER-COMMAND ucomm1.
SELECTION-SCREEN COMMENT 2(20) text-007 FOR FIELD pr_upld.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 03(15) text-a11 FOR FIELD p_flnme.
PARAMETERS: p_flnme LIKE rlgrap-filename DEFAULT 'C:\'.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS: pr_list1 RADIOBUTTON GROUP grp2.
SELECTION-SCREEN COMMENT 2(7) text-003 FOR FIELD pr_list1.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN END OF BLOCK b1.
SELECTION-SCREEN END OF SCREEN 500.
*selection-screen for non-controllers.
SELECTION-SCREEN BEGIN OF SCREEN 1500.
SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME TITLE text-001.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(22) text-002 FOR FIELD p_dcode.
PARAMETERS: p_dcode LIKE vbak-kunnr,
p_name1 LIKE kna1-name1.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS: pr_list2 RADIOBUTTON GROUP grp USER-COMMAND ucomm2.
SELECTION-SCREEN COMMENT 2(7) text-003 FOR FIELD pr_list2.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS: pr_add RADIOBUTTON GROUP grp.
SELECTION-SCREEN COMMENT 2(3) text-005 FOR FIELD pr_add.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS: pr_edit RADIOBUTTON GROUP grp.
SELECTION-SCREEN COMMENT 2(4) text-006 FOR FIELD pr_edit.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 03(20) text-a12 FOR FIELD p_code.
PARAMETERS: p_code LIKE zts0001-cdseq.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN END OF BLOCK b2.
SELECTION-SCREEN END OF SCREEN 1500.
INITIALIZATION.
SELECT SINGLE kunnr comp_flag INTO (gc_kunnr,v_compflag)
FROM zsoemailid
WHERE bname = sy-uname.
IF sy-subrc <> 0.
MESSAGE i000 WITH
'You are not authorised to use this transaction'.
LEAVE PROGRAM.
ENDIF.
IF v_compflag = 'X'.
CALL SCREEN 500.
ELSE.
CALL SCREEN 1500.
ENDIF.
*AVH - end of modification
AT SELECTION-SCREEN OUTPUT.
PERFORM authority_check.
added by derick 050125
**-changed by weng rulloda 06012005
*AVH - start of insertion - 05/22/06
*no need to get value of kunnr from global memory
*since gc_kunnr would be filled via the select statement below
GET PARAMETER ID 'KUN' FIELD gc_kunnr.
*AVH - end of insertion
p_dcode = gc_kunnr.
*AVH - start of insertion - 05/22/06
**fetch the respective description of dealer based from p_dcode
**and put in parameter p_name1
SELECT SINGLE name1 FROM kna1
INTO p_name1
WHERE kunnr = p_dcode.
*AVH - end of insertion
*AVH - start of insertion - 05/22/06
**selection-screen parameters is based if user is controller or not.
**created new selection-screen conditions based from orig. code
v_kunnr = gc_kunnr.
LOOP AT SCREEN.
IF screen-name = 'P_DCODE'.
screen-input = '0'.
screen-output = '1'.
MODIFY SCREEN.
ELSEIF screen-name = 'P_NAME1'.
screen-input = '0'.
screen-output = '1'.
MODIFY SCREEN.
ELSEIF screen-name = 'P_CODE'.
screen-input = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
IF pr_list2 = 'X' OR pr_add = 'X'.
LOOP AT SCREEN.
IF screen-name = 'P_CODE'.
screen-input = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ELSEIF pr_edit = 'X'.
LOOP AT SCREEN.
IF screen-name = 'P_CODE'.
screen-input = '1'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.
IF pr_list1 = 'X'.
LOOP AT SCREEN.
IF screen-name = 'P_FLNME'.
screen-input = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.
*AVH - end of modification
AT SELECTION-SCREEN.
CHECK sy-ucomm = 'UCOMM1' OR sy-ucomm = 'UCOMM2'.
*AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_flnme.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_flnme.
CALL FUNCTION 'WS_FILENAME_GET'
EXPORTING
mask = ',.,..'
mode = 'O'
title = 'File Selection'
IMPORTING
filename = p_flnme
EXCEPTIONS
inv_winsys = 1
no_batch = 2
selection_cancel = 3
selection_error = 4
OTHERS = 5.
*AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_code.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_code.
DATA : BEGIN OF itab_list OCCURS 0,
kunnr LIKE zts0001-kunnr,
cdseq LIKE zts0001-cdseq,
zaddress LIKE zts0001-zaddress,
zcperson LIKE zts0001-zcperson,
zcnumber LIKE zts0001-zcnumber,
END OF itab_list.
DATA: tab_fields LIKE dfies OCCURS 0 WITH HEADER LINE,
tab_valuetab(100) TYPE c OCCURS 0 WITH HEADER LINE.
DATA: tab_dynnr TYPE sy-dynnr.
DATA: BEGIN OF tab_return_tab OCCURS 0.
INCLUDE STRUCTURE ddshretval.
DATA: END OF tab_return_tab.
DATA: progname LIKE sy-repid.
CLEAR: tab_valuetab[], tab_fields[].
SELECT kunnr cdseq zaddress zcperson zcnumber
INTO CORRESPONDING FIELDS OF TABLE itab_list
FROM zts0001
WHERE kunnr = v_kunnr.
tab_dynnr = sy-dynnr.
tab_fields-tabname = 'ZTS0001'.
tab_fields-fieldname = 'KUNNR'.
APPEND tab_fields.
tab_dynnr = sy-dynnr.
tab_fields-tabname = 'ZTS0001'.
tab_fields-fieldname = 'CDSEQ'.
APPEND tab_fields.
tab_fields-tabname = 'ZTS0001'.
tab_fields-fieldname = 'ZADDRESS'.
APPEND tab_fields.
tab_fields-tabname = 'ZTS0001'.
tab_fields-fieldname = 'ZCPERSON'.
APPEND tab_fields.
tab_fields-tabname = 'ZTS0001'.
tab_fields-fieldname = 'ZCNUMBER'.
APPEND tab_fields.
LOOP AT itab_list.
tab_valuetab = itab_list-kunnr.
APPEND tab_valuetab.
tab_valuetab = itab_list-cdseq.
APPEND tab_valuetab.
tab_valuetab = itab_list-zaddress.
APPEND tab_valuetab.
tab_valuetab = itab_list-zcperson.
APPEND tab_valuetab.
tab_valuetab = itab_list-zcnumber.
APPEND tab_valuetab.
ENDLOOP.
progname = sy-repid.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = 'CDSEQ'
dynpprog = progname
dynpnr = '1000'
dynprofield = 'P_CODE'
TABLES
value_tab = tab_valuetab
field_tab = tab_fields
return_tab = tab_return_tab
EXCEPTIONS
OTHERS = 0.
START-OF-SELECTION.
IF pr_edit = 'X' AND p_code IS INITIAL.
MESSAGE i008 WITH 'Please specify a ship-to code.'.
LEAVE TO TRANSACTION 'ZDCONTACT'.
ENDIF.
PERFORM get_data.
IF pr_upld = 'X'.
PERFORM upload_file.
ELSEIF pr_add = 'X'.
PERFORM add_record.
ELSEIF pr_edit = 'X'.
PERFORM edit_record.
ELSEIF pr_list1 = 'X' OR pr_list2 = 'X'.
PERFORM display_alv.
ENDIF.
END-OF-SELECTION.
based from ALV PF-STATUS
IF sy-ucomm = '&F03'. "BACK
LEAVE TO TRANSACTION 'ZDCONTACT'.
ELSEIF sy-ucomm = '&F15'. "EXIT
LEAVE TO TRANSACTION 'ZDCONTACT'.
ELSEIF sy-ucomm = '&F12'. "CANCEL
LEAVE TO TRANSACTION 'ZDCONTACT'.
ENDIF.
*& Form authority_check
FORM authority_check.
CALL FUNCTION 'AUTHORITY_CHECK'
EXPORTING
field1 = 'TCD' "MDM
object = 'S_TCODE'
user = sy-uname
value1 = 'ZMEN'
VALUE3 = '01' MDM
EXCEPTIONS
user_dont_exist = 1
user_is_authorized = 2
user_not_authorized = 3
user_is_locked = 4
OTHERS = 5.
IF sy-subrc NE 2.
**-added by weng 04/28/2006
**-if user is not authorized to use dealer portal check if he is
**- authorized to use the tcode ZDCONTACT
CALL FUNCTION 'AUTHORITY_CHECK'
EXPORTING
field1 = 'TCD' "MDM
object = 'S_TCODE'
user = sy-uname
value1 = 'ZDCONTACT'
VALUE3 = '01' MDM
EXCEPTIONS
user_dont_exist = 1
user_is_authorized = 2
user_not_authorized = 3
user_is_locked = 4
OTHERS = 5.
**-weng
IF sy-subrc NE 2.
MESSAGE i000 WITH
'You are not authorised to use this transaction'.
LEAVE PROGRAM.
ENDIF.
ENDIF.
ENDFORM. " AUTHORITY_CHECK
*& Form get_data
FORM get_data.
*AVH - start of insertion - 04/19/06
**records selected from table zts0001 that has been marked as
**activated will be fetched otherwise, ignore.
IF v_kunnr IS INITIAL.
SELECT * INTO CORRESPONDING FIELDS OF TABLE it_zts0001
FROM zts0001.
ELSEIF v_compflag = 'X'.
SELECT * INTO CORRESPONDING FIELDS OF TABLE it_zts0001
FROM zts0001.
ELSE.
SELECT * INTO CORRESPONDING FIELDS OF TABLE it_zts0001
FROM zts0001
WHERE kunnr = v_kunnr.
ENDIF.
*AVH - start of insertion - 05/24/06
**fetch name based from kunnr and put in itab
LOOP AT it_zts0001 ASSIGNING <fs_zts0001>.
SELECT SINGLE name1 FROM kna1
INTO <fs_zts0001>-name1
WHERE kunnr = <fs_zts0001>-kunnr.
ENDLOOP.
*AVH - end of insertion
ENDFORM. " get_data
*& Form Upload_file
FORM upload_file.
DATA: lv_seq(5) TYPE n,
lv_ctr(5) TYPE c,
lv_kunnr LIKE it_upload-kunnr.
v_title = 'Upload from File'.
CALL FUNCTION 'WS_UPLOAD'
EXPORTING
filename = p_flnme
filetype = 'DAT'
TABLES
data_tab = it_upload
EXCEPTIONS
OTHERS = 1.
IF sy-subrc <> 0.
MESSAGE i008 WITH 'File does not exist.'.
IF v_compflag IS INITIAL.
LEAVE TO TRANSACTION 'ZDCONTACT'.
ELSE.
LEAVE TO TRANSACTION 'ZDCONTACT'.
ENDIF.
ENDIF.
CHECK sy-subrc EQ 0.
DELETE it_upload
WHERE zaddress EQ space
AND zcperson EQ space
AND zcnumber EQ space.
SORT it_zts0001 BY kunnr ASCENDING cdseq DESCENDING.
SORT it_upload BY kunnr ASCENDING.
LOOP AT it_upload.
lv_kunnr = it_upload-kunnr.
AT NEW kunnr.
AVH - start of insertion - 06/30/06
SELECT SINGLE kunnr FROM zsoemailid
INTO lv_kunnr
WHERE kunnr = it_upload-kunnr.
if it_upload-kunnr is not found in table ZSOEMAILID, it will
not be included in the upload.
IF sy-subrc <> 0.
DELETE it_upload.
CLEAR it_upload.
CONTINUE.
ENDIF.
AVH - end of insertion
READ TABLE it_zts0001 WITH KEY kunnr = lv_kunnr.
IF sy-subrc EQ 0.
lv_seq = it_zts0001-cdseq.
ELSE.
CLEAR lv_seq.
ENDIF.
ENDAT.
IF it_upload-zaddress IS INITIAL.
MOVE-CORRESPONDING it_upload TO it_error.
APPEND it_error.
CLEAR it_error.
ELSE.
REPLACE '"' WITH '' INTO it_upload-zaddress.
REPLACE '"' WITH '' INTO it_upload-zaddress.
REPLACE '"' WITH '' INTO it_upload-zcperson.
REPLACE '"' WITH '' INTO it_upload-zcperson.
CONDENSE it_upload-zaddress.
CONDENSE it_upload-zcperson
ADD 1 TO lv_seq.
MOVE: it_upload-kunnr TO it_ztstemp-kunnr,
lv_seq TO it_ztstemp-cdseq,
it_upload-zaddress TO it_ztstemp-zaddress,
it_upload-zcperson TO it_ztstemp-zcperson,
it_upload-zcnumber TO it_ztstemp-zcnumber,
'X' TO it_ztstemp-zactivated,
sy-uname TO it_ztstemp-zcreated_by,
sy-datum TO it_ztstemp-zchanged_date.
MOVE-CORRESPONDING it_ztstemp TO it_ztstemp_gloc.
APPEND: it_ztstemp, it_ztstemp_gloc.
CLEAR: it_ztstemp, it_ztstemp_gloc.
ENDIF.
ENDLOOP.
IF NOT it_ztstemp[] IS INITIAL.
INSERT zts0001 FROM TABLE it_ztstemp.
INSERT zts_stpgeoloc FROM TABLE it_ztstemp_gloc.
WRITE:/ 'List of Records Uploaded.' COLOR 1 INTENSIFIED ON.
FORMAT COLOR 1 INTENSIFIED OFF.
WRITE:/(020) 'Dealer Code' CENTERED,
(007) 'Code' CENTERED,
(100) 'Address',
(030) 'Contact Person' CENTERED,
(018) 'Contact Number' CENTERED.
FORMAT COLOR OFF.
WRITE:/(179) sy-uline.
DESCRIBE TABLE it_ztstemp LINES lv_ctr.
SORT it_ztstemp BY kunnr cdseq.
LOOP AT it_ztstemp.
WRITE:/(020) it_ztstemp-kunnr,
(007) it_ztstemp-cdseq,
(100) it_ztstemp-zaddress,
(030) it_ztstemp-zcperson,
(018) it_ztstemp-zcnumber.
ENDLOOP.
SKIP 1.
WRITE:/ 'TOTAL :', lv_ctr.
ENDIF.
IF NOT it_error[] IS INITIAL.
SKIP 2.
FORMAT COLOR 1 INTENSIFIED OFF.
WRITE:/(020) 'Dealer Code' CENTERED,
(030) 'Contact Person' CENTERED,
(018) 'Contact Number' CENTERED.
FORMAT COLOR OFF.
WRITE:/(070) sy-uline.
DESCRIBE TABLE it_error LINES lv_ctr.
SORT it_error BY kunnr zcperson.
LOOP AT it_error.
WRITE:/ 'With No Address.' COLOR 6 INTENSIFIED ON.
WRITE:/(020) it_error-kunnr,
(030) it_error-zcperson,
(018) it_error-zcnumber.
ENDLOOP.
SKIP 1.
WRITE:/ 'TOTAL :', lv_ctr.
ENDIF.
ENDFORM. " Upload_file
*& Form add_record
FORM add_record.
v_title = ''.
IF NOT v_kunnr IS INITIAL.
SUBMIT zdealer_contacts_add_edit AND RETURN
WITH p_kunnr = v_kunnr
WITH p_name1 = p_name1 "AVH
WITH p_cdseq = space
WITH p_flag = 'A'
WITH p_addr = it_zts0001-zaddress
WITH p_pers = it_zts0001-zcperson
WITH p_numb = it_zts0001-zcnumber
VIA SELECTION-SCREEN.
ENDIF.
LEAVE TO TRANSACTION 'ZDCONTACT'.
ENDFORM. " add_record
*& Form edit_record
FORM edit_record.
v_title = ''.
READ TABLE it_zts0001 WITH KEY kunnr = v_kunnr
cdseq = p_code.
IF sy-subrc EQ 0.
SUBMIT zdealer_contacts_add_edit AND RETURN
WITH p_kunnr = v_kunnr
WITH p_name1 = p_name1 "AVH
WITH p_cdseq = p_code
WITH p_flag = 'E'
WITH p_addr = it_zts0001-zaddress
WITH p_pers = it_zts0001-zcperson
WITH p_numb = it_zts0001-zcnumber
WITH v_controller = v_compflag
VIA SELECTION-SCREEN.
ELSE.
MESSAGE i008 WITH 'No record found.'.
CALL TRANSACTION 'ZDCONTACT'.
ENDIF.
LEAVE TO TRANSACTION 'ZDCONTACT'.
ENDFORM. " edit_record
*& Form display_records
*FORM display_records.
IF NOT it_zts0001[] IS INITIAL.
v_title = 'List of Dealer Contacts'.
FORMAT COLOR 1 INTENSIFIED OFF.
WRITE:/(020) 'Customer Number' CENTERED,
(007) 'Code' CENTERED,
(100) 'Address',
(030) 'Contact Person' CENTERED,
(018) 'Contact Number' CENTERED.
FORMAT COLOR OFF.
WRITE:/(179) sy-uline.
SORT it_zts0001 BY kunnr cdseq.
LOOP AT it_zts0001.
WRITE:/(020) it_zts0001-kunnr,
(007) it_zts0001-cdseq,
(100) it_zts0001-zaddress,
(030) it_zts0001-zcperson,
(018) it_zts0001-zcnumber.
ENDLOOP.
ELSE.
MESSAGE i008 WITH 'No records to display.'.
ENDIF.
*ENDFORM. " display_records
*& Form display_alv
FORM display_alv.
SORT it_zts0001 BY kunnr cdseq.
PERFORM f_build_layout USING gs_layout.
PERFORM f_init_fieldcat USING gt_fieldcat[].
PERFORM f_init_events USING 'BACK' gt_events[].
g_repid = sy-repid.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = g_repid
i_callback_top_of_page = 'TOP_OF_PAGE'
i_callback_user_command = 'USER_COMMAND'
is_layout = gs_layout
it_fieldcat = gt_fieldcat[]
it_events = gt_events[]
i_save = 'X'
it_sort = gt_sort
TABLES
t_outtab = it_zts0001[]
EXCEPTIONS
program_error = 1
OTHERS = 2.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
ENDFORM. " DISPLAY_ALV
FORM top_of_page *
FORM top_of_page.
*ALV Header declarations
DATA: t_header TYPE slis_t_listheader,
wa_header TYPE slis_listheader,
t_line LIKE wa_header-info,
lv_title(60),
lv_user(60),
lv_date(10),
lv_time(10),
lv_time_n_date(30),
lv_dcode_n_name(150),
lv_dlr_n_desc(100),
ld_lines TYPE i,
ld_linesc(10) TYPE c.
Title
CLEAR: lv_title, wa_header.
MOVE sy-title TO lv_title.
wa_header-typ = 'H'.
wa_header-info = lv_title.
APPEND wa_header TO t_header.
CLEAR wa_header.
User
CLEAR: lv_user, wa_header.
CONCATENATE: 'Generated by:' sy-uname
INTO lv_user SEPARATED BY space.
wa_header-typ = 'A'.
wa_header-info = lv_user.
APPEND wa_header TO t_header.
CLEAR wa_header.
*Date and time
CLEAR: lv_date, lv_time.
WRITE: sy-datum TO lv_date MM/DD/YYYY,
sy-uzeit TO lv_time USING EDIT MASK '__:__:__'.
CONCATENATE: 'Generated on:' lv_date lv_time
INTO lv_time_n_date SEPARATED BY space.
wa_header-typ = 'A'.
wa_header-info = lv_time_n_date.
APPEND wa_header TO t_header.
CLEAR wa_header.
IF NOT v_kunnr IS INITIAL AND v_compflag IS INITIAL.
*Dealer code and name
CONCATENATE: 'Dealer:' p_dcode p_name1
INTO lv_dcode_n_name SEPARATED BY space.
wa_header-typ = 'A'.
wa_header-info = lv_dcode_n_name.
APPEND wa_header TO t_header.
CLEAR wa_header.
ENDIF.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
it_list_commentary = t_header.
ENDFORM. " TOP_OF_PAGE
FORM f_build_layout *
--> %LAYOUT *
FORM f_build_layout USING %layout TYPE slis_layout_alv.
%layout-zebra = 'X'.
%layout-colwidth_optimize = 'X'.
ENDFORM. " F_BUILD_LAYOUT
FORM f_init_fieldcat *
--> %FIELDCAT *
FORM f_init_fieldcat USING %fieldcat TYPE slis_t_fieldcat_alv.
DATA: lc_fieldcat TYPE slis_fieldcat_alv.
CLEAR lc_fieldcat.
DEFINE m_field.
add 1 to lc_fieldcat-col_pos.
lc_fieldcat-fieldname = &1.
lc_fieldcat-outputlen = &2.
lc_fieldcat-seltext_l = &3.
lc_fieldcat-do_sum = &4.
lc_fieldcat-inttype = &5.
lc_fieldcat-hotspot = &6.
lc_fieldcat-fix_column = &7.
lc_fieldcat-ddictxt = 'L'.
lc_fieldcat-no_zero = 'X'.
append lc_fieldcat to %fieldcat.
END-OF-DEFINITION.
IF v_kunnr IS INITIAL.
m_field 'KUNNR' '5' 'Dealer Code' '' '' '' ''.
ENDIF.
IF v_compflag = 'X'.
m_field 'KUNNR' '5' 'Dealer Code' '' '' '' ''.
ENDIF.
IF v_compflag = 'X'.
m_field 'NAME1' '40' 'Dealer Name' '' '' '' ''.
ENDIF.
m_field 'CDSEQ' '05' 'Ship-To Code' '' '' '' ''.
m_field 'ZADDRESS' '100' 'Address' '' '' '' ''.
m_field 'ZCPERSON' '30' 'Contact Person' '' '' '' ''.
m_field 'ZCNUMBER' '18' 'Contact Number' '' '' '' ''.
IF v_kunnr IS INITIAL.
m_field 'NAME1' '40' 'Dealer Name' '' '' '' ''.
ENDIF.
m_field 'ZACTIVATED' '1' 'Activated' '' '' '' ''.
ENDFORM. " f_init_fieldcat
FORM f_init_events *
--> P_TYPE *
--> %EVENTS *
FORM f_init_events USING p_type CHANGING %events TYPE slis_t_event.
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
i_list_type = 0
IMPORTING
et_events = %events
EXCEPTIONS
list_type_wrong = 1
OTHERS = 2.
IF sy-subrc = 0.
PERFORM f_build_events USING: slis_ev_user_command.
IF p_type = 'TOP'.
PERFORM f_build_events USING: gc_top.
ELSEIF p_type = 'SUM'.
PERFORM f_build_events_sum USING: gc_topsum.
ENDIF.
ELSE.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
ENDFORM. " F_INIT_EVENTS
FORM user_command *
--> P_UCOMM *
--> P_SELFIELD *
FORM user_command USING p_ucomm LIKE sy-ucomm
p_selfield TYPE slis_selfield.
CASE p_ucomm.
WHEN 'E'.
CALL SELECTION-SCREEN 500.
ENDCASE.
ENDFORM.
FORM f_build_events *
--> %EVENT *
FORM f_build_events USING %event.
READ TABLE gt_events WITH KEY name = %event.
IF sy-subrc = 0.
MOVE: %event TO gt_events-form.
MOVE 'USER_COMMAND' TO gt_events-form.
MODIFY gt_events INDEX sy-tabix.
ENDIF.
ENDFORM. " F_BUILD_EVENTS -
Help isn’t displaying because JavaScript is turned off.
You can enable JavaScript in your browser’s preferences or settings. Then refresh this page to try again.
I've followed instructions to remove problem, still exists, how do I get Iphoto to open?Option 1
Back Up and try rebuild the library: hold down the command and option (or alt) keys while launching iPhoto. Use the resulting dialogue to rebuild. Choose to Rebuild iPhoto Library Database from automatic backup.
If that fails:
Option 2
Download iPhoto Library Manager and use its rebuild function. This will create a new library based on data in the albumdata.xml file. Not everything will be brought over - no slideshows, books or calendars, for instance - but it should get all your albums and keywords back.
Because this process creates an entirely new library and leaves your old one untouched, it is non-destructive, and if you're not happy with the results you can simply return to your old one. .
Regards
TD -
Display results seperated by comma's
Hi
Just wondering if there was a way to display results from seperate rows in one text box where the results are seperated by comma's?
=First(Fields!ClientId.Value, "DataSet1")
The example above will just show one ClientId however I would like to list all of them all like below
C001,C002,C546,F546,H232
Am I after Lookup/LookupSet?
Any help appreciated.
Cheers
Cheers ChrisOne method is to create a hidden parameter ,make it allow Multiple values and set its default value to be same as dataset field value. Then you can simply use
=Join(Parameters!ParameterName.value,",")
Please Mark This As Answer if it helps to solve the issue Visakh ---------------------------- http://visakhm.blogspot.com/ https://www.facebook.com/VmBlogs -
Not to Display Result after Re voting in Quick poll
Hello Expert,
I have created an ivew of Km Quick Poll & Km Quick Poll Administration.
I dn't wan't to display result layout ( Flat pie / Flat Bar) after voting or re-voting...user can vote or re-vote but he must be unable to see result...
Please suggest the solution
Regards,
VidhanshiHi Vishal,
In the Quick Poll admin iview, make sure that you have started the poll.
Also check the Radio buttons for displaying the result.There are 3 options.
Select the one with either displaying the poll after users voted or displaying the poll after the poll is closed.
Hope it helps. -
Display result on center of the screen. Possible ?
Hello Experts,
I have created some output of string which displays result at runtime.
I want to dispaly this string in the center of the screen.
screen may be changable so my result should be display in center.
Is it possible ?
Please give me some idea.
Thanks in advance.
-rohanhi,
u can use system variables SY-CUCOL AND SY-CUROW . u can get the system variables in Standard database table SYST.
SY-CUCOL = 35.
SY-CUROW = 35.
WRITE: 'STRING'.
if helpful reward some points.
with regards,
Suresh Aluri -
Hi All,
I successfully installed OBIEE 10G on my machine and I am able to successfully login.
For the sanity testing, I tried to create reports in answers with 'Sample Sales' subject area.
This is created by OBIEE during installation.
The issue I am facing is that the 'Display Result' tab is showing any result. I can select facts and dimensions.
But when I click on 'Display Results' or Results tab, there is no activity.
Appreciate help from the experts.
RegardsThis seems to be problem of IE.
I was able to open report in Mozilla.
Thanks. -
Help on output Display
Thanks in Advance
ID ROUTE STRT_NAME BEGIN_DESCRIPTION END_DESCRIPTION OVERLAP BEG_MP END_MP Hierarchy
100899 CR ELM AVE EXT FUERA BUSH RD ELM AVE 1551 0 0.46 3
100899 CR ELM AVE ELM AVE RT 910A 1551 0.46 0.95 3
100899 CR ELM AVE ELM AVE DELMAR BYPASS 1551 0.46 0.83 3
100290 NY32 ELM AVE EXT RT 910A FEURA BUSH RD ELM AVE 1551 16.85 17.31 1
100290 NY32 ELM AVE ELM AVE DELMAR BYPASS 1551 17.31 17.68 1
My output will be Based on Hierarchy Max valuewhich is "3"
ID = Hierarchy Max value 3 =(100899)
ROUTE = Hierarchy Min Value which is "NY32"
STRT NAME = Hierarchy Max value (3) and Min of Beg_MP of Hierarchy Max value(3) = ELM AVE EXT
Begin Description = Hierarchy Max value (3) and Min of Beg_MP (0) of Hierarchy Max value(3) = FUERA BUSH RD
End_description =Hierarchy Max value (3) and Max of Beg_MP (0.95) of Hierarchy Max value(3) = RT 910A
Beg_MP = Hierarchy Max value (3) and Min of Beg_MP (0) of Hierarchy Max value(3) =0
end_mp = Hierarchy Max value (3) and Max of Beg_MP (0.95) of Hierarchy Max value(3) = 0.95
ID ROUTE STRT_NAME BEGIN_DESCRIPTION END_DESCRIPTION BEG_MP END_MP
100899 NY32 ELM AVE EXT FUERA BUSH RD RT 910A 0 0.95CREATE TABLE TABLE_query(ID NUMBER,ROUTE VARCHAR2(30),STR_NAME VARCHAR2(30), BEGIN_DESCRIPTION VARCHAR2(300),END_DESCRIPTION VARCHAR2(300),BEG_MP NUMBER,END_MP NUMBER,HIERARCHY NUMBER,overlap number);
INSERT INTO TABLE_query(ID ,ROUTE,STR_NAME, BEGIN_DESCRIPTION,END_DESCRIPTION,BEG_MP,END_MP ,HIERARCHY,overlap)
values(100899,'CR','ELM AVE EXT','FUERA BUSH RD','ELM AVE',0,0.46,3,1551);
INSERT INTO TABLE_query(ID ,ROUTE,STR_NAME, BEGIN_DESCRIPTION,END_DESCRIPTION,BEG_MP,END_MP ,HIERARCHY,overlap)
values(100899,'CR','ELM AVE','ELM AVE','DELMAR BYPASS',0.46,0.95,3,1551);
INSERT INTO TABLE_query(ID ,ROUTE,STR_NAME, BEGIN_DESCRIPTION,END_DESCRIPTION,BEG_MP,END_MP ,HIERARCHY,overlap)
values(100899,'CR','ELM AVE','ELM AVE','DELMAR BYPASS',0.46,0.83,3,1551);
INSERT INTO TABLE_query(ID ,ROUTE,STR_NAME, BEGIN_DESCRIPTION,END_DESCRIPTION,BEG_MP,END_MP ,HIERARCHY,overlap)
values(100290,'NY32','ELM AVE EXT','RT 910A FEURA BUSH RD','ELM AVE',16.85,17.31,1,1551);
INSERT INTO TABLE_query(ID ,ROUTE,STR_NAME, BEGIN_DESCRIPTION,END_DESCRIPTION,BEG_MP,END_MP ,HIERARCHY,overlap)
values(100290,'NY32','ELM AVE','ELM AVE','DELMAR BYPASS',17.31,17.68,1,1551);
ID ROUTE STR_NAME BEGIN_DESCRIPTION END_DESCRIPTION BEG_MP END_MP HIERARCHY OVERLAP
100899 CR ELM AVE EXT FUERA BUSH RD ELM AVE 0 0.46 3 1551
100899 CR ELM AVE ELM AVE DELMAR BYPASS 0.46 0.95 3 1551
100899 CR ELM AVE ELM AVE DELMAR BYPASS 0.46 0.83 3 1551
100290 NY32 ELM AVE EXT RT 910A FEURA BUSH RD ELM AVE 16.85 17.31 1 1551
100290 NY32 ELM AVE ELM AVE DELMAR BYPASS 17.31 17.68 1 1551
My output will be Based on Hierarchy Max valuewhich is "3"
ID = Hierarchy Max value 3 =(100899)
ROUTE = Hierarchy Min Value which is "NY32"
STRT NAME = Hierarchy Max value (3) and Min of Beg_MP of Hierarchy Max value(3) = ELM AVE EXT
Begin Description = Hierarchy Max value (3) and Min of Beg_MP (0) of Hierarchy Max value(3) = FUERA BUSH RD
End_description =Hierarchy Max value (3) and Max of Beg_MP (0.95) of Hierarchy Max value(3) = DELMAR BYPASS
Beg_MP = Hierarchy Max value (3) and Min of Beg_MP (0) of Hierarchy Max value(3) =0
end_mp = Hierarchy Max value (3) and Max of Beg_MP (0.95) of Hierarchy Max value(3) = 0.95
ID ROUTE STRT_NAME BEGIN_DESCRIPTION END_DESCRIPTION BEG_MP END_MP
100899 NY32 ELM AVE EXT FUERA BUSH RD DELMAR BYPASS 0 0.95
I figured out how to get id,beg_mp and end_mp
Can anyone help me getting the rest of data coumns please
--route,str_name,begin_description,end_description,beg_mp,end_mp,hierarchy,
select distinct max(id) keep (dense_rank last order by hierarchy) over (partition by overlap) ,
min(beg_mp) keep (dense_rank last order by hierarchy) over (partition by overlap) beg_mp,
max(end_mp) keep (dense_rank last order by hierarchy) over (partition by overlap) end_mp
from table_query -
I used to have an icon on my menu bar at the top of my screen to help me detect displays (monitors) It has disappeared and I don't know how to get it back. Does anyone know?
Your's may look more like this...
...if you're running Mountain Lion. I'm in clamshell mode right now, so I don't have any mirroring options. AFAIK, there's no more "Show displays in menu bar" in Mountain Lion.
Clinton
Maybe you are looking for
-
Product weight (intrastat)
Hi, We have to do Intrastat -reporting for foreign vendors. One of the elements that needs to be reported is weight of orders. We are using a requisite's catalogs and I guess we need to maintain weights for the products in the catalog to be able to r
-
Purchase order goods receipt and Invoice receipt difference not appearing in MR11
-
Does the Digital Publishing Suite publishes only for tablets? can I publish my indesign file to html only using DPS?
-
Hi, I've prepared a very simple JApplet (that implements a MouseListener) which should do the following: 1) When the user clicks on it, it should play an audio clip (.au format), 2) When the user hovers over it, it should display a tooltip. The toolt
-
OS update deleted my SMTP settings
I updated the OS on my 3GS about two weeks ago and find that I'm unable to send mail. When I examined the server setting I found that all of my former SMTP settings were gone. Mail now comes in, but won't go out. I've tried to re-enter the SMTP se