|
The way that the Explorer Bar in My Computer works is different to the way that you are trying to do it.
In My Computer clicking the button on Panel 3 hides the content of panel 3, it does not hide panel 2.
Do you want to continue doing it the way you are, or do you want to do it like the ExplorerBar actually does it?
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
I want like Standard ExplorerBar.Please i need the code of when one panel shrink or unexpand, the others panels comes towards up..
Waiting for ur reply
Thanks a lot
|
|
|
|
|
OK.
This could take a long time, because it is quite complicated.
All of the ExplorerBar implementations I have seen have a Control that acts as the host for the XPPanels. It is this Host control that maintains a list of it's XPPanels and organizes them when one shrinks or grows.
It goes something like this.
The XPPanel Control has an event (just for this explanation I'll call it PanelSizeChanged).
The host control overrides the OnControlAdded method something like this
Protected Overrides Sub OnControlAdded(ByVal e As System.Windows.Forms.ControlEventArgs)
MyBase.OnControlAdded(e)
If e.Control Is XPPanel Then
newPanel As XPPanel = e.Control
Me.panels.Add(newPanel) ' panels is a collection in the host control for keeping track of XPPanels
AddHandler newPanel.PanelSizeChanged, New XPPanelSizeChangeHandler(AddressOf Me.SizeChangeMethod)
' and whatever else needs doing
End If
End Sub
Now whenever a XPPanel changes size the host runs the SizeChangeMethod. In that method it starts with the XPPanel that changed (the sender from the ByVal sender As System.Object parameter), finds its index in the panels collection and makes a note of where its bottom is (something like lastBottom AS Int32 = panels(index).Bottom ).
Then it gets the next XPPanel and sets its top to be lastBottom plus whatever you choose as the gap between panels, after that it sets lastBottom to equal the bottom of this XPPanel. Then it gets the next panel, repeats the above until it has dealt with all the panels.
If you do not know how to raise Events or create EventHandlers, you will need to do some research on that before proceeding.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
Dear All,
Our requirement is a cab has assigned to Pick and Drop the employee for each and every shifts for the selective date. So, we need to show how much distance a cab has travelled, then we need to show that cab has been assigned for Pick/Drop for all the selective date.
As per my Procedure we can get the "Shift Date Time", "Cab No", "Pick/Drop" value, etc....
In Range chart I need to show the "Shift Time" in "X Axis" like "9 AM", "10 AM", "11 AM".....upto Next day "8 AM".
then In "Y Axis" I need to show "Shift Date Time" & "Cab No." which come from table.
In "Y Axis" i can not show the "Shift Date Time", So, I tried to show in "X Axis", but I can show only shift Date not time.
Actually I need to show the shift date in "Y Axis" only.
If any one have the solution, Please reply me.
Thanks in Advance.
Regards,
Jegan.K
9994388922
Jegan
|
|
|
|
|
Hello, I like to make a simple application which can execute mail-merge that I've made before using ms word. The application load that document, then I can fill the merge-field from the datagridview in vb.net. Can someone help me, I need some references or maybe final source-code. I've searched through google, but I couldn't find it. Projects that were found there using database as the datasource (not datagridview).
Thanks,
Indra Permana Rusli
- No Signature Available -
|
|
|
|
|
hi,i am trying to design a property grid that consisits of multiple drop downs of user defined and move those values selected to a variable in back end vb.net code and perform some matha matical calculations.
But i am not able to create multiple dropdowns in single group can any one help?
modified on Tuesday, June 23, 2009 7:34 AM
|
|
|
|
|
That's great news. Why are you telling us this ? Did you have a specific problem ? You should tell us what it is, and post some code so we can help.
Christian Graus
Driven to the arms of OSX by Vista.
"! i don't exactly like or do programming and it only gives me a headache." - spotted in VB forums.
I can do things with my brain that I can't even google. I can flex the front part of my brain instantly anytime I want. It can be exhausting and it even causes me vision problems for some reason. - CaptainSeeSharp
|
|
|
|
|
above i modified my question in proper way.
My main problem is i am creating multiple drop downs using class for each dropdown.i created one drop down but i can not able to create multiple.
Getting error called base class have multiple definetions. code i am trying for drope down is:
Imports System.ComponentModel
Public Class MotoList1 : Inherits System.ComponentModel.StringConverter
'''
'''
Private _Title As String
Private _Show As Boolean
Private _Number As Short
'''
<CategoryAttribute("Other Inputs"), _
Browsable(True), _
[ReadOnly](False), _
BindableAttribute(False), _
DefaultValueAttribute(""), _
DesignOnly(False), _
DescriptionAttribute("Enter Title for the application")> _
Public Property Title() As String
Get
Return _Title
End Get
Set(ByVal Value As String)
_Title = Value
End Set
End Property
'''
<CategoryAttribute("Other Inputs"), _
Browsable(True), _
[ReadOnly](False), _
BindableAttribute(False), _
DefaultValueAttribute("True"), _
DesignOnly(False), _
DescriptionAttribute("Show option")> _
Public Property Show() As Boolean
Get
Return _Show
End Get
Set(ByVal Value As Boolean)
_Show = Value
End Set
End Property
'''
<CategoryAttribute("Other Inputs"), _
Browsable(True), _
[ReadOnly](False), _
BindableAttribute(False), _
DefaultValueAttribute("0"), _
DesignOnly(False), _
DescriptionAttribute("Enter a number")> _
Public Property Number() As Short
Get
Return _Number
End Get
Set(ByVal Value As Short)
_Number = Value
End Set
End Property
Dim _Motor1in As String() = New String() {"400", "500"}
Public Overloads Overrides Function GetStandardValues(ByVal context As System.ComponentModel.ITypeDescriptorContext) As System.ComponentModel.TypeConverter.StandardValuesCollection
Return New StandardValuesCollection(_Motor1in)
End Function
'''
Public Overloads Overrides Function GetStandardValuesSupported(ByVal context As System.ComponentModel.ITypeDescriptorContext) As Boolean
Return True
End Function
'''
Public Overloads Overrides Function GetStandardValuesExclusive(ByVal context As System.ComponentModel.ITypeDescriptorContext) As Boolean
Return True
End Function
'''
End Class
here while am trying to create another drop down --GetStandardValues-- i got error as function can not be over ride
that is the my problem
|
|
|
|
|
i have written this code for adding the values in to the database
i m using vb6 and Microsoft Access
i m gettin an error " SYNTAX ERROR IN INSERT INTO STATEMENT "
PLS HELP ME...
Private Sub Command1_Click()
Dim db As New ADODB.Connection
Set db = New ADODB.Connection
Dim adoRecordset As ADODB.Recordset
Set adoRecordset = New ADODB.Recordset
Dim sSQL As String
Dim name As String
Dim number As String
Dim qualification As String
Dim experience As String
Dim phone_no As String
Dim dealer As String
name = Text1.Text
number = Text2.Text
qualification = Text3.Text
experience = Text4.Text
phone_no = Text5.Text
dealer = Text6.Text
sSQL = "INSERT INTO datatable (Name, Number, Qualification, Experience, Phone_No, New_Dealer) values('name','number', 'qualification', 'experience', 'phone_no', 'dealer')"
db.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Documents and Settings\helpdesk-ngp\My Documents\sp\dataend.mdb;Persist Security Info=False"
adoRecordset.Open sSQL, db, adOpenDynamic, adLockOptimistic
adoRecordset.Close
End Sub
spruhas
|
|
|
|
|
instead of this
sSQL = "INSERT INTO datatable (Name, Number, Qualification, Experience, Phone_No, New_Dealer) values('name','number', 'qualification', 'experience', 'phone_no', 'dealer')"
you will have to construct a string like this
sSQL = "INSERT INTO datatable (Name, Number, Qualification, Experience, Phone_No, New_Dealer) values('" & name & "','" & qualification .....etc
as name,qualification are variables
cheers
TheMrProgrammer
|
|
|
|
|
i m still getting the same error
at this line
adoRecordset.Open sSQL, db, adOpenDynamic, adLockOptimistic
purvas
|
|
|
|
|
It's obvious you have no idea what you're doing. I therefore assume you're new to VB6. VB6 is unsupported, and was always garbage. Abandon it if you can, and learn a real language, or, at least, VB.NET.
Christian Graus
Driven to the arms of OSX by Vista.
"! i don't exactly like or do programming and it only gives me a headache." - spotted in VB forums.
I can do things with my brain that I can't even google. I can flex the front part of my brain instantly anytime I want. It can be exhausting and it even causes me vision problems for some reason. - CaptainSeeSharp
|
|
|
|
|
Change your SQL Statement like this
sSQL = "INSERET INTO datatable (Name, Number, Qualification, Experience, Phone_No, New_Dealer) VALUES ('" & Name & "','" & Number & "','" & qualification & "','" & experience & "','" & phone_no & "','" & dealer & "'"
|
|
|
|
|
i have changed but still get the same error at this line
adoRecordset.Open sSQL, db, adOpenDynamic, adLockOptimistic
purvas
|
|
|
|
|
NAME and NUMBER are reserved keywords in Microsoft Access and you should avoid using them as column names. The best solution is to rename the columns in your table to something like DEALER_NAME and DEALER_NO. If you can't rename the columns, then you can change your insert statement to
INSERT INTO datatable ([Name], [Number], Qualification... etc. But that is a workaround, not a real fix. Much better in the long run to fix it properly.
|
|
|
|
|
THANK YOU EVERY BODY
THE PROBLEM IS SOLVED
purvas
|
|
|
|
|
Hello,
I would like to know how to work with OpenGL with Visual Basic .Net.
Thanks
|
|
|
|
|
|
how I can use with cluse in sql 2005?
bah10z
bah10z
|
|
|
|
|
We have a SQL forum. You can also look here[^]
Christian Graus
Driven to the arms of OSX by Vista.
"! i don't exactly like or do programming and it only gives me a headache." - spotted in VB forums.
I can do things with my brain that I can't even google. I can flex the front part of my brain instantly anytime I want. It can be exhausting and it even causes me vision problems for some reason. - CaptainSeeSharp
|
|
|
|
|
clouse = cluse = clause??
how the hell did you figure that out??
More complicated then the daily CCC.
|
|
|
|
|
EliottA wrote: More complicated then the daily CCC.
Thanks, I work hard at them, his seem to come easy!
------------------------------------
"When Belly Full, Chin Hit Chest"
Confucius 502BC
|
|
|
|
|
|
Hi,
I am trying to make a client server form application using VB2005. I am using VS2005 Professional for development.
The problem is as follows:
When more than one client tries to connect to the server. The connection is refused and the Client gets an exception in Connect() method - Target machine actively refused the connection.
This problem occurs only when 2 or more clients try to simultaneously connect to the server. For a single client accessing at a time the problem does not occur.
The code segment is as given below:
-----------1 Module
Imports System.Net.Sockets
Imports System.Net
Public Class FrmMdiParent
Dim WithEvents wsServer As New Winsock2005DLL.Winsock
Private Sub FrmMdiParent_FormClosing(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles Me.FormClosing
If wsServer.State = Winsock2005DLL.WinsockStates.Connected Then wsServer.Close()
End Sub
Private Sub FrmMdiParent_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
main()
Try
wsServer.MaxPendingConnections = 20
wsServer.LocalPort = 8000
wsServer.Listen()
Catch ex As Exception
MessageBox.Show(ex.Message, "Exceptions Handler!", MessageBoxButtons.OK, MessageBoxIcon.Error)
End Try
End Sub
Private Sub wsServer_ConnectionRequest(ByVal sender As Object, ByVal e As Winsock2005DLL.WinsockClientReceivedEventArgs) Handles wsServer.ConnectionRequest
If wsServer.State = Winsock2005DLL.WinsockStates.Connected Then
MessageBox.Show("Server is busy with other clients.", "Server connection failed!", MessageBoxButtons.OK, MessageBoxIcon.Exclamation)
End If
wsServer.Accept(e.Client)
End Sub
Private Sub wsServer_DataArrival(ByVal sender As Object, ByVal e As Winsock2005DLL.WinsockDataArrivalEventArgs) Handles wsServer.DataArrival
Try
Dim str As String = ""
wsServer.Get(str)
.........(other statements)
End Select
Catch ex As Exception
MessageBox.Show(ex.Message, "Exceptions handler!", MessageBoxButtons.OK, MessageBoxIcon.Error)
End Try
End Sub
Private Sub wsServer_Disconnected(ByVal sender As Object, ByVal e As System.EventArgs) Handles wsServer.Disconnected
wsServer.Listen()
End Sub
Private Sub mnuItmLogin_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles mnuItmLogin.Click
Select Case mnuItmLogin.Tag
Case 0
' Login
Dim objfrmlogin As New FrmLogin
objfrmlogin.ShowDialog()
Case 1
' Logout
mnuSvrAuth.Enabled = False
mnuItmLogin.Tag = 0
mnuItmLogin.Text = "&Login"
End Select
End Sub
End Class
----------------2 Module
Dim WithEvents winSock1 As New Winsock2005DLL.Winsock
#Region " WinSock events "
#Region " Connected "
Private Sub winSock1_Connected(ByVal sender As Object, ByVal e As System.EventArgs) Handles winSock1.Connected
If isRequest Then
.................
End Sub
#End Region
#Region " Data Arrival "
Private Sub winSock1_DataArrival1(ByVal sender As Object, ByVal e As Winsock2005DLL.WinsockDataArrivalEventArgs) Handles winSock1.DataArrival
Dim str As String = ""
winSock1.Get(str)
.................
End Sub
#End Region
#Region " Error Occured "
Private Sub winSock1_ErrorReceived(ByVal sender As Object, ByVal e As Winsock2005DLL.WinsockErrorEventArgs) Handles winSock1.ErrorReceived
MessageBox.Show(e.Message, "Error Occured from server.", MessageBoxButtons.OK, MessageBoxIcon.Error)
End Sub
#End Region
-----------------
The above exception is thrown when more than 1 clients try to access the server simultaneously.
I am not able to find any solution to this problem, any help will be really useful.
Thanks
-Dev
|
|
|
|
|
Your going to have to contact the people that wrote the Winsock2005 library you're using to get this question answered.
|
|
|
|
|