bpanda
8th May 2012, 08:47
hi can u pls help me how to use read.text().
Actually i want to show the text of tcibd001(item general) in a customized session.
can u please suggest me.
bdittmar
8th May 2012, 10:24
hi can u pls help me how to use read.text().
Actually i want to show the text of tcibd001(item general) in a customized session.
can u please suggest me.
Hello,
read the text from table tttxt010
e.g.
select tttxt010.*
from tttxt010
where tttxt010._index1 = tcibd001.txta
.........
Regards
bpanda
9th May 2012, 08:22
Thanx,
but I want to use read.text() function or anything that will work like reference as I have the Item in my customized Table.
andreas.toepper
9th May 2012, 09:17
Your profile says you're using Baan IV, but table tcibd001 is of ERP5 or LN.
If you're using LN you may wan't to edit or show the text of the textfield on the form (that's now a standard-functionality in LN).
If you insert tcibd001.txta in a maintenace-session, you can specify the width and the high of the used textedit-field (check "Display" in the field-properties).
If you do need to access textdata in a script, take a look at solution 22924522. There you can download the latest programmers guide. Download this guide and check the syntax of the text.xxxxx functions (i.e. text.read, text.write, text.to.buf). You can export/import baan/ln-texts into/from a textfile or copy the textlines into a string-array.
Kind regards
Andreas
bdittmar
9th May 2012, 10:19
Thanx,
but I want to use read.text() function or anything that will work like reference as I have the Item in my customized Table.
Hello,
i think you mean :
text.read()
Syntax:
function long text.read (string text_field, string lang, string kw1, string kw2, string kw3, string kw4, ref string tgroup, ref string edit_opt, string tmp_file, long lock [, string rtf_file])
Description
This reads a specified text and stores it in a temporary file.
Arguments
string text_field The name of the text field that must be read. See Text fields overview.
If the text number of the specified field is 0, a subprocess is started, which lists the texts associated with the current company and enables the user to select the text to be read.
If no text is found, or if you abort the subprocess, text_field returns 0. Otherwise, it returns the text number of the retrieved text.
string lang The language for which the text must be retrieved.
string kw1 These return the key words associated with the specified text.
string kw2
string kw3
string kw4
ref string tgroup This returns the name of the text group to which the text is assigned.
ref string edit_opt This returns the default window type for the text.
string tmp_file The name of the file in which the text must be stored. If this is an empty string, no text is retrieved and the function returns 0.
long lock By default, a lock is applied to the text field when it is read. To read the field without lock, set this argument to 0.
[string rtf_file ] The name of the file in which the RTF version of the text must be stored. This is an optional argument. The usage of this argument depends on the settings of the text group as defined in the tgroup argument. If this is an empty string, no text is retrieved and the function returns 0.
Return values
>0 success; returns the number of lines read
0 no text found or subprocess aborted
-1 no permission
Context
This function can be used in all script types.
Regards