Solved

Designing beautiful windows in vb?

Posted on 2002-07-11
8
388 Views
Last Modified: 2010-05-02
I want to design a beautiful windows in my
vb application. For example like windows media player,
Real player etc. How can I desing beautiful windows like
that. Curly edges, beautiful buttons with beautiful colors. I also want to know how can I animate
a running piglet or running horse when user waits
after he clicks on a command button for copying
files etc..
I need real world solution.

I can appreciate your help.

Suresh
0
Comment
Question by:sureshpodaralla
[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
8 Comments
 
LVL 16

Expert Comment

by:Richie_Simonetti
ID: 7146700
Hi, you need to manage GDI API to get your wishes.
There is a plenty of resources for that in Internet.
Take a look at www.planet-source-code.com 
www.freevbcode.com 
or simply do a search at www.google.com
0
 
LVL 22

Expert Comment

by:rspahitz
ID: 7146855
One way to create the nice buttons is to simply use an image control and treat it like a command button.

First, you'll need at least two versions of the button image: one for the button in the up position, and one in the down position, and maybe one when disabled.

After that, you'll have to intercept the mousedown and keydown events to see if the button was activated.  If so, change to the "down" image.  On mouseup and keyup, revert to the "up" image.  In the click procedure, run your activate code as though it were a button click.

Private mstrPath As String

Private Sub Form_Load()
  mstrPath = "C:\Documents and Settings\[username]\My Documents\My Pictures\"' maybe just "images\"
  Set Image1.Picture = LoadPicture(mstrPath & "Information.gif")
End Sub

Private Sub Image1_Click()
  MsgBox "button clicked"
End Sub

Private Sub Image1_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
  Set Image1.Picture = LoadPicture(mstrPath & "Question.gif")
End Sub

Private Sub Image1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  If Button <> 0 Then
    If X > 0 And X < Image1.Width _
    And Y > 0 And Y < Image1.Height Then
      If Not mbMouseOverImage Then
        Set Image1.Picture = LoadPicture(mstrPath & "Question.gif")
        mbMouseOverImage = True
      End If
    Else
      If mbMouseOverImage Then
        Set Image1.Picture = LoadPicture(mstrPath & "Information.gif")
        mbMouseOverImage = False
      End If
    End If
  End If
End Sub

Private Sub Image1_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
  Set Image1.Picture = LoadPicture(mstrPath & "Information.gif")
End Sub

BTW
This would be much better served through a user-defined control.
--
For animations, you'll either need to set a timer that does similar to the above button example, but activated by the timer rather than mousedown/up, or again, create a user control to handle it.
0
 

Author Comment

by:sureshpodaralla
ID: 7146951
rspahitz, You are talking about buttons only.
How can I design a window. Normally all vb windows
are rectangle or square windows. I really need to design
a window with edges rounded or parabolice etc...
Do you think that windows media player designed the way
you explained?

Suresh
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 22

Expert Comment

by:rspahitz
ID: 7146963
You asked four questions combines into one:

How can I design:
1) beautiful windows like
that. Curly edges,
2) beautiful buttons
3) with beautiful colors
4) how can I animate


I answered #2 & #4
#3 is in the eye of the beholder.

For #1, if you do a search in the EE database, you will find references to making odd-shaped windows in VB. (Search for "transparent windows" or "rounded windows".)
0
 
LVL 16

Accepted Solution

by:
Richie_Simonetti earned 100 total points
ID: 7146999
0
 

Expert Comment

by:jhamlett
ID: 7147069
If you are referring to putting a skin on a window, there are some components you can buy that will let you skin your application. I quick search on the net for "skins" will give you plenty of pages to read. ActiveSkin is one I have tried, there may be others.
0
 
LVL 3

Expert Comment

by:ketapillar
ID: 7147351
0
 
LVL 16

Expert Comment

by:Richie_Simonetti
ID: 7149330
Thanks for "A" grade. Glad to help you again.
Cheers
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

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

There are many ways to remove duplicate entries in an SQL or Access database. Most make you temporarily insert an ID field, make a temp table and copy data back and forth, and/or are slow. Here is an easy way in VB6 using ADO to remove duplicate row…
Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

733 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