locked
do something every 0.5 seconds visual basic RRS feed

  • Question

  • hello all. I want to load an image into a picturebox every 0.5 but I do not know how. Anyone can help me?. thank you very much
    Saturday, May 26, 2012 8:36 PM

Answers

  • Hello july23,

    hello all. I want to load an image into a picturebox every 0.5 but I do not know how. Anyone can help me?. thank you very much

    use the timer , more information below http://msdn.microsoft.com/en-us/library/system.windows.forms.timer.aspx

    has an event timer tick, within which you can insert the code to dynamically load an image inside a picture box control

    Regards.


    Saturday, May 26, 2012 8:45 PM
  • Perhaps you want to use the Threading Timer as well instead of the System.Windows.Forms.Timer.

    If a post helps you in any way or solves your particular issue, please remember to use the Propose As Answer option or Vote As Helpful
    Visit the Forum: TechLifeForum

    • Proposed as answer by Mark Liu-lxf Monday, May 28, 2012 5:55 AM
    • Marked as answer by Mark Liu-lxf Tuesday, June 5, 2012 7:38 AM
    Sunday, May 27, 2012 12:25 AM
  • Deleted
    • Proposed as answer by Mark Liu-lxf Monday, May 28, 2012 5:54 AM
    • Marked as answer by Mark Liu-lxf Tuesday, June 5, 2012 7:38 AM
    Sunday, May 27, 2012 12:10 PM

All replies

  • Hello july23,

    hello all. I want to load an image into a picturebox every 0.5 but I do not know how. Anyone can help me?. thank you very much

    use the timer , more information below http://msdn.microsoft.com/en-us/library/system.windows.forms.timer.aspx

    has an event timer tick, within which you can insert the code to dynamically load an image inside a picture box control

    Regards.


    Saturday, May 26, 2012 8:45 PM
  • Perhaps you want to use the Threading Timer as well instead of the System.Windows.Forms.Timer.

    If a post helps you in any way or solves your particular issue, please remember to use the Propose As Answer option or Vote As Helpful
    Visit the Forum: TechLifeForum

    • Proposed as answer by Mark Liu-lxf Monday, May 28, 2012 5:55 AM
    • Marked as answer by Mark Liu-lxf Tuesday, June 5, 2012 7:38 AM
    Sunday, May 27, 2012 12:25 AM
  • hello all. I want to load an image into a picturebox every 0.5 but I do not know how. Anyone can help me?. thank you very much

    create a timer and change the interval to 5

    then right click your project in the project viewer and go to properties, then resources, then import the pictures.

    place a picture box and a progressbar

    double click on the timer then insert

    dim count as string

    count = 0

    progressbar1.value += 1

    if progressbar1.value = 100 then

    progressbar1.value = 0

    if count = 0 then

    picturebox1.image(my.resources.IMAGE_1)

    count = 1

    end if

    if count = 1 then

    picturebox1.image(my.resources.IMAGE_2)

    'Reset

    count = 0

    end if

    end if

    this script i made in the browser while typing this. it MIGHT work. so dont just go ahead and mark it as the answer

    Sunday, May 27, 2012 6:53 AM
  • Read...learn.

    Have you tried Help?

    Renee


    "MODERN PROGRAMMING is deficient in elementary ways BECAUSE of problems INTRODUCED by MODERN PROGRAMMING." Me


    Sunday, May 27, 2012 9:58 PM
  • I think however the maximal resolution one can achieveris an average 16/2 ms using a  forms timer.

    Renee


    "MODERN PROGRAMMING is deficient in elementary ways BECAUSE of problems INTRODUCED by MODERN PROGRAMMING." Me



    Monday, May 28, 2012 4:43 AM