|
The ComboBox is thoroughly explained [here].
|
|
|
|
|
Thanks all i found a way by myself
|
|
|
|
|
Okay, I just started back working on my web browser, and I want to have my custom context menu show up when the user clicks inside the browser..... This is what I have...
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim Browser As New WebBrowser
TabControl1.TabPages.Add("New Tab")
Browser.Name = "Web Browser"
Browser.Dock = DockStyle.Fill
TabControl1.SelectedTab.Controls.Add(Browser)
AddHandler Browser.ProgressChanged, AddressOf Loading
AddHandler Browser.DocumentCompleted, AddressOf Done
Int = Int + 1
CType(TabControl1.SelectedTab.Controls.Item(0), WebBrowser).Navigate(UrlLocation.Text)
End Sub
That is where I suspect the bit of code will have to go... Since I'm using Tab Control instead of the WebBrowser...
Also, within the Context Menu, I am stuck on two parts...
Private Sub OpenLinkInNewWindowToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles OpenLinkInNewWindowToolStripMenuItem.Click
End Sub
Private Sub OpenLinkInNewTabToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles OpenLinkInNewTabToolStripMenuItem.Click
End Sub
What code would I add there to have it allow the user the option to open the Link in a new tab or a new window when they right-click over a link on the current webpage?
This is all I should need to complete my Web Browser for now.... Thanks.
|
|
|
|
|
Please somebody help me...
|
|
|
|
|
Come on people..... school starts tomorrow... I want to have this finished........
|
|
|
|
|
Hi, dear all,
I have a form with a tabcontrol which has 7 tabpages, the data for the tabcontrol will be read from database.
When the form is loaded, I only want to fill in data for the default tabpage in tabcontrol, I don't want to fill in data for all tabpages by default until user first time select that tabpage, the logic is right?
I know I can create a flag for each of the tabpage, then when user first time select that tabpage (e.g., tabpage 3), I will check the flag if data is filled in or not, if not, fill in data, set flag to true. next time when user select this page again, don't need to fill in data because data is already there.
But is there professional way to check this?
Thanks a lot!
|
|
|
|
|
Andraw Tang wrote: When the form is loaded, I only want to fill in data for the default tabpage in tabcontrol, I don't want to fill in data for all tabpages by default until user first time select that tabpage, the logic is right?
Sounds good to me - if you'd load everything on startup, the user would have to wait until all seven pages are finished loading their data. This way, you're shortening the load-time considerably.
Andraw Tang wrote: will check the flag if data is filled in or not, if not, fill in data, set flag to true
Again, sounds good to me, since you'd only want to check whether it's loaded or not. The simplest approach is often the best.
As an alternative; I'm moving to a nullable DateTime , setting it to the DateTime of the last load-moment. A few triggers on the database that keep track of the DateTime of the last change, and it's possible to see if "something" might have changed in the database.
I are Troll
|
|
|
|
|
Eddy,
Thank you for your detailed explaination.
I agree with you, the simplest way is best, since there is no existing method in vb.net to check tabpage load, I'd better use flag to indicate it.
|
|
|
|
|
You're welcome
|
|
|
|
|
All:
I'd like to write a small boot program for my main app which needs a few file properties to load additional files.
What I'd like is for the boot program to get the same info as if you were to right-click on the file and select properties in Windows Explorer.
1) The filename in the properties textbox
2) The location (filepath)
3) File modified date
I can get the filepath from using the Environment.CurrentDirectory variables, but I haven't been able to figure out how to get the filename or date. Seems like it should be something simple.
What am I overlooking?
TIA for any help.
Norm
|
|
|
|
|
I believe what you are looking for can be found in fileInfo.
Dim fi As System.IO.FileInfo
fi = New System.IO.FileInfo("<put your executable path and file name here>")
fi.LastAccessTime
See if that work for you.
david
|
|
|
|
|
|
Try Application.ExecutablePath
|
|
|
|
|
thanks for your reply, but did you read my post???!!!
i tried it and it returnd path c:\windows\system32\msiexec.exe !!!!
M.Alizadeh
|
|
|
|
|
Are you running a MSI package of your application? Thats why it's showing c:\windows\system32\msiexec.exe
|
|
|
|
|
ok. then what should i do??? that means when i use a msi package always it return c:\windows\system32...???
i also test this way:
In the CustomActionData property of the Custom Action, type:
/DIR="[TARGETDIR]\"
Then in Installer class, add this code:
Dim path As String = Context.Parameters("DIR")
but when run setup.exe file it return a null string...
M.Alizadeh
|
|
|
|
|
Hi I use this code to get MAC address in network adapter, when I clone this MAC adress give me cloning MAC. I want to get real (fabric) MAC address.
Imports System.Management
Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim mc As New ManagementClass("Win32_NetworkAdapterConfiguration")
Dim moc As ManagementObjectCollection = mc.GetInstances()
Dim MACAddress As String = [String].Empty
For Each mo As ManagementObject In moc
If MACAddress = [String].Empty Then
' only return MAC Address from first card
If CBool(mo("IPEnabled")) = True Then
MACAddress = mo("MacAddress").ToString()
End If
End If
mo.Dispose()
Next
MsgBox(MACAddress)
MACAddress = MACAddress.Replace(":", "")
' Then youc an set anything to MACAddress
MsgBox(MACAddress)
End Sub
End Class
|
|
|
|
|
ivo75 wrote: Hi I use this code to get MAC address in network adapter, when I clone this MAC adress give me cloning MAC. I want to get real (fabric) MAC address.
I'm sorry, but I really don't understand what you mean.
|
|
|
|
|
can you please give me an idea how can i implement live chat in my website? I want to know idea behind how to implement live chat Programtically. Am not looking for any gadgets or so, am looking for logic how do we in Vb.net ?
Any suggestion will be most appreciated.
Wayez
http://wayezquotes.blogspot.com
|
|
|
|
|
Syed Wayez Ahmed wrote: Any suggestion will be most appreciated.
Look at the CodeProject articles here[^], search Google for "live chat".
It's time for a new signature.
|
|
|
|
|
Thank You for your suggestion, I dnt know what is google before. You have given me a valuable suggestion.
|
|
|
|
|
Syed Wayez Ahmed wrote: Thank You for your suggestion, I dnt know what is google before. You have given me a valuable suggestion
There is no point your being sarcastic here.
It's ok that you knew about Google.
But did you do a search on it before posting this question here?
|
|
|
|
|
Did you check the CodeProject articles? Your question is one of the most common posted on this website: at least once every week. And always by people who appear too lazy to do some simple simple research for themselves.
It's time for a new signature.
|
|
|
|
|
Hi Richard!
Thnx for your replies. It seems u r angry now, being angry whn made to is quality of definately Male.
I did research and found many articles which point me to use activex which i dnt want to. and i want an ajax and saved chat can you suggest me for the same?
|
|
|
|
|
Syed Wayez Ahmed wrote: It seems u r angry now, being angry whn made to is quality of definately Male.
I apologise if I misunderstood your previous message. However your use of 'txtspk' rather than proper spelling makes it difficult to understand what you are saying.
Syed Wayez Ahmed wrote: and i want an ajax and saved chat can you suggest me for the same? Roll eyes
Same answer as before, look at the articles and search Google, this is such a common question there are many answers to be found. Select the one that best suits your knowledge and experience.
It's time for a new signature.
|
|
|
|