Click here to Skip to main content
15,913,722 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: SMTP email (gmail) Pin
Bharat Jain19-Feb-09 0:30
Bharat Jain19-Feb-09 0:30 
QuestionNot so much a programming question, more a kind of please explain why... Pin
Dalek Dave17-Feb-09 5:16
professionalDalek Dave17-Feb-09 5:16 
QuestionVBA for Excel Need Help Debugging Date Conversion Pin
codeslingerCA17-Feb-09 4:13
codeslingerCA17-Feb-09 4:13 
AnswerRe: VBA for Excel Need Help Debugging Date Conversion Pin
Dave Kreskowiak18-Feb-09 3:58
mveDave Kreskowiak18-Feb-09 3:58 
Questionload report failed while crystal report running in visual studio 2005 Pin
NaliniNagarajan17-Feb-09 2:18
NaliniNagarajan17-Feb-09 2:18 
AnswerRe: load report failed while crystal report running in visual studio 2005 Pin
tosch17-Feb-09 4:27
tosch17-Feb-09 4:27 
Generalprogress bar Pin
Aamir Mustafa17-Feb-09 1:24
Aamir Mustafa17-Feb-09 1:24 
GeneralRe: progress bar Pin
Ashfield17-Feb-09 1:32
Ashfield17-Feb-09 1:32 
Aamir Mustafa wrote:
but this is loading albums and photos again and again


Of course it is, you have put your load in the for loop:


 For i = 1 To 100 Step 6
     ProgressBar1.Value = +i

     Dim objAlbums As New Albums()
     treeAlbum.Nodes.Clear()
     Using oReader As SqlDataReader = objAlbums.GetAlbumsAndPhotos()

     etc
next


To make your progress bar work properly you need to update it in the reader bit:

While oReader.Read()
    do all your code and update progress bar


You may want to consider a background thread to keep the UI responsive.

Bob
Ashfield Consultants Ltd
Proud to be a 2009 Code Project MVP

QuestionDrag-arrow on usercontrol in designer Pin
vigylant16-Feb-09 23:43
vigylant16-Feb-09 23:43 
QuestionVBScript logoff Pin
JR21216-Feb-09 22:27
JR21216-Feb-09 22:27 
AnswerRe: VBScript logoff Pin
DaveAuld16-Feb-09 23:20
professionalDaveAuld16-Feb-09 23:20 
GeneralRe: VBScript logoff Pin
JR21216-Feb-09 23:34
JR21216-Feb-09 23:34 
AnswerRe: VBScript logoff Pin
Dave Kreskowiak17-Feb-09 3:49
mveDave Kreskowiak17-Feb-09 3:49 
GeneralRe: VBScript logoff Pin
JR21217-Feb-09 21:14
JR21217-Feb-09 21:14 
GeneralRe: VBScript logoff Pin
Dave Kreskowiak18-Feb-09 2:13
mveDave Kreskowiak18-Feb-09 2:13 
Questionhexa Pin
aswd16-Feb-09 21:11
aswd16-Feb-09 21:11 
AnswerRe: hexa Pin
DaveAuld16-Feb-09 23:23
professionalDaveAuld16-Feb-09 23:23 
GeneralRe: hexa Pin
aswd17-Feb-09 5:03
aswd17-Feb-09 5:03 
GeneralRe: hexa Pin
EliottA17-Feb-09 5:35
EliottA17-Feb-09 5:35 
GeneralRe: hexa Pin
DaveAuld17-Feb-09 5:55
professionalDaveAuld17-Feb-09 5:55 
GeneralRe: hexa Pin
aswd17-Feb-09 15:30
aswd17-Feb-09 15:30 
GeneralRe: hexa Pin
EliottA18-Feb-09 2:21
EliottA18-Feb-09 2:21 
QuestionInserting Graphs in VB using Visual Studio Pin
EvanSaunders16-Feb-09 20:00
EvanSaunders16-Feb-09 20:00 
AnswerRe: Inserting Graphs in VB using Visual Studio Pin
DaveAuld16-Feb-09 23:27
professionalDaveAuld16-Feb-09 23:27 
QuestionProblem with passing UDT array from Excel VBA to C++ dll Pin
eight16-Feb-09 19:51
eight16-Feb-09 19:51 

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.