Click here to Skip to main content
15,887,683 members
Home / Discussions / Visual Basic
   

Visual Basic

 
AnswerRe: Please help me with my project work. Pin
Peter_jnr16-Feb-14 11:54
professionalPeter_jnr16-Feb-14 11:54 
QuestionVB 2010 Report is Blank Pin
nyt197227-Nov-13 20:34
professionalnyt197227-Nov-13 20:34 
QuestionWhat do i need to dim the textbox name as? Pin
RedIrishMan26-Nov-13 16:21
RedIrishMan26-Nov-13 16:21 
AnswerRe: What do i need to dim the textbox name as? Pin
RedIrishMan26-Nov-13 16:38
RedIrishMan26-Nov-13 16:38 
AnswerRe: What do i need to dim the textbox name as? Pin
Bernhard Hiller26-Nov-13 22:39
Bernhard Hiller26-Nov-13 22:39 
QuestionScroll Bar Acts Wiered Pin
DipeshTrivedi25-Nov-13 3:28
DipeshTrivedi25-Nov-13 3:28 
AnswerRe: Scroll Bar Acts Wiered Pin
Mycroft Holmes25-Nov-13 11:29
professionalMycroft Holmes25-Nov-13 11:29 
QuestionSorting using User Session Pin
Commish1323-Nov-13 14:14
professionalCommish1323-Nov-13 14:14 
I'm trying to sort my GridView using a User Session but whenever I run my program I get an error message saying 'Cannot find Column Name' but the table columns are correct so I don't know why I'm getting the error message.


If Not Page.IsPostBack Then
BindEmpGrid()
txtSearch.Enabled = False
Dim dt As New DataTable()
**** I'm sure the line below is whats causing the error *******
grdEmp.DataSource = dt
Session("data") = dt
End If


Protected Sub grdEmp_sorting(sender As Object, e As GridViewSortEventArgs) Handles grdEmp.Sorting
Dim dataTable As DataTable = TryCast(Session("data"), DataTable)

If dataTable IsNot Nothing Then
Dim dataView As New DataView(dataTable)
dataView.Sort = Convert.ToString(e.SortExpression) & " " & ConvertSortDirection(e.SortDirection)
grdEmp.DataSource = dataView
grdEmp.DataBind()
End If
End Sub

Private Function ConvertSortDirection(sortDirection1 As SortDirection) As String
Dim newSortDirection As String = [String].Empty
Select Case sortDirection1
Case SortDirection.Ascending
newSortDirection = "ASC"
Exit Select
Case SortDirection.Descending
newSortDirection = "DESC"
Exit Select
End Select
Return newSortDirection
End Function
AnswerRe: Sorting using User Session Pin
Bernhard Hiller24-Nov-13 20:51
Bernhard Hiller24-Nov-13 20:51 
QuestionFunction Calling 2 Different Stored Procedures Pin
Commish1322-Nov-13 6:18
professionalCommish1322-Nov-13 6:18 
AnswerRe: Function Calling 2 Different Stored Procedures Pin
Richard MacCutchan22-Nov-13 7:06
mveRichard MacCutchan22-Nov-13 7:06 
GeneralRe: Function Calling 2 Different Stored Procedures Pin
Eddy Vluggen22-Nov-13 7:09
professionalEddy Vluggen22-Nov-13 7:09 
GeneralRe: Function Calling 2 Different Stored Procedures Pin
Richard MacCutchan22-Nov-13 7:33
mveRichard MacCutchan22-Nov-13 7:33 
AnswerRe: Function Calling 2 Different Stored Procedures Pin
Eddy Vluggen22-Nov-13 7:07
professionalEddy Vluggen22-Nov-13 7:07 
GeneralRe: Function Calling 2 Different Stored Procedures Pin
Commish1322-Nov-13 8:22
professionalCommish1322-Nov-13 8:22 
GeneralRe: Function Calling 2 Different Stored Procedures Pin
Eddy Vluggen26-Nov-13 11:28
professionalEddy Vluggen26-Nov-13 11:28 
Questionhow to display the size of the camera sensor in vb.net Pin
fitriadinurdin21-Nov-13 19:33
fitriadinurdin21-Nov-13 19:33 
QuestionRe: how to display the size of the camera sensor in vb.net Pin
Eddy Vluggen22-Nov-13 7:11
professionalEddy Vluggen22-Nov-13 7:11 
QuestionOverlapping with a Picturebox other controls having the picturebox transparent background VB .NET (update) Pin
jose mandurrino18-Nov-13 23:35
jose mandurrino18-Nov-13 23:35 
QuestionRe: Overlapping with a Picturebox other controls having the picturebox transparent background VB .NET Pin
Richard MacCutchan19-Nov-13 4:37
mveRichard MacCutchan19-Nov-13 4:37 
AnswerRe: Overlapping with a Picturebox other controls having the picturebox transparent background VB .NET Pin
jose mandurrino19-Nov-13 5:39
jose mandurrino19-Nov-13 5:39 
AnswerRe: Overlapping with a Picturebox other controls having the picturebox transparent background VB .NET (update) Pin
Eddy Vluggen19-Nov-13 10:39
professionalEddy Vluggen19-Nov-13 10:39 
GeneralRe: Overlapping with a Picturebox other controls having the picturebox transparent background VB .NET (update) Pin
jose mandurrino19-Nov-13 13:05
jose mandurrino19-Nov-13 13:05 
GeneralRe: Overlapping with a Picturebox other controls having the picturebox transparent background VB .NET (update) Pin
Eddy Vluggen20-Nov-13 7:44
professionalEddy Vluggen20-Nov-13 7:44 
AnswerRe: Overlapping with a Picturebox other controls having the picturebox transparent background VB .NET (update) Pin
TnTinMn19-Nov-13 13:06
TnTinMn19-Nov-13 13:06 

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.