Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Sensitive picture display on the form.

Posted on 2006-06-15
6
Medium Priority
?
181 Views
Last Modified: 2010-04-30
The picture on the form draws a graph, but the picture is so sensitive, it disappears if a windows comes on top of it, it also dissappears if the application window is minimized, can someone please tell me what is causing this behavior.

Thank you.
0
Comment
Question by:Aiysha
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
  • 2
6 Comments
 
LVL 86

Expert Comment

by:Mike Tomlinson
ID: 16915355
How are you drawing this graph?
0
 

Author Comment

by:Aiysha
ID: 16915407
For j = 1 To count - 1
X = ArrDate(j)
Y = ArrData(j)
x1 = ArrDate(j + 1)
y1 = ArrData(j + 1)
Picture1.Line (X, Y)-(x1, y1), vbBlue
Picture1.DrawWidth = 2
Next j
0
 
LVL 5

Expert Comment

by:lunchbyte
ID: 16915564
do you have form.redraw set to false if so then set it to true and see if this helps.
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 

Author Comment

by:Aiysha
ID: 16915648
Where do I find that option "Form.redraw" ?
0
 
LVL 86

Expert Comment

by:Mike Tomlinson
ID: 16915671
It should be the AutoRedraw property of your PICTUREBOX set to True.

If you don't want AutoRedraw set to True, then use the PictureBoxes Paint() event to do your drawing:

So either:

    Private Sub Form_Load()
        Picture1.AutoRedraw = True
    End Sub

or:

    Private Sub Picture1_Paint()
        ' variable declarations...
   
        ' ... more code possibly ...
   
        For j = 1 To Count - 1
            X = ArrDate(j)
            Y = ArrData(j)
            X1 = ArrDate(j + 1)
            Y1 = ArrData(j + 1)
            Picture1.Line (X, Y)-(X1, Y1), vbBlue
            Picture1.DrawWidth = 2
        Next j
    End Sub
0
 
LVL 5

Accepted Solution

by:
lunchbyte earned 2000 total points
ID: 16915673
in properties.

autoredraw not redraw my bad.

You can do this on form load
me.autoredraw = true if you cannot find it in properties
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Suggested Courses

670 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question