Real Software Forums

The forum for Real Studio and other Real Software products.
[ REAL Software Website | Board Index ]
It is currently Sun Jun 24, 2018 4:16 am
xojo

All times are UTC - 5 hours




Post new topic Reply to topic  [ 4 posts ] 
Author Message
 Post subject: Can read video from database macosx but not from windows...
PostPosted: Wed Mar 06, 2013 4:41 am 
Offline

Joined: Mon Sep 28, 2009 1:29 am
Posts: 32
Hallo...

I have a record:
id as integer
video as binary

I have:

dim f as folderitem
dim b as binarystream
dim s as string
f = GetOpenFolderItem ("")
if f <> nil then
b = BinaryStream.Open(f)
s = b.Read(b.Length)
Dim rec As New DatabaseRecord
rec.IntegerColumn("id") = val(IdScelto)
rec.BlobColumn("video") = s
app.db.InsertRecord "video", rec
if app.db.Error then MsgBox app.db.ErrorMessage
app.db.Commit
end if

for put video and this works
Then I have :
RecordScelto = App.db.SQLSelect("SELECT video FROM video WHERE id = " + vettvid(index) + ";")
if RecordScelto.RecordCount > 0 then
RecordScelto.MoveFirst
if Schermo <> nil then Schermo.Stop
#if TargetWin32
Schermo.PlayerType = 2
#ElseIf TargetMacOS
Schermo.PlayerType = 1
#endif
Schermo.Movie = app.strvid(RecordScelto.Field("video").StringValue)
Schermo.Top = ImgChi.top
Schermo.Left = (Main.Width - Schermo.Width) / 2
Schermo.Play
Schermo.Visible = true
end if

Works only for macosx. On windows shows: can't play .tmp extension (or something similar)
what can I do????

Thank you
Gianfranco


Top
 Profile  
Reply with quote  
 Post subject: Re: Can read video from database macosx but not from windows
PostPosted: Fri Apr 12, 2013 2:48 am 
Offline

Joined: Mon Sep 28, 2009 1:29 am
Posts: 32
Nobody have an idea???

gianfranco


Top
 Profile  
Reply with quote  
 Post subject: Re: Can read video from database macosx but not from windows
PostPosted: Fri Apr 12, 2013 11:19 am 
Offline
User avatar

Joined: Sun Aug 12, 2007 10:10 am
Posts: 1086
Location: Boiling Springs, SC
gianfranco wrote:
Nobody have an idea???

gianfranco



when the video is written to disk...can you open it using the system default player?

_________________
Matthew A. Combatti
Real Studio 2012 r1.2

Visit Xojo Developer's Spot!
Systems I Use:
Windows XP/Windows Vista/Windows Server 2008 r2/Windows 7/Windows 8
Mac OSX 10.5/Mac OSX 10.6/Mac OSX Server/Ubuntu/Debian/Suse/Red Hat/
Windows Server 2011/CentOS 5.4 /ReactOS/SimOS

~All Xojo Compatible~


Top
 Profile  
Reply with quote  
 Post subject: Re: Can read video from database macosx but not from windows
PostPosted: Fri Apr 12, 2013 7:05 pm 
Offline

Joined: Fri Nov 16, 2007 10:18 pm
Posts: 195
Location: Portland, OR
gianfranco wrote:
Schermo.Movie = app.strvid(RecordScelto.Field("video").StringValue)

Works only for macosx. On windows shows: can't play .tmp extension (or something similar)
what can I do????


Looks like your problem lies within app.strvid. You will want to look at how it is naming the temp file for video playback because the video player does not want to touch a file with an invalid extension.

_________________
Windows: Win7 64bit sp1, Vista 32bit sp2, WinXP 32bit SP3
Linux: RH EL6
Mac: Died in 2011 and took 2 months to notice.

RealStudio: 2012r2


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC - 5 hours


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group