Re: [BLACKBOX] Converters

From: Campbell, Robert (SELEX GALILEO, UK) <Robert.D.Campbell{([at]})nowhere.xy>
Date: Wed, 17 Sep 2008 13:37:59 +0100

----boundary-LibPST-iamunique-1462623374_-_-
Content-type: text/plain

Thanks Igor

I used the (*Horrible*) way from HostBitmaps, and it is working fine.

I agree that adding a routine:

PROCEDURE GetFileName*(f: Files.File; OUT name: ARRAY OF CHAR)

to HostFiles would be a much cleaner solution - what about this for 1.6
final Oms?

Cheers

Robert


PS: Helmut, I can't use your suggestion as I don't have the filename.

>> -----Original Message-----
>> From: BlackBox [mailto:BLACKBOX{([at]})nowhere.xy
>> Of igor_d{([at]})nowhere.xy
>> Sent: 17 September 2008 10:05

>> R> It there a way of finding a file's pathName?
>> Yes. But the way is horrible. See procedure HostBitmaps.ImportBitmap.
>>
>> PROCEDURE ImportBitmap* (f: Files.File; OUT s:
>> Stores.Store); TYPE Str = POINTER TO ARRAY [untagged] OF
>> CHAR; VAR name: Str; BEGIN
>> name := SYSTEM.VAL(Str, SYSTEM.VAL(INTEGER, f) + 40);
>>
>> The magic number 40 is the offset of the field 'name' in a
>> record of type HostFiles.File.
>>
>> R> Any suggestions?
>> I prefer to customise module HostFiles by adding a simple procedure.
>> PROCEDURE GetFileName*(f: Files.File; VAR name: ARRAY OF CHAR);

SELEX Sensors and Airborne Systems Limited
Registered Office: Sigma House, Christopher Martin Road, Basildon, Essex SS14 3EL
A company registered in England & Wales. Company no. 02426132
********************************************************************
This email and any attachments are confidential to the intended
recipient and may also be privileged. If you are not the intended
recipient please delete it from your system and notify the sender.
You should not copy it or use it for any purpose nor disclose or
distribute its contents to any other person.
********************************************************************


----
To unsubscribe, send a message with body "SIGNOFF BLACKBOX" to LISTSERV{([at]})nowhere.xy----boundary-LibPST-iamunique-1462623374_-_-
Content-type: application/rtf
Content-transfer-encoding: base64
Content-Disposition: attachment; filename="rtf-body.rtf"
e1xydGYxXGFuc2lcYW5zaWNwZzEyNTJcZnJvbXRleHQgXGRlZm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kXHBhcg0K
UmVnaXN0ZXJlZCBPZmZpY2U6IFNpZ21hIEhvdXNlLCBDaHJpc3RvcGhlciBNYXJ0aW4gUm9hZCwg
QmFzaWxkb24sIEVzc2V4IFNTMTQgM0VMXHBhcg0KQSBjb21wYW55IHJlZ2lzdGVyZWQgaW4gRW5n
bGFuZCAmIFdhbGVzLiAgQ29tcGFueSBuby4gMDI0MjYxMzJccGFyDQoqKioqKioqKioqKioqKioq
KioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKlxwYXIN
ClRoaXMgZW1haWwgYW5kIGFueSBhdHRhY2htZW50cyBhcmUgY29uZmlkZW50aWFsIHRvIHRoZSBp
bnRlbmRlZFxwYXINCnJlY2lwaWVudCBhbmQgbWF5IGFsc28gYmUgcHJpdmlsZWdlZC4gSWYgeW91
IGFyZSBub3QgdGhlIGludGVuZGVkXHBhcg0KcmVjaXBpZW50IHBsZWFzZSBkZWxldGUgaXQgZnJv
bSB5b3VyIHN5c3RlbSBhbmQgbm90aWZ5IHRoZSBzZW5kZXIuXHBhcg0KWW91IHNob3VsZCBub3Qg
Y29weSBpdCBvciB1c2UgaXQgZm9yIGFueSBwdXJwb3NlIG5vciBkaXNjbG9zZSBvclxwYXINCmRp
c3RyaWJ1dGUgaXRzIGNvbnRlbnRzIHRvIGFueSBvdGhlciBwZXJzb24uXHBhcg0KKioqKioqKioq
KioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioq
KipccGFyDQpccGFyDQpccGFyDQotLS0tXHBhcg0KVG8gdW5zdWJzY3JpYmUsIHNlbmQgYSBtZXNz
YWdlIHdpdGggYm9keSAiU0lHTk9GRiBCTEFDS0JPWCIgdG8gTElTVFNFUlZATElTVFMuT0JFUk9O
LkNIfX0AbmFsQQ=
----boundary-LibPST-iamunique-1462623374_-_---
Received on Wed Sep 17 2008 - 14:37:59 UTC

This archive was generated by hypermail 2.3.0 : Thu Sep 26 2013 - 06:30:53 UTC