|
I am making a tile view control, but have a couple of snags. I am using a custom control for the tile and adding it to a panel control. I have made a semi transparent control to act as a selection box. Problem is that the selection box doesn't paint over the controls that are added to my user control..ie pic box and leabels. I looked at trying to inherit the listview control and make my own items, but haven't found much to help with the problem. Any ideas?
TIA
|
|
|
|
|
Hi all programmers,
I need a code which converts the XML file to Excel file. I have xml file and a xsl file is related to xml file.
Please help me with it.
Regards, all
|
|
|
|
|
There're two forms running on the MDI Form. From 1 form, how can we process another one?
Thanks!
|
|
|
|
|
<font color=blue>Dim</font> Frm As Form2
Frm = <font color=blue>New</font> Form2( <font color=green>set constructor parameters here</font> )
Frm.ShowDialog() <font color=green>' if you want it modal...</font>
Frm.Show() <font color=green>' Non Modal child frame...</font>
TOXCCT >>> GEII power [toxcct][VisualCalc]
|
|
|
|
|
No, both forms've already running. The way i want is from the first form, we update some controls of the second form (add a new item to a combobox etc..)
Can you help me?
Thanks!
|
|
|
|
|
add a reference of form2 into form1...
TOXCCT >>> GEII power [toxcct][VisualCalc]
|
|
|
|
|
How can I cancel the Form_Unload event? When the user clicks the red X at the top of the screen I want to capture the event and ask if they want to save first. If they do then I want to stop the Unload call. Thanks!
|
|
|
|
|
Private Sub Form_Unload(Cancel As Integer)´
''''If You want to cancel the exit just...
Cancel = 1
End Sub
|
|
|
|
|
|
Hi,
For my multiuser vb.net application i DONT want to use any commercial DBMS.
How do i use flat file system for a multiuser application.
Regards
|
|
|
|
|
Very painfully - it's called Access. You can use your own files too, but...
I abhore using Access, or any other file-based database, for any multiuser system, but some other people have a different opinion. It can be done, but performance stinks, severly limiting scalability.
If your system has an unknown upper limit on the number of users, save yourself the trouble and go with the DMBS up front. You won't have to convert your Access "SQL" to Real "SQL" code later.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
MSDE is free, although it doesn't scale as well as SQL Server 2000. But Dave is right, do it properly, or don't do it at all.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
Google for Sqlite. Its completely filebased, only some kilobytes in size and faster than Access. It has its issues but it can work very well (there is even a native .Net provider for it).
|
|
|
|
|
There is also MySQL wich is becoming widely used and Free.
|
|
|
|
|
I am sure we are all faced with SOX (Sarbenes & Oxly). I am looking for a program that will let me enter a date range and path, then it will create a report that provides me with a list of files that were created and/or modified during this date range. Ideally I would also like to be able to control what file extension the program looks for. Any help is appriciated ... I a newby to .NET.
THANKS!
GuateGerman
|
|
|
|
|
this code is write by vb6 and it convert to vb.net, when I run it, it gets me error. is anybody knows hot to fix this or what should I code it in vb.net? Thanks!
Private Sub clearTextboxes()
Dim txt As System.Windows.Forms.Control
'Set each textbox's value to ""
For Each txt In frmMain.DefInstance.Controls
'UPGRADE_WARNING: TypeOf has a new behavior. Click for more: 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="vbup1041"'
If TypeOf txt Is System.Windows.Forms.TextBox Then txt.Text = ""
Next txt
End Sub
Lisa
|
|
|
|
|
You need to change out the TypeOf statement to something more .NET compatible.
Dim ctrl As Control
Dim txtBox As TextBox
For Each Control In frmMain.Controls
If Control.GetType().Equals(GetType(TextBox)) Then
txtBox = CType(Control, GetType(TextBox))
txtBox.Text = String.Empty
End If
Next
Or something very similar. I wrote this from memory so it may not compile without some tweaks.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
thanks..Dave.
I have another question to ask you. if I created textboxes, do I need to remove them when I use it again? when I resign the iStartIndex and iEndIndex and recall the sub textboxshow(), what should I do to make the second call shows correctly?
Private Sub textboxShow()
setStartIndex()
setEndIndex()
clearTextboxes()
MessageBox.Show(iStartIndex & "," & iEndIndex)
Dim I, J As Integer
Dim sData As Integer = 1
While sData <= iEndIndex
For I = 1 To 6
For J = 1 To 7
Call AddDataShow(sData, I, J)
sData += 1
Next
Next
End While
End Sub
Public Sub AddDataShow(ByVal sText As String, ByVal I As Integer, ByVal J As Integer)
Dim txtDataShow As New TextBox
Dim UserLft, UserTop As Integer
Dim X, Y As Integer
Dim a As Integer
a = sText - iStartIndex
UserLft = 20
UserTop = 80
txtDataShow.Height = 80
txtDataShow.Width = 80
txtDataShow.TextAlign = HorizontalAlignment.Left
txtDataShow.BorderStyle = BorderStyle.FixedSingle
'txtDataShow.BackColor = Color.White
txtDataShow.BringToFront()
If a > 0 And a <= iEndIndex Then
txtDataShow.Text = a
'MessageBox.Show(a)
Else
txtDataShow.Text = ""
End If
If txtDataShow.Text = "" Then
txtDataShow.BorderStyle = BorderStyle.None
Else
txtDataShow.BorderStyle = BorderStyle.FixedSingle
txtDataShow.BackColor = Color.White
End If
txtDataShow.Multiline = True
txtDataShow.ReadOnly = True
X = UserLft + (J - 1) * txtDataShow.Width
Y = UserTop + (I - 1) * txtDataShow.Height
txtDataShow.Location = New Point(X, Y)
'MessageBox.Show(X & "," & Y)
Me.GroupBox1.Controls.Add(txtDataShow)
End Sub
Private Sub clearTextboxes()
Dim ctrl As Control
Dim txtBox As TextBox
For Each ctrl In GroupBox1.Controls
If ctrl.GetType().Equals(GetType(TextBox)) Then
txtBox = CType(ctrl, Control)
txtBox.Text = String.Empty
End If
Next
End Sub
Lisa
|
|
|
|
|
If the code generates textboxes to display data, and you use the same code to display new data, then either, yes, you'll have to delete the old textboxes because your code is going to create a new set of them, or, your code will have to know that it already created all the necessary textboxes and reuse them.
The first option is much easier to implement...
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
how can I remove the dynamic textboxes? I have tried to remove it use controls.remove, but it doesn't work, it just remove all the textboxes when it load, then doing nothing. can you help me see what's wrong with it? Thanks a lot.
Dim tempCtrl As Control
For Each tempCtrl In GroupBox1.Controls
Groupbox1.Controls.Remove(tempCtrl)
Next tempCtrl
Lisa
|
|
|
|
|
You're not checking the type of control your removing. On top of that, you can't modify a collection while your enumerating it, or using For/Each on it. You have to use an array index to do this. But, overall, it works the same as trying to clear the text boxes. Check the type of the control first, then remove it:
Dim ctrl As Control
Dim txtBox As TextBox
Dim i As Integer
For i = 0 to frmMain.Controls.Count - 1
If frmMain.Controls(i).GetType().Equals(GetType(TextBox)) Then
frmMain.Controls.RemoveAt(i)
End If
Next
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
when I run it, it shows this error:
Specified argument was out of the range of valid values.
parameter name: Index 32 is out of range.
but the control.count shows result is 53, why it is out of range?
Lisa
|
|
|
|
|
Hi,
I am aware that the VB.NET environment provides a wizard and associated functionality to faclitate the upgrade of VB 6.0 applications to VB.NET.
I wanted to know if this also works with earlier versions of VB like VB5.0 and 3.0. If not, is there any recommended approach for upgrading such applications?
Thanks for your help!
|
|
|
|
|
Anonymous wrote:
I wanted to know if this also works with earlier versions of VB like VB5.0 and 3.0. If not, is there any recommended approach for upgrading such applications?
I never upgrade from version 5 or 3 of vb to vb.net. But if it is possible, try to upgrade your version 5 or 3 of your vb application to vb6 then upgrade it from vb6 to vb.net.
A thousand mile of journey, begin with the first step.
APO-CEDC
Save Children Norway-Cambodia Office
|
|
|
|
|
I know it doesn't work with VB3. It MIGHT work with VB5, but you'll have to try it. But like the other poster said, you could upgrade the project in VB6 first, then load it into VB.NET. You'll have to clean up the code in VB6 first before you try VB.NET though.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|