473,395 Members | 1,738 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Painting on a Form

I am just trying to paint on a Form.
I tried it with Bitmap.SetPixel, but that didnt work,
now I tried a method from the MS API.

Public Sub DrawRectangleFloat(ByVal e As PaintEventArgs) ' Create pen.
Dim blackPen As New Pen(Color.Black, 3)
' Create location and size of rectangle.
Dim x As Single = 0.0F
Dim y As Single = 0.0F
Dim width As Single = 200.0F
Dim height As Single = 200.0F
' Draw rectangle to screen.
e.Graphics.DrawRectangle(blackPen, x, y, width, height)
End Sub

This method seems to be called by the event "PaintEventArgs".
Unfortunately I haven't yet really that much expierence with those Events.
How do I call that event to get this rectangle drawn, and could I also do it
without an event???
I tried to write Handles behind the method, but whatever I select, it tells
me the signature wasn't fitting.

What I wanted to do in first place:

Drawing a few bars, that represent procentual values.
I had a look on Crystal, but for some strange reasons it didn't work with
the connection to
my db, I guess (MySQL)

Then I downloaded and installed this VBRKit,
but I have no idea how I should use it.

(http://msdn.microsoft.com/vbasic/vbrkit/default.aspx )
----------

Thanks in advance!!!

Stefan

Nov 20 '05 #1
3 985
Assalam O Alaikum,
i have no idea about painting of form.But i used vbrkit. It is simple to use just extract and run setup.It automatically create a virtual directory and it can run from start->programs->vbresourcekit.From here u can run this.You must have IIS installed on your system.

Allah Hafiz.
Nov 20 '05 #2
Hi Stefan,

After downloading the resource kit you can install it, it should normaly
install everything.

There comes than an item in your start menu.

Start and your browswer will be opened. Maximise the window, otherwise it
does not show all.

Then you choose for the windows applicaties and in that for the samples.

The GDI clock (it is at the bottom of the samples) is real great to start
with, even when it was only to look at. However the other GDI samples give
also a lot of information.

If there are still questions, feel free to ask.

Cor
Nov 20 '05 #3
Hi Junaid,

Sorry I was answering messages and overlooked that you did already anwered
this question.

Cor
Nov 20 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Dayne | last post by:
I would like to cancel a windows form from painting in the form's activate event. How do I do this? DT
1
by: Bill K | last post by:
I am developing a winforms project in vb.net. I have several forms that have a number of controls, grids, etc. When I load these as MDI child forms, they load slowly AND they paint/repaint on the...
5
by: Alien | last post by:
I have a hex editor-type class that extends UserControl and paints its data to a PictureBox. Basically the problem is that repainting it takes usually between 60 and 80ms, which may seem pretty...
4
by: Dafü | last post by:
Hello! I have an application that paint graphics in VB.NET. Each graphic is painted after a long calculation process. My problem is when another windows pass over my graphics or I resize the...
7
by: adh | last post by:
How do you temporarly stop the screen painting in VB.NET (alla "echo off" in vb6)? I have a modal form that when closing keeps partial showing. Thanks ADH
0
by: J Rico | last post by:
Hi, I'm having a problem with some code we're writting. Our customer doesn't like windows forms style painting, so their designer has created a skin and we have added it. There are many ways in...
0
by: Halimaji Nijazi | last post by:
Hi everybody On my form I have a procedure, which moves some textboxes and buttons... then it makes some validations... after this it moves the objects again. So far so good... But now I have...
2
by: Halimaji Nijazi | last post by:
Hi everybody On my form I have a procedure, which moves some textboxes and buttons... then it makes some validations... after this it moves the objects again. So far so good... But now I have...
4
by: Marina Levit | last post by:
I am trying to do some processing on a background thread while keeping the UI painting. However, this is a generic server side call routine - and it needs to block until the server side call...
5
by: lazyvlad | last post by:
Hi, I'm writing here because this issue is becoming more annoying with each day it passes. So I have a form, a dataset with a few table adapters (3 to be precise) and a datagridview.The datagridview...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.