|
I created one html file that file should view through scriptlet control. Before deploying the project it works fine
After deploying the project only the scriptlet is not working.
I think that the corresponding dll is not there in my deployed application. Here i am sendig my code
Private Sub btnhome_Click()
Unload Me
frmMain.Show
End Sub
Private Sub Form_Load()
Scriptlet1.Visible = False
MMControl1.fileName = App.path & "\Time Line1.mpg"
MMControl1.hWndDisplay = Picture1.hwnd
MMControl1.Command = "Open"
End Sub
Private Sub Form_Unload(Cancel As Integer)
MMControl1.Command = "Stop"
MMControl1.Command = "Close"
End Sub
Private Sub Home_Click()
Unload Me
frmMain.Show
End Sub
Private Sub MMControl1_StatusUpdate()
Dim strMode As String
strMode = ""
Select Case MMControl1.Mode
Case mciModeReady
strMode = "Ready."
Case mciModeStop
strMode = "Stopped."
Scriptlet1.Visible = False
Case mciModeSeek
strMode = "Seeking."
Case mciModePlay
strMode = "Playing."
Scriptlet1.Visible = True
'Scriptlet1.url = "file://" & App.path & "\fish1.html"
Case mciModeRecord
strMode = "Recording."
Case mciModePause
strMode = "Paused."
End Select
Label1.Caption = strMode
End Sub
Private Sub Scriptlet1_onscriptletevent(ByVal name As String, ByVal eventData As Variant)
End Sub
|
|
|
|
|
It is probably the URL for the embedded scriptlet object that is causing problems. You probably have it pointing to the absolute address where you are developing it, which of course no-one else can access.
However scriptlets are not a good design choice.
If you are coding in vb.Net, why not use a custom web control (.ascx) instead. If not then I suggest using an iframe. Scriptlets are only supported by Internet Explorer so useless unless used on an intranet with a company policy enforcing no other browser. When used in the real world a page containing a scriptlet will not work at all for nearly a third of your customers.
If you have knowledge, let others light their candles at it.
Margaret Fuller (1810 - 1850)
www.JacksonSoft.co.uk
|
|
|
|
|
Hi All,
I need some help with customizing an upload.aspx. I have a VB.Net 2005
Winform that has a file picker and a textbox (plus loads of other stuff).
When the user selects a file, I want to upload the file to a server.
This is the command I am using in my Winform to upload the file:
My.Computer.Network.UploadFile(CStr(e.Value), Files_Dir, "user", "password",
True, 100, FileIO.UICancelOption.ThrowException)
Where Files_dir = http://server/upload.aspx
Separately, I've created an upload.aspx page that works fine. When I select
a file or type a filename into the textbox on the upload.aspx page and click
upload, the file is uploaded to the correct directory on the server.
The upload.aspx form is simple with just one textbox and 2 buttons:
<%@ Page Language="VB" AutoEventWireup="false" CodeFile="Default.aspx.vb"
Inherits="_Default" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transition al.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>Upload</title>
</head>
<body>
<form id="frmUp" runat="server">
<div>
<input id="inpFile" type="file" runat="server" /><br/>
<asp:Button id="btn_Upload" runat="server" text="Upload" /><br
/>
<span id="txtMsg" runat="server" />
</div>
</form>
</body>
</html>
And the code behind:
Protected Sub btnUpload_Click(ByVal sender As Object, ByVal e As
System.EventArgs) Handles btn_Upload.Click
Dim i As Integer
Dim objFile As HttpPostedFile
Dim strFileName As String
Dim strMessage As String = ""
For i = 0 To Request.Files.Count - 1
objFile = Request.Files(i)
If Len(objFile.FileName) > 0 Then
strFileName objFile.FileName.Substring(objFile.FileName.LastInd exOf("\") + 1)
Try
objFile.SaveAs(Server.MapPath("~/Files") & "/" &
strFileName)
strMessage &= "<span>" & strFileName & " successfully
uploaded</span><br/>"
Catch ex As Exception
strMessage &= "<span>Failed uploading " & strFileName &
": " & ex.ToString() & "</span><br/>"
End Try
End If
Next i
txtMsg.InnerHtml = strMessage
End Sub
So, how do I pass the filename to be uploaded to the upload.aspx page?
(Something like http://server/upload.aspx?filename)??? I know the code
that's in the button click event will work when someone actually clicks the
button, but where do I put the code so that it'll fire when the winform
tries to upload a file? (It seems that the page load event might be ok, but,
is the page ever loaded?)
I don't want the Winform user to ever see the upload.aspx page. I just want
the Winform UploadFile command to use the form to put the file on the
server.
Any help would be greatly appreciated!!
|
|
|
|
|
Write a webservice instead of mucking around with this. It can run on the same site as your webpage, so the files will be on the server with your website.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
hi expert
i have created one table in mysql database
the field name is
ex. id,name,address
so i want insert name and address in table by store procedure and get value of id by out parameter.
name is in parameter
address is in parameter
id is out parameter
|
|
|
|
|
Con.Open()
'Transaction = Con.BeginTransaction()
Dim cmd As New SqlCommand("SP", Con)
cmd.CommandType = CommandType.StoredProcedure
cmd.ExecuteNonQuery()
Variable = cmd.Parameters("@ID").Value
'Transaction.Commit()
Con.Close()
Best Of Regards,
SOFTDEV
If you have knowledge, let others light their candles at it
|
|
|
|
|
That's great, if only it would work.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
pauleeece correct me if ,their is any mistake
Best Of Regards,
SOFTDEV
If you have knowledge, let others light their candles at it
|
|
|
|
|
When you add your parameters to the code for the proc, make sure you create the parameter explicitly, then add it to the list. That way, you can also set the Direction property ( from memory ) to specify it's an Out parameter. Then check the value on that variable after calling the procedure.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Thanks,
Yes you are right , like this
cmd.Parameters.Add(New SqlParameter("@ID", SqlDbType.Int, 9, ParameterDirection.Output, False, 18, 0, "ID", DataRowVersion.Current, CInt(mCls.EM_ID)))
Best Of Regards,
SOFTDEV
If you have knowledge, let others light their candles at it
|
|
|
|
|
Hi,
Please help me in getting process id when job is scheduled or RUN. It helps me in killing the process when more than one process of same name occurs.
|
|
|
|
|
How do you expect to identify it ? Is your code doing the running ?
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Hello guys
I need your help
I have an array of byte.
each byte array represent a individual file of any type
(the filetype is unknown but i kept the file name and extension in separated data)
i want to display it on a list view.
Here is the problem
how can i display it on large icon, small icon, list and tile view with windows default icon to be shown?
It's like when you use windows explorer with Thumbnail , tiles or list view...
Please help me....
Sorry for my idiocy....
|
|
|
|
|
Oh yeah
Im Sorry i forget to tell you
Im Using VB.Net 2005....
Thanks....
|
|
|
|
|
Deadlast wrote: how can i display it on large icon, small icon, list and tile view with windows default icon to be shown?
These are just different representations of the content of a ListView. Check the ListView documentation on MSDN for the methods to switch between the different display types.
|
|
|
|
|
Thanks Richard
I had already managed to handle different display type on listview
What i am not capable of is to show the ICON when i was in Large icon, small icon, list and tile display type....
How can i do that??
Thanks again
|
|
|
|
|
Deadlast wrote: What i am not capable of is to show the ICON when i was in Large icon, small icon, list and tile display type....
As I said in my previous reply, see the ListView[^] documentation on MSDN. There are various ImageList type properties which define the icon to be displayed in the different views.
|
|
|
|
|
Thanks Richard I get it now...
But how manage to show large icon and small icon from Byte Array...
Please, give me a clue..
Thanks so much Richard.....
|
|
|
|
|
Deadlast wrote: But how manage to show large icon and small icon from Byte Array...
I'm not sure what you mean by Byte Array in this context. Check out the LargeImageList and SmallImageList Properties in the ListView.
|
|
|
|
|
What i meant was that i have files that have been converted into Array of byte...
These files could be any kind of file type...
then instead of displaying the files from specified location on hard drive...
I want to display the files that have been converted into Array of byte.....
Thankyou...
|
|
|
|
|
Deadlast wrote: I want to display the files that have been converted into Array of byte.....
I think you will need to use the OwnerDraw property and event for this. See here[^] on MSDN for more information.
|
|
|
|
|
Hi richard, thanks for the advice
But i seem don't get it
I just want to display the icons based on byte array...
Not to redraw Listview on my own
Im sorry....
I dont really understand...
|
|
|
|
|
Well a quick Google search produced this[^]!
|
|
|
|
|
I am looking for someone help to develop a motion tracking system.
I need a very basic application to track a fairly fast moving ball in 2D from a web or video camera. If I can get funding following a proof of concept demo it could lead to a lucrative contract.
Ian
|
|
|
|
|
Something like this[^]? Perhaps the code would work with a fluorescent ball?
Sounds cool
I are Troll
|
|
|
|