listbox column head format backcolor - ms-access-2007

I need to set the entire column head in the list box to bold
and color. So I created a list box, and in the list box property under
column heads I selected yes, how can I make this list box bold without
effect the rest of the data in the list.

You can't do it as far as I know. The only alternative I can offer is a method I use. You make your list box wide enough that it doesn't scroll horizontally and put labels right above it.
Remember to leave the last column a little wider than you need to account for the scroll bar.

Related

VB.net: highlight full row without affecting cell backcolor

datagrid
hi guys, Good day! I'm doing a ticketing system with color code in 1st and 2nd column in my datagrid. My question is, how can I fullrowselect my datagrid without affecting the back color of my datagrid in 1st and 2nd column. Please see my image sample
dataGridView.DefaultCellStyle.SelectionBackColor is used to control this color. So set that to your prefered colors. There is more information on this here: https://msdn.microsoft.com/en-us/library/1yef90x0.aspx
You may need to do it dynamically if you're customizing the background colors so you could handle the CellFormatting event and make the changes in there.

Excel expand text horizontally down instead of vertically to the right

The default behavior is that text overflows to the right into the next cells, is there a way to change this to make the text flow downward to cells below the same way as it flows to the right?
Right click on the cell and choose the Format option. Click on the Alignment tab. You can change the Horizontal Text alignment to Fill. Only the text that fits will be displayed, the overflow will be hidden.
Or, you can check the Wrap text box, the text will wrap vertically increasing the height of the cell.
I see no option to overflow down.
The only way that I know of is to merge the cells vertically. Merge enough cells and you will reveal all of the text. Brute force approach, but it works.
I can suggest settings that you have to keep in cell alignment tab.
here is how you can make sure the settings should look like.

Draw border around controls on VBA Userform without using a Frame?

I am designing a VBA UserForm (in Excel, if it is relevant) and I would like some controls to be visually grouped together.. but when I put them in a frame, I am getting some undesired results (part of it has to do with the RefEdit control which seems to be particularly unhappy inside a frame).
Is there a way to draw a border around a group of controls on a form without putting them inside a Frame?
Use a label with the caption deleted and the border style set to fmBorderStyleSingle. It may appear on top of your other controls, so right click on it and select "send backwards" until it's behind your other controls.
The best way to do this would be to create the shape over where you need it to be. Drag highlight everything that you want on top of it, then right click and brink it all forwards. Then when you drag your shape back over the top it will in fact be underneath everthing else.
Hope that helps.
This worked for me and I was at first having the same issue where I had to choose to "Send Backward" up to 30 times per label in some cases. I found that hitting the Ctrl-K sends it to the back of all controls with one time hitting these keys.

In VB.NET, can we draw empty lines instead of blank area in non existent row of datagrid?

EDITED:
I think we can just draw an image that resemble the grid using this article : drawing in a datagridview Currently creating a way to make the image drawn in tile mode. :)
Each time I develop a datacentric application using VB.NET regardless of how much the data displayed in the datagrid, I always want the grid to display full row of empty data, not just blank panel.
Can we achieve this using VB.NET design time property?
And also, we must not trigger the display of vertical scrollbar this way.. :)
Thanks
You might try doing a screen capture of the dgv when it is full of blank lines and use that as your background. However, you'll have a problem with the vertical lines if they resize the columns. In your picture you don't have any vertical lines so if you don't need them then just erase them and your problem is solved.
There's also the option of using the Virtual Mode. When you set that property to true then you can set the number of visible rows, but you are responsible for telling the dgv what each individual cell is supposed to contain: http://msdn.microsoft.com/en-us/library/2b177d6d.aspx
Or you can just add extra blank rows to whatever datasource you are setting your DGV to.
Use the ScrollBars property to turn the vertical scroll bar off.

Grouping Controls in Pairs vb.net windows.forms - Dynamic List in grid format

I have pairs of controls: immagebox + textbox = one pair.
I want these to show up in a single column grid/tabular format. Each cell contains one image/text pair.
I want this grid to scroll because the number of pairs is dynamic depending on a user selection.
I suppose I will be adding these controls in code at runtime when the user makes his/her selection.
What is the best way to accomplish that in vb.net? TableLayoutPanel or better way?
One possible approach is the following.
Use a Panel as your container. Inside this Panel you can add a TableLayoutPanel that is defined to be AutoSize=True. Add two columns to your table layout and then add controls in rows as needed. The TableLayoutPanel will then size itself automaticlly depending on the contents.
Now make your Panel be AutoScroll=True and it will automatically add the correct scrollbars so the user can move around and see the contained set of controls.