|
Increase the width of the TreeView control??
|
|
|
|
|
Hi, Everyone
I have me own web company called HoskWare i am looking for people to work with in building web browsers,
There are many great web browsers these days such as (Internet Explorer 8) - (Mozilla Firefox) - (Opera) and others
How ever i am trying to gather some people so we could make a web browser better that is better than them all put together.
If anyone is interested please contact me at:
MSN - ash-hosk@hotmail.co.uk
Thanks,
|
|
|
|
|
There is a jobs board on this site. Perhaps you could look for employees that way?
And if you do, you might also want to check your grammar. I don't like seeing simple gramatical errors on CVs I'm reviewing and it doesn't make such a good impression the other way around either.
113st4life wrote: I have me own web company
me --> my
113st4life wrote: i am looking
i --> I
113st4life wrote: web browsers,
Sentences end with a full stop, not a comma.
113st4life wrote: such as (Internet Explorer 8) - (Mozilla Firefox) - (Opera) and others
List items in prose a typically demarked by commas. Why are your list items in brackets? Finally, you've not put any puncuation at all to indicate the end of this sentence.
113st4life wrote: How ever
However is all one word.
113st4life wrote: i am
Again, the first person pronoun should be an upper case "I".
113st4life wrote: Thanks,
Your final sign off ends in a comma rather than a full stop.
I would have serious doubts about working for someone that cannot master the basics of communication.
|
|
|
|
|
Colin, you must have terrible trouble dealing with the Yank bastardisation of the language.
I was enlightened by your exception article, thanks.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
I was looking for people to work with me not for a lesson!
I wasn't bothered about all that stuff you said its just a simple message!!
|
|
|
|
|
After long time I opened the Crystal Report
I got the following error message on the line that declared a ReportDocument. In addition, when I tried to open any Crystal Reports that I created in Visual Studio 2005, I got "Crystal Reports ActiveX Designer: Failed to open document." and "Microsoft Visual Studio: Failed to create the Crystal Query Engine." error message.
But before it working properly.
Plzzz Help me. Thanking you
|
|
|
|
|
Hello sir,
I want similar coding for treeview, where for linklabel is as follows.
[CODE]
Private Sub LinkLabel8_LinkClicked(ByVal sender As System.Object, ByVal e As System.Windows.Forms.LinkLabelLinkClickedEventArgs) Handles LinkLabel8.LinkClicked
WebBrowser1.Navigate(Application.StartupPath & "\source\test.html\")
End Sub
[/CODE]
|
|
|
|
|
I solved this, use file name in the tag with this extension and use the below coding
WebBrowser1.Navigate(Application.StartupPath & "\Source\" & e.Node.Tag)
IT Professional.
Work till you get it!
|
|
|
|
|
i need how to use crystal report with vb.i install crystal report 10.
|
|
|
|
|
Given that VB6 was a dead language when CR 10 was written, I doubt this is possible. either way, VB6 was rubbish even when it was supported, why are you using it ?
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
i need the code.how i use crystal report with visual basic 6.i need this code.
|
|
|
|
|
Don't double post just b/c you were incapable of thinking of an intelligent subject. Your posts can be edited.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
I generally code for using VB.NET 2.0 and Visual Studio 2008.
I have a datagrid view bound to a dataset stored in xml file. I have implemented
several custom datagridviewtextboxcell controls - one which displays a box with a
colour beside a number. Another which displays a line of varying width beside it's
value.
These cells are drawn correctly when the value is changed, however when the form is
loaded and the datagriddview filled with data, all the cells are not painted. Only
when I select the cell by clicking does the cell repaint - this has been causing all
sorts of trouble.
I have attempted several workarounds, including a timer tick event hooked to the
invalidate method of the dgv and each displayed cell individually. Any ideas;
I probably have missed something simple.
The sample below is the custom control for the color cell - it will not work right
out of the box as it requires the Autodesk AutoCAD 2008 API
Public Class AcColorCell
Inherits DataGridViewTextBoxCell
<DebuggerNonUserCode()> _
Protected Overrides Sub Paint(ByVal graphics As Graphics, ByVal clipBounds As Rectangle, ByVal cellBounds As Rectangle, ByVal rowIndex As Integer, ByVal elementState As DataGridViewElementStates, ByVal value As Object, _
ByVal formattedValue As Object, ByVal errorText As String, ByVal cellStyle As DataGridViewCellStyle, ByVal advancedBorderStyle As DataGridViewAdvancedBorderStyle, ByVal paintParts As DataGridViewPaintParts)
'formattedValue = Nothing
MyBase.Paint(graphics, clipBounds, cellBounds, rowIndex, elementState, value, formattedValue, errorText, cellStyle, advancedBorderStyle, paintParts)
If Me.RowIndex < 0 Then Exit Sub
Dim ColorBoxRect As New Rectangle(cellBounds.X, cellBounds.Y, cellBounds.Width - 1, cellBounds.Height - 3)
ColorBoxRect.Inflate(-1, -1)
ColorBoxRect.Width = 18
ColorBoxRect.Offset(1, 0)
Dim TextBoxRect As New RectangleF(cellBounds.X + ColorBoxRect.Width + 4, _
cellBounds.Y, cellBounds.Width - 1, cellBounds.Height - 1)
Dim cellBackground As SolidBrush
If Not Me.Value Is DBNull.Value Then
If Me.Value <> 0 Then
Dim AcColor As Autodesk.AutoCAD.Colors.Color
Dim ColorValue As Short = CShort(Me.Value)
AcColor = Autodesk.AutoCAD.Colors.Color.FromColorIndex(Autodesk.AutoCAD.Colors.ColorMethod.ByAci, ColorValue)
Dim r As Byte = AcColor.ColorValue.R
Dim g As Byte = AcColor.ColorValue.G
Dim b As Byte = AcColor.ColorValue.B
Dim Color As Drawing.Color = Drawing.Color.FromArgb(r, g, b)
cellBackground = New SolidBrush(Color)
graphics.FillRectangle(cellBackground, ColorBoxRect)
graphics.DrawRectangle(Pens.Black, ColorBoxRect)
graphics.DrawString(AcColor.ToString, cellStyle.Font, System.Drawing.Brushes.Black, TextBoxRect)
cellBackground.Dispose()
End If
End If
End Sub
End Class
Public Class AcColorColumn
Inherits DataGridViewColumn
Public Sub New()
MyBase.CellTemplate = New AcColorCell
End Sub
End Class
As below, the code for the lineweight control
Public Class AcLineweightCell
Inherits Windows.Forms.DataGridViewTextBoxCell
'skip the following while debugging
<DebuggerNonUserCode()> _
Protected Overrides Sub Paint(ByVal graphics As System.Drawing.Graphics, ByVal clipBounds As System.Drawing.Rectangle, ByVal cellBounds As System.Drawing.Rectangle, ByVal rowIndex As Integer, ByVal cellState As System.Windows.Forms.DataGridViewElementStates, ByVal value As Object, ByVal formattedValue As Object, ByVal errorText As String, ByVal cellStyle As System.Windows.Forms.DataGridViewCellStyle, ByVal advancedBorderStyle As System.Windows.Forms.DataGridViewAdvancedBorderStyle, ByVal paintParts As System.Windows.Forms.DataGridViewPaintParts)
MyBase.Paint(graphics, clipBounds, cellBounds, rowIndex, cellState, value, formattedValue, errorText, cellStyle, advancedBorderStyle, paintParts)
If Me.RowIndex < 0 Then Exit Sub
If Not Me.Value Is DBNull.Value Then
If Me.Value <> "" Then
'Get value of cell
Dim cellvalue As String = Me.Value
'Get AutoCAD lineweight of value
Dim lwconv As AcDb.LineWeightConverter = New AcDb.LineWeightConverter()
Dim lw As AcDb.LineWeight = Nothing
'Get the number of pixels that represent the lineweight
Dim px As Integer = GetLineweightPixel(cellvalue)
'Get rectangle where we can draw the lineweight
Dim lwrect As New Rectangle(cellBounds.X, cellBounds.Y, cellBounds.Width - 1, px)
lwrect.Width = 70
lwrect.Height = px
'Offset the rectangle from the top of the cell to center the lineweight display
lwrect.Offset(0, Math.Round(cellBounds.Height / 2) - CInt(Math.Round(px / 2)))
'Get rectangle where we can draw the cell value
'Dim txrect As New RectangleF(cellBounds.X, lwrect.Width + 4, cellBounds.Width - 1, cellBounds.Height - 1)
Dim newfont As New Font("Tahoma", 8.25, FontStyle.Regular, GraphicsUnit.Pixel)
Dim cellBackground As New SolidBrush(Color.Black)
graphics.FillRectangle(cellBackground, lwrect)
cellBackground.Dispose()
End If
End If
End Sub
black holes happened when God divided by zero
|
|
|
|
|
I suspect the problem is with the event you are using to paint the cells. I have not used custom controls in a gridview but I do paint individual cells accoring the data in the row. Explore RowPrePaint and there is a cell paint event that may work as well.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
Can I Convert PDF file in Crystal Reports in vb.net 2005
Please If any One Have A Solution Please Give Me And Give also the Code how to Convet
Please Help Me One This Topics Please ............
|
|
|
|
|
You can't convert a PDF file to Crystal Report.
|
|
|
|
|
Can I Convet Word file in Crystal Report ?
|
|
|
|
|
No, you can't convert anything to Crystal Report.
|
|
|
|
|
Hi,
How can I create a multiline listview in VB.net(2008)
I converted some code already:
Public Class MultiLineListview
Inherits System.Windows.Forms.ListView
Dim _Font As Font = MyBase.Font
Sub New()
Me.OwnerDraw = True
Me.View = Windows.Forms.View.Details
Me.FullRowSelect = True
Me.HoverSelection = False
End Sub
Protected Overrides Sub OnDrawColumnHeader(ByVal e As System.Windows.Forms.DrawListViewColumnHeaderEventArgs)
e.DrawDefault = True
MyBase.OnDrawColumnHeader(e)
End Sub
Protected Overrides Sub OnDrawSubItem(ByVal e As System.Windows.Forms.DrawListViewSubItemEventArgs)
On Error Resume Next
If e.ItemIndex > -1 And e.ItemIndex < Me.Items.Count Then
Dim sText As String = e.SubItem.Text
Dim sLines() As String = Split(sText, vbCrLf)
If InStr(1, e.ItemState.ToString.ToLower, "selected") > 0 Then
e.Graphics.FillRectangle(SystemBrushes.Highlight, e.Bounds)
Else
e.Graphics.FillRectangle(SystemBrushes.Window, e.Bounds)
End If
e.Graphics.DrawRectangle(SystemPens.Control, e.Bounds)
e.Graphics.DrawString(sText, Me.Font, SystemBrushes.WindowText, e.Bounds.Left, e.Bounds.Top)
End If
MyBase.OnDrawSubItem(e)
End Sub
Protected Overrides Sub OnCreateControl()
On Error Resume Next
Me.Items.Clear()
End Sub
End Class
However I can't change the height of each row
For a listbox this code works fine
Protected Overrides Sub OnMeasureItem(ByVal e As System.Windows.Forms.MeasureItemEventArgs)
On Error Resume Next
If e.Index > -1 And e.Index < Me.Items.Count Then
Dim sSize As SizeF
Dim sText As String = Me.Items(e.Index).ToString()
'Dim sLines() As String = Split(sText, vbCrLf)
sSize = e.Graphics.MeasureString(sText, Me.Font)
e.ItemHeight = sSize.Height '* (sLines.GetUpperBound(0))
End If
MyBase.OnMeasureItem(e)
End Sub
But It won't work for a listview
|
|
|
|
|
First, get rid of the "On Error Resume Next". That stuff has been deprecated and replaced with Try/Catch blocks. Also, eating exceptions and doing nothing with them is really bad practice.
Next, the ListView doesn't expose any kind of MeasureItem event, so it's no surprise that it doesn't work.
As far as I know, the only way to change the item height is to change the ImageList size property to an appropriate size to get the height you want.
|
|
|
|
|
Sorry that I didn't replay sooner!
The on error statement was just copyed from someone else his code. Normely I adapted the code but only after i got it to work. but here for measering a listview item I did not found something working.
So if someone has an option/idee how I can implement the measering of the item(s) it helps me a lot
Thanks
|
|
|
|
|
There is no method exposed by the ListView control that allows you to meaure the item in a given box.
The only way to do it would be to create your own version of the ListView control and replace all the painting code with your own.
Frankly, I'd find it easier, cheaper, and faster, to find a third party control that offers the functionality you need.
|
|
|
|
|
|
Did you manage to find an answer ?
Im looking for a Wordwrap solution to listview using owner draw, just cant find mutch info on it
DB
|
|
|
|
|
No.
Like dave wrote.
this doesn't work for listview
Jan
|
|
|
|
|