|
Dave Kreskowiak wrote: You have to supply those boundries yourself
How is that??
Dave Kreskowiak wrote: or code your own edge detection algorithm to figure them out.
any hint for that?
Regards
Ramy
|
|
|
|
|
Just like image maps in HTML, you have to draw the boundries of each "region" of the map that's clickable and check for mouse clicks inside those regions.
Read this[^] for an explanation of what an "image map" is and the concept behind it. You'll have to implement your own functionality to implement this since there is nothing in Windows Forms that will do it for you.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
hi,
can any one tell me how to create a button in the title bar. just like a minimise button in the title bar.
|
|
|
|
|
There is no support for this built into the .NET BCL. You'll have to create your own support for this from scratch.
Basically, you have to handle all the window messages releated to the non-client area of your form, including painting and non-client hit testing of mouse clicks to see if your button was clicked on. Overriding your form's WndProc method is how you accomplish this. Painting your button in the correct place and keeping it visible are NOT easy. You have to have an in-depth knowledge of how Windows works and window messages work and why. I haven't found any tutorial that explains this to beginners.
You can find an example of overriding WndProc here[^], but it doesn't go into any depth about what window messages you have to handle to pull off what you want to do.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Hi,
Does anyone know of a good site which explains how to get use popup messages in vb.net? Hopefull one which doesn't involve javascript. If the only way is through javascript, then so be it.
Please help. Thank you.
|
|
|
|
|
Your reference to jscript makes me assume you're doing ASP.NET. In which case, jscript is it.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
You are correct. I am using asp.net in VB. Seeing as, according to your reply, the solution is thru javascript, do you know of any good sites I can learn from? Just for the popup message boxes (for now).
Thanks for the reply.
|
|
|
|
|
hi,
can any one help vb6.0 should send emails without using outlook or sqlserver
tx
|
|
|
|
|
How does SQL Server factor into it ?
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
google "cdosys" you can create an object to send email (you need an email system to send the request through however, it won't do it on it's own)
|
|
|
|
|
when i used smtp.gmail.com it is giving an error STARTSLL some thing like that
can any one help me
|
|
|
|
|
Dear friends!
actually i am trying to create a login form which should load b4 or after logon in the windows,thery validating users r allowed to access the system.
I want to implement this using windows services!
pls Guide me.
thanks
sezhi
|
|
|
|
|
By system do you mean:
1) the computer/network? -- wouldn't windows already take care of that?
2) some kind of application? -- you could make it easy on the user and grab the logged in user id and use that to authenticate access to the application.
|
|
|
|
|
Windows already does this on its own. It also will NOT let a user switch desktops unless they logon to the system first, thereby defeating ability to even SHOW a desktop, let alone get input on it.
What are you REALLY trying to do with this?
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
i draw a line chart on form in a picture box as i need to move these line further.
i need to get all the points(xy) coordinates of the line.
can anyone helps.any help or suggestion greatly appriciated
thanks.
-- modified at 1:45 Thursday 14th December, 2006
amolk
|
|
|
|
|
As soon as you want to do anything more than show a picture, you should ditch the picture box and handle your own paint event.
To get the co-ordinates along a line, work out the rate of ascent in one direction, then use fixed values in the other direction to work out your co-ordinates. So if you have a line from 10, 30 to 200, 150, your rate of ascent is (200-10)/(150-30) or 190/120. In other words, for every 19 pixels in the X, you travel 12 in the y. 19/12 = 1.583. So, to calculate your Y, multiple your X by 1.583, after normalising ( subtracting 10 and 30 so you start at 0 ).
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
hello all,
am creating an application using vs.net2005 and sql server as a backend and vb as my code begin. my problem is am setting eno as a primary key field in that field an user entered a number which is alreay in the database it was shown some msg(that no is in the database please choose different no) am writing code for thi. but it is not working propherly. cause when ever user enter no it was check that condition and the clear again he put the same no in the text it was not show that message. am attaching my code. please help me to solve the issue....
Private Sub txteno_Leave(ByVal sender As Object, ByVal e As System.EventArgs) Handles txteno.Leave
con.Open()
Dim A As Integer
A = txteno.Text
str = "select eno from empl"
cmd = New OdbcCommand(str, con)
While Not rs.EOF
'If (A = rs.getvalue("eno")) Then
If (A = rs.Fields(0).Value) Then
MsgBox("Eno Already in DataBase so Please select Different No")
txteno.Text = ""
End If
rs.MoveNext()
End While
con.Close()
End Sub
|
|
|
|
|
1) you can bypass the while loop by putting the value of the textbox in the where clause of the select statement
str = "select eno from empl where eno=" & cint(txteno.text)
if not rs.eof then it exists -- msgbox
2) where did rs get set, your code doesn't specify?
|
|
|
|
|
is there any way to identify that the process is being close by task manager? (not in the application tab but in the process tab)
im using the formclosed event of the form but it doest work..
Private Sub frmMain_FormClosed(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosedEventArgs) Handles Me.FormClosed
Select Case e.CloseReason
Case CloseReason.ApplicationExitCall
MsgBox("Notify")
Case CloseReason.FormOwnerClosing
MsgBox("Notify")
Case CloseReason.MdiFormClosing
MsgBox("Notify")
Case CloseReason.None
MsgBox("Notify")
Case CloseReason.TaskManagerClosing
MsgBox("Notify")
Case CloseReason.UserClosing
MsgBox("Notify")
Case CloseReason.WindowsShutDown
MsgBox("Notify")
End Select
but it doesnt work when i closed the form in process tab(Task Manager)..
-- modified at 1:57 Thursday 14th December, 2006
|
|
|
|
|
There are a few different methods TaskManager TRIES on the Applications tab before doing the brute force "halt execution and free the memory" method. This last-ditch method is what the Processes tab uses when it "kills" a process. It isn't detectable by your code since your process ceases to execute when TaskManager obliterates the Process using this method.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
No, there isn't. You code STOPS executing, immediately. You don't have any way of detecting this if your no longer running.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Hi
I'm using vb.net 2005
I want to use treeview to view the table as a tree for expample :
id Name Parent
1 A1
2 B1
11 AA 1
23 BC 2
112 AcA 11
... etc
how can i make the treeview view the table as a tree
please every one try to help me to give me an example project
jooooo
|
|
|
|
|
id::::Name::::Parent
1 :::::A1 ::::
2 :::::B1 ::::
11:::::AA :::: 1
23:::::BC :::: 2
112::::AcA :::: 11
No one want to help me , or give me any web site that i can find the asnswer there
jooooo
|
|
|
|
|
Does anyone know how to delete a line within a txt file. I am trying to clean up a file that has unnecessary lines.
Any advice would help!
jds1207
|
|
|
|
|
You need to read the file into memory, remove the lines, and overwrite the file. You can't just delete a line from a file.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|