[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to embedded file/sound into executable?


On 3/23/24 19:50, BB wrote:
Ah, I just realised. Because you are passing the file path to an external program (which can't see inside the executable) you need to :

on startup, copy the file from inside the executable to a Temp directory

then you can refer to that file in your Exec call.

b

Or:

Public Sub Main()

  Dim Data As Stream
  Dim pPlay As Process

  Data = Open "./din-din.wav" For Read
  pPlay = Exec ["aplay"] For Write

  Write #pPlay, Read #Data, Lof(Data)

End



--
Lee

--- Gambas User List Netiquette [https://gambaswiki.org/wiki/doc/netiquette] ----
--- Gambas User List Archive [https://lists.gambas-basic.org/archive/user] ----


Follow-Ups:
Re: How to embedded file/sound into executable?Jussi Lahtinen <jussi.lahtinen@xxxxxxxxx>
Re: How to embedded file/sound into executable?Admin <admin@xxxxxxxxxx>
References:
How to embedded file/sound into executable?roberto.premoli@xxxxxxxxxx
Re: How to embedded file/sound into executable?T Lee Davidson <t.lee.davidson@xxxxxxxxx>
Re: How to embedded file/sound into executable?roberto.premoli@xxxxxxxxxx
Re: How to embedded file/sound into executable?BB <adamnt42@xxxxxxxxx>
Re: How to embedded file/sound into executable?BB <adamnt42@xxxxxxxxx>