Question : ASP.NET: I am having a problem with inserting a value into an mssql select statement

This is the string:
this works when I hard code the number '23' .....
  InsertCommand="INSERT INTO [CustomerImages] ([ImageID],[EquipmentID], [Title],  [ImageData], MIMEType)
          VALUES (@ImageId, (SELECT [EquipmentID] FROM Equipment WHERE ID =  '23'), @Title, @ImageData, @MIMEType)" >
----------------------------------------
the value I need is  being displayed by this label message
 MessageLabel.Text = "You selected row ID = " & row.Cells(1).Text & "."

I need to insert this value      ..... row.Cells(1).Text .... into the select statement.

when I do this I get a statement that the server tag is not well formed

InsertCommand="INSERT INTO [CustomerImages] ([ImageID],[EquipmentID], [Title],  [ImageData], MIMEType)
          VALUES (@ImageId, (SELECT [EquipmentID] FROM Equipment WHERE ID =  '" + row.Cells(1).Text + "'), @Title, @ImageData, @MIMEType)" >

Answer : ASP.NET: I am having a problem with inserting a value into an mssql select statement

if u are looking for portable application for thumb drive, check below

all application in Public license and free ware.

http://www.lupopensuite.com/

you can run web server from your thumb drive and can put your application as a link.

http://www.pendriveapps.com/usb-webserver/

Random Solutions  
 
programming4us programming4us