Search:
Type: Posts; User: nicnicman
Search:
Search took 0.21 seconds.
-
Okay. So something like this:
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
Dim circles() As OvalShape = {OvalShape1,...
-
When a shape from PowerPacks is dragged onto the form a ShapeContainer is created and the shape is added to it. It also seems that each shape is automatically assigned an index in the...
-
Pardon my ignorance, but I'm not sure how to do this.
Dim circle As SimpleShape = Me.ShapeContainer1.Shapes(start)
circle.BackColor = color
-
Okay, I thought OvalShapes were a Control. It seems that they do have a BackColor property though.
-
Although, I am still having problems when I want to change the property using a variable. Which is why I was trying to use the index. I also tried it like this:
Me.Controls.OvalShape("circle" &...
-
This works fine:
circle0.BackColor = color
circle0 is an OvalShape.
-
This is for a Connect 4 game. I have a RectangleShape and 42 OvalShapes on a form drawn using PowerPacks. I need to light up the OvalShapes (either red or black) in sequence.
-
I'm trying to color an OvalShape using its index in the shape container. When I added the OvalShapes in Design view I saw a property for BackColor, so that's why I used it. I tried to set the...
-
When I turn Option Strict off or there is no error. Capitalizing didn't help. Thanks for trying.
-
For some reason VS is giving me a number of late binding errors: "Option Strict On Disallows Late Binding".
Here is a sample of the code:
If position(start) = status.empty Then
...
-
I fixed my latest issue by using RectangleShapes instead of Panels.
-
I guess that's why nothing was happening. Thanks for the info.
-
I've tried using a timer but I'm getting some side effects:
In the Connect 4 game I'm using 7 vertical Panels with 7 mouseEnter and 7 mouseClick events so that when the mouse enters any portion of...
-
Nice! It worked.
Me.ShapeContainer1.Shapes(x).invalidate()
Update()
-
I think I spoke too soon. When I run the following code for some reason it doesn't sleep once during each loop it seems to add them all up and do one long sleep before it changes the properties of...
-
Just got this working, too. I think I'm all set now.
For x As Integer = 0 To 6
Me.ShapeContainer1.Shapes(x).BackColor = Color.Red
Next
-
Well I got this code to work:
For Each circle As OvalShape In Me.ShapeContainer1.Shapes
circle.BackColor = color.red
Next
It's not really what I was looking for but I...
-
This code throws the same exception:
Private Sub Form1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Click
For x As Integer = 1 To 7
...
-
For some reasons VS says x is Nothing, but I'm not sure why.
-
Okay, the reason I was seeing the OvalShape object in IntelliSense is because I didn't Import PowerPacks.
Imports Microsoft.VisualBasic.PowerPacks
However, I'm still getting an exception with...
-
I'm working on a Connect 4 game. I created a rectangle with 42 holes punched out of it (drawn in Panels Paint event) and I have 42 circles (created with PowerPacks) placed in each punch out. Right...
-
I see some clipping around the circle. I think this is what jm was referring to. No big deal though.
-
Yup, you're method got rid of the trailing. Thanks.
-
-
I think the I need to enlarge the rectangle that I am invalidating. That may get rid of the trail. I remember reading something about it in one of jmcilhinney's posts.
-
That works great, BB, but there is a lot of flickering.
With Invalidate and Update I get less flickering but also a trail behind the circle.
Me.Invalidate(CircleRect)
Update()
...
-
I guess just changing the color of the circles in sequence will be enough to give the illusion of pieces falling.
-
Oh, that makes things much more difficult than I expected. Hmm. . . how can I get the effect of falling tiles for my Connect 4 Game?
-
Well, for simplicity the circles were drawn in design view using Visual Basic Power Packs.
-
Thanks a lot BB! This works wonderfully.
Is it possible to make the shape created the top most object on the screen? This is for a Connect 4 game: I have a rectangle with 49 holes in it and...
-
Okay, I'll take a look.
Thanks.
-
If I drew a rectangle using e.Graphics.FillRectangle() is there a way I could punch transparent holes in it?
Thanks for any feedback.
-
Maybe this isn't such a good idea for a project.
-
I didn't realize this. It might be better to check out kevin's link.
-
This should work:
Public Class Form1
Private Sub TextBox1_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles TextBox1.KeyPress
If...
-
For a class project I am thinking of doing a Spelling Bee game.
I would like to have a button that will place the word in a sentence, and a button that will give the definition. Are there .txt...
-
-
I did think of doing that...after the project was all done :) I might still edit it though. Thanks for the suggestion.
-
Thanks, jmcilhinney, this is what I went with.
-
I'm thinking it'd be easier to just loop through each letter with a For, Next loop.
|
Click Here to Expand Forum to Full Width
|