473,372 Members | 1,188 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,372 software developers and data experts.

Image in toolbar disappeared

after I changed the image size. I tried different
combinations of images sizes and button sizes. I have
tried both botton and the image in the same sizes or
button size was larger than that of image. The images
were still invisible. What is the trick? I asked this
question a while ago. Thanks.

Nov 20 '05 #1
9 1771
* "Hugh" <an*******@discussions.microsoft.com> scripsit:
after I changed the image size. I tried different
combinations of images sizes and button sizes. I have


I don't think that this is caused by a wrong button size.

Can you post the complete code of the form where the images don't
appear?

--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/>
Nov 20 '05 #2
Hi Herfried,

There is no code. The settings are in property window. The
code itself is very large. let me try to see if Ican
reproduce the problem in a simple code and post the code
late. Thanks for offer.

Hugh
-----Original Message-----
* "Hugh" <an*******@discussions.microsoft.com> scripsit:
after I changed the image size. I tried different
combinations of images sizes and button sizes. I have
I don't think that this is caused by a wrong button size.

Can you post the complete code of the form where the

images don'tappear?

--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/>
.

Nov 20 '05 #3
* "Hugh" <an*******@discussions.microsoft.com> scripsit:
There is no code. The settings are in property window. The
code itself is very large. let me try to see if Ican
reproduce the problem in a simple code and post the code
late. Thanks for offer.


OK.

--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/>
Nov 20 '05 #4
Hi Herfried,

I deleted all code and objects on the designer except for
toolbar in my application, the images in the toolbar were
still invisible in debugging mode. This drives me crazy.
Following is the code generated my window. Thanks very
much.

Hugh

Public Class MainForm
Inherits System.Windows.Forms.Form
#Region " Windows Form Designer generated code "

Public Sub New()
MyBase.New()
'This call is required by the Windows Form
Designer.
InitializeComponent()
'Add any initialization after the
InitializeComponent() call
End Sub

'Form overrides dispose to clean up the component list.
Protected Overloads Overrides Sub Dispose(ByVal
disposing As Boolean)
If disposing Then
If Not (components Is Nothing) Then
components.Dispose()
End If
End If
MyBase.Dispose(disposing)
End Sub

'Required by the Windows Form Designer
Private components As System.ComponentModel.IContainer

'NOTE: The following procedure is required by the
Windows Form Designer
'It can be modified using the Windows Form Designer.
'Do not modify it using the code editor.
Friend WithEvents ToolBar1 As
System.Windows.Forms.ToolBar
Friend WithEvents tbNew As
System.Windows.Forms.ToolBarButton
Friend WithEvents ToolBarImageList As
System.Windows.Forms.ImageList
Friend WithEvents tbRemove As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbFillGrid As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbPrint As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbExit As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbGemini As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbOpenFile As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbBlack As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbDelete As
System.Windows.Forms.ToolBarButton
Friend WithEvents ofdFileSets As
System.Windows.Forms.OpenFileDialog
Friend WithEvents tbMethodFile As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbHelp As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbDeckLayout As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbAbout As
System.Windows.Forms.ToolBarButton
<System.Diagnostics.DebuggerStepThrough()> Private Sub
InitializeComponent()
Me.components = New System.ComponentModel.Container
Dim resources As System.Resources.ResourceManager
= New System.Resources.ResourceManager(GetType(MainForm) )
Me.ToolBar1 = New System.Windows.Forms.ToolBar
Me.tbNew = New System.Windows.Forms.ToolBarButton
Me.tbOpenFile = New
System.Windows.Forms.ToolBarButton
Me.tbRemove = New
System.Windows.Forms.ToolBarButton
Me.tbFillGrid = New
System.Windows.Forms.ToolBarButton
Me.tbMethodFile = New
System.Windows.Forms.ToolBarButton
Me.tbGemini = New
System.Windows.Forms.ToolBarButton
Me.tbPrint = New System.Windows.Forms.ToolBarButton
Me.tbDeckLayout = New
System.Windows.Forms.ToolBarButton
Me.tbBlack = New System.Windows.Forms.ToolBarButton
Me.tbDelete = New
System.Windows.Forms.ToolBarButton
Me.tbExit = New System.Windows.Forms.ToolBarButton
Me.tbAbout = New System.Windows.Forms.ToolBarButton
Me.tbHelp = New System.Windows.Forms.ToolBarButton
Me.ToolBarImageList = New
System.Windows.Forms.ImageList(Me.components)
Me.ofdFileSets = New
System.Windows.Forms.OpenFileDialog
Me.SuspendLayout()
'
'ToolBar1
'
Me.ToolBar1.Buttons.AddRange(New
System.Windows.Forms.ToolBarButton() {Me.tbNew,
Me.tbOpenFile, Me.tbRemove, Me.tbFillGrid,
Me.tbMethodFile, Me.tbGemini, Me.tbPrint, Me.tbDeckLayout,
Me.tbBlack, Me.tbDelete, Me.tbExit, Me.tbAbout, Me.tbHelp})
Me.ToolBar1.ButtonSize = New System.Drawing.Size
(20, 19)
Me.ToolBar1.DropDownArrows = True
Me.ToolBar1.Font = New System.Drawing.Font
("Microsoft Sans Serif", 7.8!,
System.Drawing.FontStyle.Regular,
System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.ToolBar1.ImageList = Me.ToolBarImageList
Me.ToolBar1.Location = New System.Drawing.Point(0,
0)
Me.ToolBar1.Name = "ToolBar1"
Me.ToolBar1.ShowToolTips = True
Me.ToolBar1.Size = New System.Drawing.Size(376, 31)
Me.ToolBar1.TabIndex = 0
'
'tbNew
'
Me.tbNew.ImageIndex = 0
Me.tbNew.Tag = "New"
Me.tbNew.ToolTipText = "New"
'
'tbOpenFile
'
Me.tbOpenFile.ImageIndex = 1
Me.tbOpenFile.Tag = "Open File"
Me.tbOpenFile.ToolTipText = "Open File"
'
'tbRemove
'
Me.tbRemove.ImageIndex = 2
Me.tbRemove.Tag = "Remove file"
Me.tbRemove.ToolTipText = "Remove entries"
'
'tbFillGrid
'
Me.tbFillGrid.ImageIndex = 3
Me.tbFillGrid.Tag = "Fill Grid"
Me.tbFillGrid.ToolTipText = "Fill Grid"
'
'tbMethodFile
'
Me.tbMethodFile.ImageIndex = 5
Me.tbMethodFile.Tag = "Gemini File"
Me.tbMethodFile.ToolTipText = "Save Gemini File"
'
'tbGemini
'
Me.tbGemini.ImageIndex = 6
Me.tbGemini.Tag = "Gemini"
Me.tbGemini.ToolTipText = "Run Gemini"
'
'tbPrint
'
Me.tbPrint.ImageIndex = 7
Me.tbPrint.Tag = "Print"
Me.tbPrint.ToolTipText = "Print"
'
'tbDeckLayout
'
Me.tbDeckLayout.ImageIndex = 10
Me.tbDeckLayout.Tag = "Deck Layout"
Me.tbDeckLayout.Text = "Deck Layout"
Me.tbDeckLayout.ToolTipText = "Deck Layout"
'
'tbBlack
'
Me.tbBlack.Enabled = False
'
'tbDelete
'
Me.tbDelete.Enabled = False
Me.tbDelete.ImageIndex = 12
Me.tbDelete.Tag = "Delete"
Me.tbDelete.ToolTipText = "Delete source files"
'
'tbExit
'
Me.tbExit.ImageIndex = 11
Me.tbExit.Tag = "Exit"
Me.tbExit.ToolTipText = "Exit"
'
'tbAbout
'
Me.tbAbout.ImageIndex = 9
Me.tbAbout.Tag = "About"
Me.tbAbout.Text = "Software"
Me.tbAbout.ToolTipText = "About Software"
'
'tbHelp
'
Me.tbHelp.ImageIndex = 8
Me.tbHelp.Tag = "Help"
Me.tbHelp.Text = "Help"
Me.tbHelp.ToolTipText = "Help"
'
'ToolBarImageList
'
Me.ToolBarImageList.ImageSize = New
System.Drawing.Size(20, 19)
Me.ToolBarImageList.ImageStream = CType
(resources.GetObject("ToolBarImageList.ImageStream "),
System.Windows.Forms.ImageListStreamer)
Me.ToolBarImageList.TransparentColor =
System.Drawing.Color.Transparent
'
'MainForm
'
Me.AutoScaleBaseSize = New System.Drawing.Size(5,
13)
Me.ClientSize = New System.Drawing.Size(376, 125)
Me.Controls.Add(Me.ToolBar1)
Me.Font = New System.Drawing.Font("Microsoft Sans
Serif", 8.25!, System.Drawing.FontStyle.Regular,
System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.Icon = CType(resources.GetObject("$this.Icon"),
System.Drawing.Icon)
Me.Name = "MainForm"
Me.StartPosition =
System.Windows.Forms.FormStartPosition.CenterScree n
Me.Text = "Test"
Me.ResumeLayout(False)

End Sub

#End Region

End Class
Nov 20 '05 #5
* <Hu**@discussions.microsoft.com> scripsit:
I deleted all code and objects on the designer except for
toolbar in my application, the images in the toolbar were
still invisible in debugging mode. This drives me crazy.
Following is the code generated my window. Thanks very
much.


Mhm... The code looks OK for me. Do you use an application manifest
with "devenv.exe"?

--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/>
Nov 20 '05 #6
Hi Herfried,

I created two more toolbars on the designer and user the
same imagelist for these two toolbars. I can change sizes
of the images and buttons of these two new toolbars and
the images were still visible. However, the images in
origial toolbar were still invisible even I set sizes of
images and buttons of original toolbar the same as those
new toolbars. I think the original toolbar is corrupted
somehow. This is really strange. What do you think?

Hugh
-----Original Message-----
Hi Herfried,

I deleted all code and objects on the designer except for
toolbar in my application, the images in the toolbar were
still invisible in debugging mode. This drives me crazy.
Following is the code generated my window. Thanks very
much.

Hugh

Public Class MainForm
Inherits System.Windows.Forms.Form
#Region " Windows Form Designer generated code "

Public Sub New()
MyBase.New()
'This call is required by the Windows Form
Designer.
InitializeComponent()
'Add any initialization after the
InitializeComponent() call
End Sub

'Form overrides dispose to clean up the component list. Protected Overloads Overrides Sub Dispose(ByVal
disposing As Boolean)
If disposing Then
If Not (components Is Nothing) Then
components.Dispose()
End If
End If
MyBase.Dispose(disposing)
End Sub

'Required by the Windows Form Designer
Private components As System.ComponentModel.IContainer

'NOTE: The following procedure is required by the
Windows Form Designer
'It can be modified using the Windows Form Designer.
'Do not modify it using the code editor.
Friend WithEvents ToolBar1 As
System.Windows.Forms.ToolBar
Friend WithEvents tbNew As
System.Windows.Forms.ToolBarButton
Friend WithEvents ToolBarImageList As
System.Windows.Forms.ImageList
Friend WithEvents tbRemove As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbFillGrid As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbPrint As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbExit As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbGemini As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbOpenFile As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbBlack As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbDelete As
System.Windows.Forms.ToolBarButton
Friend WithEvents ofdFileSets As
System.Windows.Forms.OpenFileDialog
Friend WithEvents tbMethodFile As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbHelp As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbDeckLayout As
System.Windows.Forms.ToolBarButton
Friend WithEvents tbAbout As
System.Windows.Forms.ToolBarButton
<System.Diagnostics.DebuggerStepThrough()> Private SubInitializeComponent()
Me.components = New System.ComponentModel.Container Dim resources As System.Resources.ResourceManager
= New System.Resources.ResourceManager(GetType(MainForm) )
Me.ToolBar1 = New System.Windows.Forms.ToolBar
Me.tbNew = New System.Windows.Forms.ToolBarButton
Me.tbOpenFile = New
System.Windows.Forms.ToolBarButton
Me.tbRemove = New
System.Windows.Forms.ToolBarButton
Me.tbFillGrid = New
System.Windows.Forms.ToolBarButton
Me.tbMethodFile = New
System.Windows.Forms.ToolBarButton
Me.tbGemini = New
System.Windows.Forms.ToolBarButton
Me.tbPrint = New System.Windows.Forms.ToolBarButton Me.tbDeckLayout = New
System.Windows.Forms.ToolBarButton
Me.tbBlack = New System.Windows.Forms.ToolBarButton Me.tbDelete = New
System.Windows.Forms.ToolBarButton
Me.tbExit = New System.Windows.Forms.ToolBarButton
Me.tbAbout = New System.Windows.Forms.ToolBarButton Me.tbHelp = New System.Windows.Forms.ToolBarButton
Me.ToolBarImageList = New
System.Windows.Forms.ImageList(Me.components)
Me.ofdFileSets = New
System.Windows.Forms.OpenFileDialog
Me.SuspendLayout()
'
'ToolBar1
'
Me.ToolBar1.Buttons.AddRange(New
System.Windows.Forms.ToolBarButton() {Me.tbNew,
Me.tbOpenFile, Me.tbRemove, Me.tbFillGrid,
Me.tbMethodFile, Me.tbGemini, Me.tbPrint, Me.tbDeckLayout,Me.tbBlack, Me.tbDelete, Me.tbExit, Me.tbAbout, Me.tbHelp}) Me.ToolBar1.ButtonSize = New System.Drawing.Size
(20, 19)
Me.ToolBar1.DropDownArrows = True
Me.ToolBar1.Font = New System.Drawing.Font
("Microsoft Sans Serif", 7.8!,
System.Drawing.FontStyle.Regular,
System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.ToolBar1.ImageList = Me.ToolBarImageList
Me.ToolBar1.Location = New System.Drawing.Point (0,0)
Me.ToolBar1.Name = "ToolBar1"
Me.ToolBar1.ShowToolTips = True
Me.ToolBar1.Size = New System.Drawing.Size(376, 31) Me.ToolBar1.TabIndex = 0
'
'tbNew
'
Me.tbNew.ImageIndex = 0
Me.tbNew.Tag = "New"
Me.tbNew.ToolTipText = "New"
'
'tbOpenFile
'
Me.tbOpenFile.ImageIndex = 1
Me.tbOpenFile.Tag = "Open File"
Me.tbOpenFile.ToolTipText = "Open File"
'
'tbRemove
'
Me.tbRemove.ImageIndex = 2
Me.tbRemove.Tag = "Remove file"
Me.tbRemove.ToolTipText = "Remove entries"
'
'tbFillGrid
'
Me.tbFillGrid.ImageIndex = 3
Me.tbFillGrid.Tag = "Fill Grid"
Me.tbFillGrid.ToolTipText = "Fill Grid"
'
'tbMethodFile
'
Me.tbMethodFile.ImageIndex = 5
Me.tbMethodFile.Tag = "Gemini File"
Me.tbMethodFile.ToolTipText = "Save Gemini File"
'
'tbGemini
'
Me.tbGemini.ImageIndex = 6
Me.tbGemini.Tag = "Gemini"
Me.tbGemini.ToolTipText = "Run Gemini"
'
'tbPrint
'
Me.tbPrint.ImageIndex = 7
Me.tbPrint.Tag = "Print"
Me.tbPrint.ToolTipText = "Print"
'
'tbDeckLayout
'
Me.tbDeckLayout.ImageIndex = 10
Me.tbDeckLayout.Tag = "Deck Layout"
Me.tbDeckLayout.Text = "Deck Layout"
Me.tbDeckLayout.ToolTipText = "Deck Layout"
'
'tbBlack
'
Me.tbBlack.Enabled = False
'
'tbDelete
'
Me.tbDelete.Enabled = False
Me.tbDelete.ImageIndex = 12
Me.tbDelete.Tag = "Delete"
Me.tbDelete.ToolTipText = "Delete source files"
'
'tbExit
'
Me.tbExit.ImageIndex = 11
Me.tbExit.Tag = "Exit"
Me.tbExit.ToolTipText = "Exit"
'
'tbAbout
'
Me.tbAbout.ImageIndex = 9
Me.tbAbout.Tag = "About"
Me.tbAbout.Text = "Software"
Me.tbAbout.ToolTipText = "About Software"
'
'tbHelp
'
Me.tbHelp.ImageIndex = 8
Me.tbHelp.Tag = "Help"
Me.tbHelp.Text = "Help"
Me.tbHelp.ToolTipText = "Help"
'
'ToolBarImageList
'
Me.ToolBarImageList.ImageSize = New
System.Drawing.Size(20, 19)
Me.ToolBarImageList.ImageStream = CType
(resources.GetObject("ToolBarImageList.ImageStrea m"),
System.Windows.Forms.ImageListStreamer)
Me.ToolBarImageList.TransparentColor =
System.Drawing.Color.Transparent
'
'MainForm
'
Me.AutoScaleBaseSize = New System.Drawing.Size(5,
13)
Me.ClientSize = New System.Drawing.Size(376, 125)
Me.Controls.Add(Me.ToolBar1)
Me.Font = New System.Drawing.Font("Microsoft Sans
Serif", 8.25!, System.Drawing.FontStyle.Regular,
System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.Icon = CType(resources.GetObject ("$this.Icon"),System.Drawing.Icon)
Me.Name = "MainForm"
Me.StartPosition =
System.Windows.Forms.FormStartPosition.CenterScre en
Me.Text = "Test"
Me.ResumeLayout(False)

End Sub

#End Region

End Class
.

Nov 20 '05 #7
No.
-----Original Message-----
* <Hu**@discussions.microsoft.com> scripsit:
I deleted all code and objects on the designer except for toolbar in my application, the images in the toolbar were still invisible in debugging mode. This drives me crazy. Following is the code generated my window. Thanks very
much.
Mhm... The code looks OK for me. Do you use an

application manifestwith "devenv.exe"?

--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/>
.

Nov 20 '05 #8
Hi,

http://support.microsoft.com/default...b;en-us;327154

Ken
----------------------
"Hugh" <an*******@discussions.microsoft.com> wrote in message
news:2f****************************@phx.gbl...
after I changed the image size. I tried different
combinations of images sizes and button sizes. I have
tried both botton and the image in the same sizes or
button size was larger than that of image. The images
were still invisible. What is the trick? I asked this
question a while ago. Thanks.

Nov 20 '05 #9
Your Welcome

Ken
------------
<an*******@discussions.microsoft.com> wrote in message
news:34****************************@phx.gbl...
Hi Ken,
Thanks for the link. I was crazy and called microsoft to
see if it is a reported bug. I received no answer yet.

Hugh
-----Original Message-----
Hi,

http://support.microsoft.com/default.aspx?scid=kb;en-

us;327154

Ken
----------------------
"Hugh" <an*******@discussions.microsoft.com> wrote in

message
news:2f****************************@phx.gbl...
after I changed the image size. I tried different
combinations of images sizes and button sizes. I have
tried both botton and the image in the same sizes or
button size was larger than that of image. The images
were still invisible. What is the trick? I asked this
question a while ago. Thanks.

.

Nov 20 '05 #10

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

Similar topics

4
by: Sam Carleton | last post by:
The subject says it all, how do I go about disableing the image toolbar IE throughts up when you hover over an images? I found some code to disable the right menu, but not the toolbar. Sam
0
by: Simon Harvey | last post by:
Hi everyone, Any help with the following would be very greatfully received. I've been having a lot of problems trying to get the standard winforms toolbar to display my images correctly. The...
0
by: Larry | last post by:
I have a problem where all of my Toolbar Tabs have disappeared in VS2003. I have reloaded VS and I still have no Toolbar Tabs. Does anyone know how to get the standard Toolbar Tabs back? I...
0
by: Hugh | last post by:
Hi there, Only thing changed is "Buttonsize" of the ToolBar", however, the images in the ToolBar disappeared. What else do I need to do to change buttonsize? Thanks very much for your tip. ...
1
by: bkasmai | last post by:
An access 2000 database is used by a number of users on a windows xp professional machine. Users logon to the machine using their own individual windows login name and password. The database is...
4
by: huntingseasonson | last post by:
Hi, I have set up the following page http://gertrudischale.com/cgi/ viewart.pl?lang=en&i=22 to scroll in the same direction one moves the mouse. This works fine -except in IE- where the image tends...
9
by: tshad | last post by:
This was posted before but the message got messed up (all NLs were stripped out for some reason). I have 2 labels that hold the name of different images on my .aspx page. <asp:Label ID="Logo"...
3
by: vaniKanabathy | last post by:
I had used toolbar to replace button usage in program . I had disable the image button in toolbar but it not displayed in a shaded mode when disabled. How can i do it because i want to differentiate...
10
by: rmurgia | last post by:
We have set up a function as listed below to display a custom toolbar used to export data from the report. The function is called from the open event of each report: Function CBShowPrint() ...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
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
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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...

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.