Can you link the color value during loading of the data from database?.
This way you have a column containing the needed color for that row. You can hide the color column.
Then using the cellformating to show the color.
Hi,
Have you looked at the cellformatting of the datagridview?
If your column has always the same name you can use maybe this code.
Private Sub dgvOverview_CellFormatting(ByVal sender As Object, ByVal e As System.Windows.Forms.DataGridViewCellFormattingEventArgs) Handles...
Oke solved my problem. Atleast for now. :-)
I had my code in Datagridview.SelectionChanged event.
Now I moved is to the MouseClick event.
So far it seems to be working.
I did but that is not working.
With that command you clear any selection.
So no row would be selected after that.
I want the selection to return to the previous row.
Hi,
Probably a basic thing but how can you cancel the row selection in a datagridview?
Used google but probably used the wrong words because I was unable to find the answer I am looking for.
What I want to do is when user selects a row it first needs to check if there are unsaved data in the...
Hi,
I have a strange problem that I can't seem to solve.
Using VB.net 2005
On a form I have a comboboxen that is populated thru datatables.
One combobox hold names of relations of the company
Valuemember is set to ID column (relatieID)
Displaymember is set to the relationname (RelatieNaam)...
ICTECH,
Would suggest to step through your program to see if your code is run or not because it should be working with your code.
No need to redraw the screen.
Greetings,
Ernst Jan
Hi ICTECH
When you use the menustrip you can call the items by design name.
So when you name the Item "User Manager" for example miUserManager you can simple put
miUserManager.Visible = True
Or ofcourse
miUserManager.Visible = False.
Greetings
So the name
Hi Sorwen,
I am not compleet sure but I think this is the line where it goes wrong.
_GraphicsPath.AddLine(Rect.Width, CornerSize, (Rect.Width + 40), Rect.Height - CornerSize)
You want to go down, but the X values are diffrent and should be the same.
(Rect.Width + 40) Should be Rect.Width...
Hi,
I use the following code in VS2005 to format a datagridview to the wishes of the user.
With dgvOverzicht
.DataSource = dsGegevens.Tables("Overzicht")
.AutoGenerateColumns = False
.AllowUserToResizeColumns = True
For Each varColumn As DataColumn In...
Hi Basbrian,
To open a word template you can use.
Change this
docWord = appWord.Documents.Open("q:\computer.adm\basbrian\delegation.dot")
to this
docWord = appword.Documents.Add(Template:="q:\computer.adm\basbrian\delegation.dot", newtemplate:=False, Documenttype:=0)
Don't have the time...
Found a solution for my problem.
It's not perfect but it's working.
The scrollbar has a maximum value.
That value I divided by the total number of rows and place it in a variable.
In the scroll event of the custom scroll bar I placed this
Private Sub dgvScrollBar_Scroll(ByVal sender As...
Mansii,
Thank you for your response.
Unfortunally it's a partial solution.
I can now scroll with the scroll bar but bar is not showing the way the orginal scrollbar would show it.
What I am trying to do is to mimic the vertical scrollbar of the datagridview.
'Scroll balk aanmaken...
Some info up front.
Have a panel(pnlMain) containing a datagridview and an other panel (pnlFilter).
pnlFilter contains textboxes to filter the data in the datagridview.
Also the width of the textboxes are synchronized with the width of the colums of the datagridview.
To keep the textboxes lined...
Oke, Solved my problem by doing what i did not want to do.
Build a view with links to members table.
Also I changed the way I save the color. (Was in Argb).
Now I save the RGB as a string like 255128000.
First 3 = R, Middle 3 = G and last 3 = B.
Build the formula like this
Numbervar R :=...
Thanks for looking in to this.
Really appricate it.
Can you maybe help me also with the second part of this problem.
My query has only the ID number of the person on duty.
Don't want to make a query with a lot of links.
Can you let the report look up a record in a table?
Ofcourse there will be...
The current format in the database is float.
Had found a peace of code for VB.net to convert this into RGB
Dim C As Integer = IIf(txtWaardeIn.Text = String.Empty, -1, txtWaardeIn.Text)
Dim R As Integer = C And 255 ' Get lowest 8 bits - Red
Dim G As...
Oke hope it will be clear. If not let me know.
What I have is an VB.net application.
Part of the application is a rooster to see which person is on duty. That will be one person per day.
I have build is so that people can choice a color representing that person. For the color choice I us the...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.