من می خوام یک ویذیو از گالری انتخاب کنم
تا اینجا رو انجام میدم
وقتی می خوام این ویدیو را
#Region Project Attributes
#ApplicationLabel: uploadvideo
#VersionCode: 1
#VersionName:
'SupportedOrientations possible values: unspecified, landscape or portrait.
#SupportedOrientations: portrait
#CanInstallToExternalStorage: False
#End Region
#Region Activity Attributes
#FullScreen: False
#IncludeTitle: True
#End Region
Sub Process_Globals
'These global variables will be declared once when the application starts.
'These variables can be accessed from all modules.
Dim Up As UploadFilePhp
Dim cc As ContentChooser
End Sub
Sub Globals
'These global variables will be redeclared each time the activity is created.
'These variables can only be accessed from this module.
Private Button1 As Button
Private Button2 As Button
Dim vv1 As VideoView
Private Panel1 As Panel
Dim http As HttpJob
Dim filmname As String
End Sub
Sub Activity_Create(FirstTime As Boolean)
'Do not forget to load the layout file created with the visual designer. For example:
Activity.LoadLayout("1")
vv1.Initialize("vv1")
http.Initialize("Job1",Me)
Panel1.AddView(vv1,0,0,Panel1.Width,Panel1.Height)
End Sub
Sub Activity_Resume
End Sub
Sub Activity_Pause (UserClosed As Boolean)
End Sub
Sub Button1_Click
Dim cc As ContentChooser
cc.Initialize("videochooser")
cc.Show("video/*","انتخاب تصویر")
Panel1.Visible = True
vv1.MediaControllerEnabled = True
vv1.Play
End Sub
Sub videochooser_Result(Success As Boolean, Dir As String, FileName As String)
If Success = True Then
vv1.LoadVideo(Dir,FileName)
End If
End Sub
Sub Button2_Click
filmname = vv1.toString
http.PostFile("http://fater.bartar124.ir/phpfile/film/upload.php?FileName="&filmname,File.DirInternal,filmname)
ProgressDialogShow("در حال ثبت اطلاعات...")
End Sub
Sub JobDone (Job As HttpJob)
ProgressDialogHide
If Job.Success = True Then
Select Job.JobName
Case "Job1"
Msgbox( Job.GetString,"پیام سیستم")
End Select
Else
ToastMessageShow("خطا در برقراری اتصال" , False)
End If
Job.Release
End Sub
'
سوال
rezanaseri 6
من می خوام یک ویذیو از گالری انتخاب کنم
تا اینجا رو انجام میدم
وقتی می خوام این ویدیو را
#Region Project Attributes #ApplicationLabel: uploadvideo #VersionCode: 1 #VersionName: 'SupportedOrientations possible values: unspecified, landscape or portrait. #SupportedOrientations: portrait #CanInstallToExternalStorage: False #End Region #Region Activity Attributes #FullScreen: False #IncludeTitle: True #End Region Sub Process_Globals 'These global variables will be declared once when the application starts. 'These variables can be accessed from all modules. Dim Up As UploadFilePhp Dim cc As ContentChooser End Sub Sub Globals 'These global variables will be redeclared each time the activity is created. 'These variables can only be accessed from this module. Private Button1 As Button Private Button2 As Button Dim vv1 As VideoView Private Panel1 As Panel Dim http As HttpJob Dim filmname As String End Sub Sub Activity_Create(FirstTime As Boolean) 'Do not forget to load the layout file created with the visual designer. For example: Activity.LoadLayout("1") vv1.Initialize("vv1") http.Initialize("Job1",Me) Panel1.AddView(vv1,0,0,Panel1.Width,Panel1.Height) End Sub Sub Activity_Resume End Sub Sub Activity_Pause (UserClosed As Boolean) End Sub Sub Button1_Click Dim cc As ContentChooser cc.Initialize("videochooser") cc.Show("video/*","انتخاب تصویر") Panel1.Visible = True vv1.MediaControllerEnabled = True vv1.Play End Sub Sub videochooser_Result(Success As Boolean, Dir As String, FileName As String) If Success = True Then vv1.LoadVideo(Dir,FileName) End If End Sub Sub Button2_Click filmname = vv1.toString http.PostFile("http://fater.bartar124.ir/phpfile/film/upload.php?FileName="&filmname,File.DirInternal,filmname) ProgressDialogShow("در حال ثبت اطلاعات...") End Sub Sub JobDone (Job As HttpJob) ProgressDialogHide If Job.Success = True Then Select Job.JobName Case "Job1" Msgbox( Job.GetString,"پیام سیستم") End Select Else ToastMessageShow("خطا در برقراری اتصال" , False) End If Job.Release End Sub '
بفرستم رو هاست ارور میده
لینک ارسال
به اشتراک گذاری در سایت های دیگر
5 پاسخ به این سوال تاکنون داده شده است
ارسالهای توصیه شده
بایگانی شده
این موضوع بایگانی و قفل شده و دیگر امکان ارسال پاسخ نیست.