f



Re: AIFFILEGGET -- Perm file vs Temp File Problem #2

The saga continues. Well, not really, got an answer from the AIF techie a=
t=20
HP just a few days ago.

The results returned by AIFFILEGGET differs between perm and temp files.

There are three ways to access a file's attributes with this intrinsic.

Scenario #1 --=20

Perm file

1) Go in by the File Name returns a -43 if file not found
2) Go in by the UFID returns -42 if file not found
3) Go in by HFS pathname returns a -66 if file not found.

Tempfile parm is boolean zeroes.

Correct for perm files.


Scenario #2 --

Temp file=20

1) Go in by the File Name returns a -43 if file not found
2) Go in by the UFID returns -42 if file not found
3) Go in by HFS pathname returns a -66 if file not found.

Guess what? -- the temp file is not found if you go in by the file name o=
r hfs=20
path name. AIFFILEGGET only finds the temporary file if you go in by the =
UFID.

Regardless, the tempfile parm is returned as boolean zeroes! WRONG! -- sh=
ould=20
be boolean true.


After discussions with the techie at HP recently I was given the bad news=

and told that this problem will never be fixed now.

Nice one.

No matter, I can live with it, as most of the time I would be processing
perm files with this intrinsic.

Makes me wonder which other AIF intrinsics are flawed......

Time will tell,
Brian.

On Mon, 1 Oct 2007 20:01:57 -0400, Brian Donaldson <bmdinsocal@AOL.COM>=20=

wrote:

>I found a solution -- use the UFID instead of the file name and
>AIFFILEGGET works just fine.
>
>Brian.
>
>On Mon, 1 Oct 2007 15:48:29 -0400, Brian Donaldson=20
<bmdinsocal@AOL.COM>=20
>wrote:
>
>>I am using this AIF intrinsic to get info on a file.
>>
>>Works fine when the file is in the perm domain but it doesn't work if
>>the file is in the temp domain.
>>
>>I need this file to be in the temp domain (not the perm domain) so
>>what do I need to do to get AIFFILEGGET to see the temp file.
>>
>>I would use the FLABELINFO intrinsic but it doesn't give me the file=20=

>>lockword when the program is being run by a non SM/AM user.
>>
>>So I opted for the AIF's.
>>
>>
>>Here's my code:
>>
>>PROCEDURE get_the_labelinfo(var overall_status:HPE_status;
>>                            var item_table    :item_table_type;
>>                            var tempfile       :boolean);
>>
>>label 999;
>>begin
>>   item_num_array[1]  :=3D 5001;
>>   item_num_array[2]  :=3D 5041;
>>   item_num_array[3]  :=3D 5016;
>>   item_num_array[4]  :=3D 5008;
>>   item_num_array[5]  :=3D 5017;
>>   item_num_array[6]  :=3D 5012;
>>   item_num_array[7]  :=3D 5039;
>>   item_num_array[8]  :=3D 5010;
>>   item_num_array[9]  :=3D 0;
>>
>>   item_array    [1]  :=3D addr(item_table.itt_file_name);
>>   item_array    [2]  :=3D addr(item_table.itt_file_owner);
>>   item_array    [3]  :=3D addr(item_table.itt_rec_size);
>>   item_array    [4]  :=3D addr(item_table.itt_file_code);
>>   item_array    [5]  :=3D addr(item_table.itt_eof);
>>   item_array    [6]  :=3D addr(item_table.itt_foptions);
>>   item_array    [7]  :=3D addr(item_table.itt_file_type);
>>   item_array    [8]  :=3D addr(item_table.itt_lockword);
>>
>>   overall_status.all     :=3D 0;
>>   user_id                :=3D 0;
>>   item_status_array      :=3D init_item_status_array;
>>   item_table.itt_lockword:=3D ' ';
>>
>>   GETPRIVMODE;
>>
>>   AIFFILEGGET(overall_status,
>>               item_num_array,
>>               item_array,
>>               item_status_array,,
>>               item_table.itt_file_name,
>>               tempfile,
>>               user_id,,);
>>   if overall_status.all <> 0 then
>>      goto 999;
>>
>>   goto 999;
>>999:
>>   GETUSERMODE;
>>end;
>>
>>TIA,
>>Brian Donaldson.
>>
>>* To join/leave the list, search archives, change list settings, *
>>* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *
>
>* To join/leave the list, search archives, change list settings, *
>* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *

* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *

0
Brian
10/21/2007 9:43:35 PM
comp.sys.hp.mpe 25828 articles. 0 followers. rhorner (2) is leader. Post Follow

0 Replies
304 Views

Similar Articles

[PageSpeed] 1

Reply: