Text Output as Separate Lines
I have this code:
tell application "iTunes"
set playlistList to name of user playlists
end tell
You can also use AppleScript's text item delimiters. You didn't mention what you were going to do with the information, so I included a choose from list dialog, which will also show the items:
<pre title="this text can be pasted into the Script Editor" style="font-family: Monaco, 'Courier New', Courier, monospace; font-size: 10px; padding: 5px; width: 720px; color: #000000; background-color: #E0E0E0; overflow: auto">tell application "iTunes"
set MyList to (name of user playlists) -- get a list
-- convert the list to a string using a return character to delimit each item
set {TempTID, AppleScript's text item delimiters} to {AppleScript's text item delimiters, return}
set MyString to MyList as string
set AppleScript's text item delimiters to TempTID
-- show both results:
choose from list MyList with title "List" with prompt "" with empty selection allowed
display dialog MyString with title "String"
end tell
</pre>
G4 Digital Audio 1.4GHz Mac OS X (10.4.10)
Similar Messages
-
Exporting remarks on separate lines
The customer has lines of remarks in their item master data records. They wish to export these
reports into Excel using a query.
When they do, the remarks appear as one long line instead of separate lines. Is there a way of
exporting this information to any type of format (e.g excel, word, notepad) so that the remarks show
with carriage returns so the text is on separate lines?
Thanks,
KateThe answer probably depends on what you want to do with the data once it reaches Excel.
I think that it would be difficult to do with SQL Query & export to Excel because I am not aware of any features in SQL to chop block text into lines of a particular size, but what about just wrapping the column in Excel once it's there?
If you really need it as separate rows in Excel, then I think that you would need to go via some other product which would do the line splitting for you. The Crystal viewer which we use in Business One allows export to Excel, and Crystal will handle the line splitting.
Regards,
Douglas -
How to align output formatted and output text in the same line?
Hi All,
I want an output formatted label and a text on the same line,. I've surrounded these components wth a panel form layout and they automatically align one below the other. how do I kepe them in the same line?
Thanks.Try as per the code snippet below:
<af:document title="TestPage.jspx" id="d1">
<af:messages id="m1" inline="true"/>
<af:form id="f1">
*<af:panelGroupLayout id="pgl1" layout="horizontal">*
*<af:outputFormatted value="outputFormatted1" id="of1"/>*
*<h:outputText value="outputText1" id="ot1"/>*
*</af:panelGroupLayout>*
</af:form>
</af:document>
Thanks,
Navaneeth -
Nested tables as separate lines in output
I'm working with Adobe forms using transaction SFP from the ABAP Workbench. I'm trying to construct a prototype of an SD invoice, with one internal table having the basic item data, and then a secondary table with further information, such as discounts, taxes, etc. The item number is part of both tables so that they can be related to each other. Using right-click and Create in the context I constructed a loop on the main table, and then under that a loop on the secondary table, with the equal item number as a condition. It all works, but in the output the secondary data comes out on the same line as the main item data, and when I try to drag it down to the next line in the layout, it changes its position in the data view also, so that it's outside the loop and prints only once, over the second main item line. Surely for an invoice or a purchase order it's normal to have one basic item line, and then one or more other lines with various other information for each item. It's very easy in both SAPscript and Smart Forms to have a loop within a loop displaying separate lines, but so far I haven't been able to get it to work with Adobe.
Oracle Database 10g Enterprise Edition Release 10.1.0.2.0 - 64bit Production
With the Partitioning, OLAP and Data Mining options
SQL> CREATE OR REPLACE TYPE table_type AS TABLE OF VARCHAR2 (8);
2 /
Type created.
SQL> CREATE TABLE r(
2 a INTEGER,
3 b table_type)
4 NESTED TABLE b STORE as b_1;
Table created.
SQL> CREATE TABLE s(
2 a INTEGER,
3 b table_type)
4 NESTED TABLE b STORE as b_2;
Table created.
SQL> INSERT INTO r VALUES (1, table_type ('a', 'b'));
1 row created.
SQL> INSERT INTO s VALUES (1, table_type ('b', 'c'));
1 row created.
SQL> COLUMN c FORMAT A10;
SQL> SELECT r.a, r.b MULTISET UNION DISTINCT s.b c
2 FROM r, s
3 WHERE r.a = s.a;
A C
1 TABLE_TYPE('a', 'b', 'c')
SQL> -
Display multiple choice column selections on a separate line in the body of email
This question could have been answered elsewhere and I just don't realize it. I have a SharePoint Foundation 2010 form (11 columns) that has one choice column allowing the user to select multiple options (checkboxes). The selections have been typed into "type each choice on a separate line". Moving to Designer we have created a workflow that sends an email when the user submits to form.
If Current Item: Select shift equals DAY request Email ................
The body of the email has this field:
Information Being Requested: [%Current Item: The following information is being requested%].
When the user gets the email the output for this field is string on a single line separated by a comma. What I need is each of the selections to be on a separate line so the users can easily read what is being requested and not miss any of the selection. I'm stuck. I'm not worried about text wrapping. I've been searching for hours but either it's not what a need, it's over my head, or I just don't know where to make the changes. I don't use VS but I do know html and I'm fairly comfortable in Designer. I would appreciate any help.Firstly, can you edit your post and take the question out of the code / quote box. It'll make it easier to read.
Secondly the options depend on the version of SharePoint. Are we to assume you're using SharePoint 2003 or 2007 as you've posted into the legacy forums?
Steven Andrews
SharePoint Business Analyst: LiveNation Entertainment
Blog: baron72.wordpress.com
Twitter: Follow @backpackerd00d
My Wiki Articles:
CodePlex Corner Series
Please remember to mark your question as "answered" if this solves (or helps) your problem. -
Displaying Information selected within a Checkbox Choice column on a separate line
I am looking to change the display output of a Choice column, which has checkboxes enabled for multiple selections, to show on Separate lines.
At the moment when more than one box is selected the data is separated by a comma
JRHi Treble99,
There is not an OOB way to implement displaying multiple values with separate lines. As the values are separated by a comma, you can replace the comma with break line.
Here are some posts for your reference:
http://stackoverflow.com/questions/16208081/comma-separated-string-to-linebreak
http://social.msdn.microsoft.com/Forums/sharepoint/en-US/9a58177f-f135-492b-97df-c6c70086c2d3/sharepoint-designer-show-line-break-for-multi-text-plain-text?forum=sharepointcustomizationlegacy
I hope this helps.
Thanks,
Wendy
Wendy Li
TechNet Community Support -
I have a labview sub-VI reading the string being outputted by a pH meter. The meter outputs a 5 line string and labview is only reading up to each lines carriage return, there-by giving me 5 separate strings is there anyway to rectify this and have the 5 line read as one string?
NAS1
St Petersburg FL
Labview 2010Yes, LabVIEW will automatically update. What happens is that the old serial functions still exist in 7.1 and above but the code (the block diagram) has been modified to use VISA functions. Older versions of LabVIEW are fully supported in this manner. The only way you can avoid the automatic update is to have the old serial functions in an llb and your top level VI refer to these. Having any VI that was part of vi.lib in an llb is a very bad idea and the way to fix things is to remove any VIs in the llb that are part of the LabVIEW distribution.
I don't remember how the old serial config worked and what the new version does with the VISA Configure Serial Port. Your program should only have a single serial config and you might just be able to directly replace that with the VISA configure Serial Port. -
SAPScript: How to combine two text in the same line?
Dear Gurus,
I have a case to combine hard code text and long text in the same line.
For example, i need to display following line:
'Project name:' <long_text>
How to do it in SAPScript?
Can we do it with following code?
/: 'Project name: ' INCLUDE Z_TEST OBJECT TEXT ID ST LANGUAGE &NAST-SPRAS&
Thanks & Regards,
AriHi,
You can achieve that by this method,
Goto Tcode SO10
Give the Object Name 'Z_TEST' & Id
See the Paragraph format for the Text, you can do it from Menu
Format>Line . If it is /: change it to =. Save
Now in the SAPScript Text editor in which you want to print
P1 'Project Name :'
/: INCLUDE Z_TEST OBJECT TEXT ID ST LANGUAGE &NAST-SPRAS&
the output will be
Project name : Abc xyz
Regards
Bala Krishna.
Edited by: Bala Krishna on Oct 17, 2008 7:11 PM -
How to add the line item text in the Ledger line item report
Hi SAP Gurus,
I having one requirement from the user. He wants the line item text which we will enter in FB60/FB70/FB50 has to be shown in the Ledger line item report. Right now this field is not available. Is there any possible we can make this line item text in the ledger line item report i.e. FBL1N/FBL3N/FBL5N?
advance thanks for the help.
Regards,
Deva.Hi,
You can do the below to get this. (You can change the names of the function modules as per your wish/ organization naming convention):-
Step 1:-
Create function module Z_GET_SGTXT as below:-
Import:-
BELNR LIKE BKPF-BELNR
BUKRS LIKE BKPF-BUKRS
BUZEI LIKE BSEG-BUZEI
GJAHR LIKE BKPF-GJAHR
Export:-
PRCTR LIKE BSEG-SGTXT
FUNCTION Z_GET_SGTXT.
""Local Interface:
*" IMPORTING
*" VALUE(BELNR) LIKE BKPF-BELNR
*" VALUE(BUKRS) LIKE BKPF-BUKRS
*" VALUE(BUZEI) LIKE BSEG-BUZEI
*" VALUE(GJAHR) LIKE BKPF-GJAHR
*" EXPORTING
*" VALUE(SGTXT) LIKE BSEG-SGTXT
SELECT SINGLE SGTXT FROM BSEG INTO SGTXT WHERE GJAHR = GJAHR
AND BELNR = BELNR
AND BUKRS = BUKRS
AND BUZEI = BUZEI.
ENDFUNCTION.
Step 2:-
Then create the Function Modules as below:-
Z_LINE_ITEMS_GET_SGTXT (Copy of SAMPLE_INTERFACE_00001650)
FUNCTION Module Z_LINE_ITEMS_GET_SGTXT.
""Local Interface:
*" IMPORTING
*" VALUE(I_POSTAB) LIKE RFPOS STRUCTURE RFPOS
*" EXPORTING
*" VALUE(E_POSTAB) LIKE RFPOS STRUCTURE RFPOS
Initialize Output by using the following line
E_POSTAB = I_POSTAB.
E_POSTAB = I_POSTAB. "<-- important
CALL FUNCTION 'Z_GET_SGTXT'
EXPORTING
BELNR = I_POSTAB-BELNR
BUKRS = I_POSTAB-BUKRS
BUZEI = I_POSTAB-BUZEI
GJAHR = I_POSTAB-GJAHR
IMPORTING
SGTXT = E_POSTAB-SGTXT
EXCEPTIONS
OTHERS = 1.
ENDFUNCTION.
Step3:-
Transaction FIBF:-
Settings -> Products -> of a Customer
SGTXT Text in Line Item Display Active
Settings -> P/S Module -> of a Customer
00001650 SGTXT Z_LINE_ITEMS_GET_SGTXT
Step 4:-
Create the layout for FBL*N with display of the TEXT.
Regards,
Gaurav -
How to get the Hardcoded text and the Standard text in the same line
Hi,
I have an SAP Layout. In that, it should show the Consignee name as below.
Consignee: SAP LABS
In this, the text 'Consignee: ' should be hardcoded in the layout itself. and the customer has requested to create a standard text for 'SAP LABS' sothat if they want to change the value in future, they would go and change the Standard text. I have created the Standard Text for SAP LABS. I am not able to get both these texts on the same line. I wrote in the layout like below and AS is the Paragraph format.
AS Consignee:
/: INCLUDE ZVRU_CONSIGNEE OBJECT TEXT ID ST LANGUAGE EN PARAGRAPH 'AS'
But, both are coming in dofferent lines. As /: is a command line, it is coming in the next line. Is there any way of getting these two texts in the same line..? While Inserting the Standard Texts, will there be any option/command to print it in the same line..?
Please share your thoughts. Thanks in advance.
Thanks & Regards,
Paddu.Hi Paddu,
I have had a similar requirement. I did not use any FM or anything, simply did the following:
In SO10, for your standard text where u have used the text SAP LABS.
Instead of P1/ default para, change it to =. And then Save ur Standrd text.
Now in the SAPScript Text editor in which you want to print
P1 'Consignee :'
/: INCLUDE TEST OBJECT TEXT ID ST LANGUAGE EN
the output will be
Consignee : SAP LABS
I have tried and tested this method. It will surely work.
With regards,
Niharika. -
I need to convert PDF to Excel, however, columns and tabs make many merged cells and many blank columns. In addition to not separate the columns correctly, I see many not separate lines together in the same cell. I'm even thinking that Adobe Acrobat Pro DC has limitations. There is no way to define what points in columns to force break column? Nor create many columns that are useless? How does text to column in Excel, fixed size when we import text, and define where the breaks have columns?
Google Tradutor para empresas:Google Toolkit de tradução para appsTradutor de sitesGlobal Market Finder
Desativar tradução instantâneaSobre o Google TradutorCelularComunidadePrivacidade e TermosAjudaEnviar feedbackPDF does not contain columns, rows, formats, styles, or other aspects of word processing or spreadsheet file formats.
This is because PDF is decidedly not a word processing or spreadsheet file format or something "like" one of those.
(see ISO 32000 for what PDF "is")
What can optimize the export of PDF page content is to start with a well-formed tagged PDF (ISO 14289-1, PDF/UA-1 compliant).
Without that export is what it is and one performs whatever content cleanup is needed using the native application for the export file (MS Word or Excel).
Be well... -
Generating TEXT output from RTF template/reports
Hi ,
We have been working with XML Publisher for a long time now.. and we have come across some requirements such as
1. Page break in TXT report output
2. Page Headers after every 'X' lines in TEXT output.
This was easily achieved with RTF template and PDF/HTML/RTF output, but not with TEXT output in eTEXT template.
So we started looking into two approaches
1. Generate TXT from PDF/RTF/HTML output(generated from RTF template), though it will addon to the time, but we are looking for this approach. We are looking for some JAVA api's which can help us to extract text from PDF/HTML/RTF while preserving the format.
2. Pass the TXT generated by eTEXT template to our custom util , which will split the report in diff. pages.This will get complex as we recieve more and more reports.
We have also tried hacking the RTF parser used in XML P so as to get a TXT output or using XSL-FO objects in eTEXT parser, but we could not get anything of our help.
Does anyone have any pointers in this.
regards
GauravYou can burst with eText and I have done it
successfully.
I don't believe pagebreaks are an option in eText and
I don't think it makes sense either since your
generating a flat-file and not a customer or internal
facing document. Does that make sense?
Also, if you would like you can use the
BIPublisherIDE, this code can be converted pretty
easily to handle jcp. There is a an oa framework
version I have developed but I haven't posted on my
blog yet. I plan on adding a bolt on for java
concurrent programs soon. it's really pretty simple
just haven't had the time.
http://bipublisher.blogspot.com/2008/03/bi-publisher-b
ipublisheride.html
Ike Wiggins
http://bipublisher.blogspot.com
Thanks Ike for your reply.
I agree with your points on TXT files, but in our case,the reports are generated in TXT format for the customer so we are looking for the above mentioned features.
I have gone through BIP IDE and its a wonderful small utility which eases the task of BIP development.
As I mentioned in my original post that we are currently processing the generated TXT report using a custom util. in JAVA to get the desired output in TXT again.
I assume thats not what a JCP would do,so I am looking to explore that too.
As I understand the process for report generation is
1. Generate XSL from eTEXT template.
2. Get the XML data from DB using XDO
3. Apply XSL on XML to get the required template.
If we are looking to achieve some customizations then we need to have the XSL generated with those customizations.
In this case, where do we plug in the JCP to alter XSL or am I missing something.
regards
Gaurav -
Executing a native process and getting the text output
Hi,
I have the following problem.
When I execute a native DOS process (lets say a batch file), and
expect some text output from this process I use the following code:
String command = "test.bat";
Process process = runtime.exec(command);
BufferedReader rd = new BufferedReader(new InputStreamReader(process.getInputStream()));
String s = new String();
while((s = rd.readLine())!=null) {
out.println(s + "<br/>" );
The problem is that as long as rd.readLine() does not return null, the page does not display the result. When the process crash, sometimes nothing return.
I would like to display the output as it comes, i.e. line by line.
I have no clue on how to do that except writting the output in a text file, and reading the text file with a page that reload every x seconds.
I do not beleive this is a good solution.
Additionaly, I may have a huge output. It seems to make the process
to hang. Is there a was to fix it.
Could someone give me some hints.
Regards,
Arnaud.I am having the same problem...did you ever solve it?
-
Same sql statement gives output in different lines in 12.1.3 vs 11i
Hi all,
DB:11.2.0.3.0
EBS:11i and 12.1.3
O/S: Solaris SPARC 64 bits 5.10
The below query gives the output in one line in 11i as expected but it gives the output in two separate lines in 12.1.3. Are there any server level settings for linesize and pagesize to be performed?
set term off;
set serveroutput on size 1000000;
set feedback off;
set pagesize 0;
set head off;
set linesize 72;
set pause off;
set colsep '';
select
lpad(code_combination_id,15,0)||
rpad(to_char(start_date_active,'YYYYMMDD'),8,' ')||
rpad(to_char(end_date_active,'YYYYMMDD'),8,' '),
substr(SEGMENT1,1,3)|| --entity
rpad(substr(SEGMENT2,1,6),6,' ')|| --account
rpad(substr(SEGMENT3,1,5),5,' ')|| --costcenter
rpad(substr(SEGMENT4,1,6),6,' ')|| --activity
substr(SEGMENT6,1,3)|| --product
substr(SEGMENT7,1,3)|| --service
substr(SEGMENT5,1,3)|| --country
substr(SEGMENT8,1,3)|| --intercompany
rpad(substr(SEGMENT9,1,8),8,' ')|| --regional
substr(enabled_flag,1,1) -- active flag
from gl_code_combinations
where last_update_date >=
(select nvl(max(actual_start_date),'01-JAN-1951')
from fnd_concurrent_requests
where concurrent_program_id = (select concurrent_program_id
from fnd_concurrent_programs
where
concurrent_program_name = 'XYZACCT')
and status_code = 'C'
and actual_completion_date is not null)
order by 1;
OUTPUT in 11i
============
00000000000100020120930 7014912000000000000000000000000000000000Y
00000000000100120120930 5014912000000000000000000000000000000000Y
OUTPUT in 12.1.3
==============
00000000000116020120930
4881124010000000000000000000000000000000Y
000000000001161
6103229990000000000000000000000000000000Y
11i and 12.1.3 should get the output in one line as per the above sql statement.
Could anyone please share the fix on the above issue?
Thanks for your time
Regards,Hi,
Can you confirm in what session are you running this query.
Try this
Column Code_Date_Range format a25
Column Segments format a50
set lines 300
set pages 200
set term off;
set serveroutput on size 1000000;
set feedback off;
set pagesize 0;
set head off;
set linesize 72;
set pause off;
set colsep '';
select
lpad(code_combination_id,15,0)||
rpad(to_char(start_date_active,'YYYYMMDD'),8,' ')||
rpad(to_char(end_date_active,'YYYYMMDD'),8,' ') Code_Date_Range,
substr(SEGMENT1,1,3)|| --entity
rpad(substr(SEGMENT2,1,6),6,' ')|| --account
rpad(substr(SEGMENT3,1,5),5,' ')|| --costcenter
rpad(substr(SEGMENT4,1,6),6,' ')|| --activity
substr(SEGMENT6,1,3)|| --product
substr(SEGMENT7,1,3)|| --service
substr(SEGMENT5,1,3)|| --country
substr(SEGMENT8,1,3)|| --intercompany
rpad(substr(SEGMENT9,1,8),8,' ')|| --regional
substr(enabled_flag,1,1) Segments -- active flag
from gl_code_combinations
where last_update_date >=
(select nvl(max(actual_start_date),'01-JAN-1951')
from fnd_concurrent_requests
where concurrent_program_id = (select concurrent_program_id
from fnd_concurrent_programs
where
concurrent_program_name = 'XYZACCT')
and status_code = 'C'
and actual_completion_date is not null)
For more details, please see:
Formatting SQL*Plus Reports
Thanks &
Best Regards -
How can I conditionally change text output?
Trying to modify text output, inline, based on a True|False condition
i.e.:
"the condition is: <condition>" should become
"the condition is: Yup" or "the condition is: Badboy"
I'm trying to use some inline code. for example: "{if ($condition) {"Yup"} else {"Nope"}}" but can't seem to get it to work.
cls
$condition=$true
if ($condition) {"Yup"} else {"Nope"} #this actually provides the proper output, but I can't seem to integrate it to the complete string output.
#the following line does not provide the proper result.
"Test string " + ({if ($condition) {"Yup"} else {"Nope"}}) +"."Hi Murdan,
In addition, add some explanations to the methods above, we could use the “dollar sign + round brackets” and the expression in the brackets in double-quoted strings, whatever is in
the brackets should be evaluated first.
For more detailed information, please check this article:
PowerShell - Special Characters And Tokens:
http://www.neolisk.com/techblog/powershell-specialcharactersandtokens
For more detailed information about the format operator “-f”, please refer to this article:
about_Operators:
http://technet.microsoft.com/en-us/library/hh847732.aspx
If you have any feedback on our support, please
click here.
Best Regards,
Anna Wang
TechNet Community Support
Maybe you are looking for
-
Problems with decimal places and formatting
Hi , we are having problems with an add on running on different localization companies. Decimal places separatd by "," differ from other localizations. We dont know if this is a SQL collation setting or somethng related to code or requirements to run
-
Hi, Does following command ONLY helpful in level 1 incremental? RMAN>CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 30 DAYS; I want to configure to have 30 days backup must be available on tape.I also have policy anually to have tape backup and sen
-
Nokia C7 duplicate CITIES on two memories?
I've just got a new C7 replacing a 5800XM, and I stuck with Nokia largely because of the free satnav which is very useful. On the 5800 the CITIES folder was on the memory card, and when I got the C7 I transferred the memory card too. Then I install
-
ABAP WD, Multiple Row selection in table control
Hi all, I am populating and displaying the records using the table control, i have to select the multiple records in the list and want do some deletion,selection,so i could not select the more than one record. How do i solve this? Please give
-
Need the Details About ABAB and Netviewer.
Hi All, One of my friend is working in JAVA.. And he want study ABAB and Netviewer. Please provide any websites or books to study MP