
20/09/2006, 10:02
|
| | Fecha de Ingreso: mayo-2005
Mensajes: 95
Antigüedad: 19 años, 10 meses Puntos: 0 | |
Ok, no problem; ya lo he solucionado.
Private Sub DataGrid1_ItemDataBound(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.DataGridItemEventArgs) Handles DataGrid1.ItemDataBound
Dim aux As String = ""
Dim fichero As String = ""
Dim count As Integer
count = e.Item.Cells.Count()
'Si no es cabecera o footer ya que si no fallan los indices
If (Not e.Item.ItemType = ListItemType.Header) And (Not e.Item.ItemType = ListItemType.Footer) Then
'La tercera columna del datagrid es la que corresponde al path de ejecutable
aux = e.Item.Cells(3).Text.ToString()
count = e.Item.Cells(3).Text.Split("\").Length()
fichero = e.Item.Cells(3).Text.Split("\")(count - 1).ToString()
If (fichero <> "") Then
e.Item.Cells(3).Text = fichero
End If
End If
End Sub |