Click here to Skip to main content
15,909,039 members
Home / Discussions / ASP.NET
   

ASP.NET

 
QuestionHow to send SMS to any mobile globally Pin
Software_Guy_12321-Jul-07 5:19
Software_Guy_12321-Jul-07 5:19 
AnswerRe: How to send SMS to any mobile globally Pin
Sathesh Sakthivel21-Jul-07 22:15
Sathesh Sakthivel21-Jul-07 22:15 
Questiontwo dimensional array in vb.net [modified] Pin
Sonia Gupta21-Jul-07 1:48
Sonia Gupta21-Jul-07 1:48 
AnswerRe: two dimensional array in vb.net Pin
Guffa21-Jul-07 5:22
Guffa21-Jul-07 5:22 
QuestionGridview Paging Pin
venkata lakshmi prasanna21-Jul-07 1:19
venkata lakshmi prasanna21-Jul-07 1:19 
AnswerRe: Gridview Paging Pin
Fred_Smith21-Jul-07 5:21
Fred_Smith21-Jul-07 5:21 
AnswerRe: Gridview Paging Pin
Sathesh Sakthivel21-Jul-07 22:13
Sathesh Sakthivel21-Jul-07 22:13 
Questiondisplayin image Pin
boyindie21-Jul-07 0:24
boyindie21-Jul-07 0:24 
Hi
I am tryin to display an image which is stored in a database

i ahve a procedure which will go to the appropiate record in my database and pull the file name from it

it should then take the file name and put it into a prefixed img src tag, which should then take the appropiate file from the imagestore and display to the web page

it all seems to work fine, even when i check the html source file the tag has been filled with the valid address but it jus doesn't seem to want to render the image

Is there anythin i need to do here? here is my code

<code> Sub getimage(ByVal sender As Object, ByVal e As EventArgs)
'Create connection string to pass database, string holds login information to mySQL,
Dim connectionString As String
connectionString = "Server=localhost; u;database=ftp1;"

'Builds .net mysql connection and passes connection string into method
Dim connection As New MySqlConnection(connectionString)



'Create mySql command string for passing query or SPROC(Stored Procedure)
Dim cmdString As New MySqlCommand
'Set Command to equal mySql connection,t so can pass SQL query
cmdString.Connection = connection


'Set command string to equal SPROC
cmdString.CommandText = "sp_getImage"
'ONLY PLACE THIS IF SPROC, sets the command to a SPROC
cmdString.CommandType = CommandType.StoredProcedure
Dim literr As New LiteralControl

Dim param As MySqlParameter
Try
'Creates parameter which will be passed into procedure
param = cmdString.Parameters.Add("?p_id", MySqlDbType.Int32)
'Sets parameter type equal to input
param.Direction = ParameterDirection.Input
'Sets parameter value equal to value held in textbox
param.Value = 4

'Creates parameter to pass into SPROC
param = cmdString.Parameters.Add("?p_image", MySqlDbType.VarChar)
'Sets parameter type to output
cmdString.Parameters("?p_image").Direction = ParameterDirection.Output


connection.Open() 'Opens DB connection
cmdString.ExecuteNonQuery() 'Executes procedure and reads in OUTPUT parameter
connection.Close() 'Closes DB connection

Catch ex As Exception
literr.Text = ex.Message
MsgBox(ex.Message)

End Try
MsgBox(cmdString.Parameters("?p_image").Value)

Dim imageStore As String = cmdString.Parameters("?p_image").Value
MsgBox(imageStore)
imgHolder.ImageUrl = ("c:\test\" & imageStore)

End Sub


<asp:image runat=server ID="imgHolder" Height="282px" Width="488px" BackColor="Red" />
</code>
AnswerRe: displayin image Pin
Fred_Smith21-Jul-07 4:41
Fred_Smith21-Jul-07 4:41 
Questionconnection code in app_cofig file using windows form Pin
$h@ma!|@20-Jul-07 23:40
$h@ma!|@20-Jul-07 23:40 
AnswerRe: connection code in app_cofig file using windows form Pin
Sonia Gupta20-Jul-07 23:58
Sonia Gupta20-Jul-07 23:58 
AnswerRe: connection code in app_cofig file using windows form Pin
Psycho-*Coder*-Extreme21-Jul-07 6:37
Psycho-*Coder*-Extreme21-Jul-07 6:37 
Questionvalidation checks in desktop application Pin
ooooooooppppppss20-Jul-07 23:27
ooooooooppppppss20-Jul-07 23:27 
AnswerRe: validation checks in desktop application Pin
Sonia Gupta20-Jul-07 23:40
Sonia Gupta20-Jul-07 23:40 
GeneralRe: validation checks in desktop application Pin
ooooooooppppppss20-Jul-07 23:50
ooooooooppppppss20-Jul-07 23:50 
GeneralRe: validation checks in desktop application Pin
Sonia Gupta21-Jul-07 0:05
Sonia Gupta21-Jul-07 0:05 
QuestionCreateUserWizard Inquiry Pin
Tethibogz20-Jul-07 22:08
Tethibogz20-Jul-07 22:08 
AnswerRe: CreateUserWizard Inquiry Pin
Sonia Gupta20-Jul-07 23:00
Sonia Gupta20-Jul-07 23:00 
GeneralRe: CreateUserWizard Inquiry Pin
Tethibogz21-Jul-07 9:34
Tethibogz21-Jul-07 9:34 
AnswerRe: CreateUserWizard Inquiry Pin
enjoycrack21-Jul-07 16:24
enjoycrack21-Jul-07 16:24 
QuestionDrag and Drop and upload images in IE Pin
Milind Panchal20-Jul-07 21:16
Milind Panchal20-Jul-07 21:16 
AnswerRe: Drag and Drop and upload images in IE Pin
Christian Graus20-Jul-07 21:24
protectorChristian Graus20-Jul-07 21:24 
AnswerRe: Drag and Drop and upload images in IE Pin
Sonia Gupta20-Jul-07 22:57
Sonia Gupta20-Jul-07 22:57 
GeneralRe: Drag and Drop and upload images in IE Pin
Milind Panchal20-Jul-07 23:19
Milind Panchal20-Jul-07 23:19 
Questionbutton click event firig twice .. Pin
Vipin.d20-Jul-07 20:37
Vipin.d20-Jul-07 20:37 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.