View previous topic :: View next topic
|
Author |
Message |
mjadwani2785
New User
Joined: 28 Apr 2009 Posts: 89 Location: Noida , Dublin
|
|
|
|
Hi,
TBCREATE tablename keys names
variables defined in names is 8byte restricted. Is there any way I can overcome this restriction?
eg: i want to display pefix-notification.html
but it displays pe-fixnot.
Please help |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10873 Location: italy
|
|
|
|
Quote: |
variables defined in names is 8byte restricted. Is there any way I can overcome this restriction? |
sorry to disillusion You but the rules are the rules...
You will have to resort to some good mangling of the names, and to write comments in your code
but after rereading Your post the pefix-notification.html does not look as a proper ISPF variable name,
and what You are experiencing looks more like a data truncation issue!
if the dialog is written in REXX You will not have to worry about the variables content ( the content and length is variable dynamic )
if You write in a <higher level> (*) language then You will have to ensure that the lengths are corrects ( declarations and Vdefines)
(*) they might be higher level, but rexx is orders of magnitude smarter! |
|
Back to top |
|
|
mjadwani2785
New User
Joined: 28 Apr 2009 Posts: 89 Location: Noida , Dublin
|
|
|
|
Quote: |
pefix-notification.html does not look as a proper ISPF variable name, |
pefix-notification.html is not a variable..its the value the variable defined in name will contain...but my problem is its ending with pefixnot..is there any logic I can apply to prevent this truncation? |
|
Back to top |
|
|
PeterHolland
Global Moderator
Joined: 27 Oct 2009 Posts: 2481 Location: Netherlands, Amstelveen
|
|
|
|
mjadwani2785 wrote: |
Hi,
TBCREATE tablename keys names
variables defined in names is 8byte restricted. Is there any way I can overcome this restriction?
eg: i want to display pefix-notification.html
but it displays pe-fixnot.
Please help |
No.
It is not a restriction. It is a design.
You can always ask IBM to change their design. If you do, let us know the response. |
|
Back to top |
|
|
mjadwani2785
New User
Joined: 28 Apr 2009 Posts: 89 Location: Noida , Dublin
|
|
|
|
I am trying to create to display all the files of the hfs path on the ispf panel (not ishell) but similar view like ishell..
ishell view is
Type Filename
_ Dir .
_ Dir ..
_ File manoj
_ File pe-fix_notification.html
_ File samjcl.txt
_ File uk57310.zip
but my view is
SEL Description
_ manoj
_ pe-fix_notif
_ samjcl.txt
_ uk57310.zip
if you can see pe-fix_notif is getting truncated..
now the problem can be where?? As I have jst realised that names variable is storing full pe-fix_notification.html while in display its showing pe-fix_notif only.. |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
What you are trying to do is really unclear at this point.
Please post the code to (a) Build your table, (b) Display your table.
Maybe we can get a better idea of what you want to do and how your code looks. |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
All I can add to this is that the ISPF variable name must be 8 characters or less. The actual content of the variable can be considerably larger. |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10873 Location: italy
|
|
|
|
if Your variable content is not displayed properly, check the length in the panel definition!
by the way You talk about 8 bytes ... but You show that You are able to display 12 bytes! and in Your first post the example showed 9 bytes!
a bit of counting problems... I suppose
no reason to be upset... yes Your initial post had a confusing terminology.. |
|
Back to top |
|
|
mjadwani2785
New User
Joined: 28 Apr 2009 Posts: 89 Location: Noida , Dublin
|
|
|
|
code goes like this
/***for reading the files in the path **/
Parse Arg Passed_path
Call Setup
Call Syscalls 'ON'
Address SYSCALL
"readdir" Passed_path stem1 stem2
Do i = 1 to dirlist.0
If left(dirlist.i,1) = '.' Then Iterate
If dirlista.i.ST_TYPE <> S_ISDIR Then Do
p=p+1
PickFrom.p = dirlist.i
End
End
PickFrom.0=p
/**for building the table **///
Address ISPEXEC
"TBCREATE FILLIST
KEYS(TKEY)
NAMES(TNAME) NOWRITE"
sel_start = 0
Do i = 1 to PickFrom.0
Parse var PickFrom.i Tname
Tkey = i
"TBADD FILLIST"
If tname = ' ' then sel_start = i
End
"TBTOP FILLIST"
/**for displayin the table **/
Title = 'Description'
Info = 'Displayed for Selection from ' Passed_path
Do until rc ¬= 0
"TBDISPL FILLIST PANEL(sel@List)"
if tsel = 'S' Then Do
If tkey > sel_start then leave
End
End
"TBCLOSE FILLIST"
If tsel = ' ' Then picked = ' '
Else picked = strip(tname)
say picked
/* Call $setmsg , 'Sorry File Selection - not available.',
'Under development'
MyRC = 4 */
Adieu :
Return(MyRC)
Setup :
stem1='dirlist.'
stem2='dirlista.'
p=0
MyRc = 0
Return |
|
Back to top |
|
|
Pedro
Global Moderator
Joined: 01 Sep 2006 Posts: 2547 Location: Silicon Valley
|
|
|
|
Since the question is about displaying the information, show us your panel. |
|
Back to top |
|
|
mjadwani2785
New User
Joined: 28 Apr 2009 Posts: 89 Location: Noida , Dublin
|
|
|
|
thanks all...i did one silly mistake..my modelling of panel was not perfect that was creating the problem .. thanks |
|
Back to top |
|
|
|