[2008] Detect Hardware Information
Feb 23, 2009How would I do this in VB.net? Example: Generate a form that will tell me the:
1. CPU
2. OS
3. RAM Used/Available
4. Framework Package Installed. Is there an easy way to do this?
How would I do this in VB.net? Example: Generate a form that will tell me the:
1. CPU
2. OS
3. RAM Used/Available
4. Framework Package Installed. Is there an easy way to do this?
I want to be able to detech when a text box changes, this is populated from another application the text box is [code]What I would like to be able to do is detect when this changes from 0-1 and 1-0 so I can log this to my text file, the code for that is below.[code]
View 6 RepliesIs there a way to detect if a object is over an other, and then do an action?Eg:There's a label and a picturebox.When I change the label's location it goes on top of the picturebox.Is there a way I can detect it, so that once it's on top of the picturebox I show a messagebox or so?
View 2 Repliesi dont want my local ip..its a remote computertheres diferent ranges in the ips but from where i am looking for the ip im connected to the same network..lets say my ip its 10.31.47.54 but the one i try to see if its one its the above....but its behind a firewall..i know its on...but when i ping from my code
View 22 RepliesHow to detect USB Drive (Stick) when plug/unplug in real time ?ps like : show drive label in textbox , " if plugged text1.text = E: " and " if unplugged text1.text = "" " in real tim
View 2 RepliesI have a webapp where a datagridview is populated with records from a database and one of the columns is a download link to download the zip or exe file. We have the zip files on our server, but not the exe files as those are on another department's server. We have all of the file available for download, but if the user as an option selected in a dropdown, those url's in the gridview are re-formatted to be the exe file's on the other dept's server, however they don't have all of them (some 20% are missing) which means if the user click's the link they get their server's 404 not found page and can't download the file.
My PM (Project Manager) is asking me if I can have our webapp detect that the file doesn't exist on their server and instead of them getting the 404 page, they don't leave our app at all and get a javascript popup window or the page is refreshed with a red mark (and a message) next to the link they clicked on, is something like that possible? I have 2 restrictions with this, I can't modify the database because it doesn't contain file paths, it only contains a small portion like (Clinton County, Eaton County, Traverse County, etc..) and the rest of the url is formatted on the fly when the page is rendered, so there's no way to mark the missing files and there's no way we can host the files.
I am using a richtextbox control on my form.I want a small code which can detect if any image has been inserted in the rtb or not.For e.g. user can just type some text or insert image also. Now if we select an image then we can get the type but I want a code which scans contents of rtb and gives me a true if an image is inserted or false if there is none.
View 8 RepliesI have roughly 20 text boxes on my form,When you press tab, it naturally selects all text in the box (highlighted in blue), so you can press any key, and it replaces it with that,That result is what I want, unfortunately, if you click into the text box, and tab back to it, it no longer selects all the text.I'm wondering how I can detect the tab event properly,I've tried adding a 'KeyDown' event to each text box, and then selecting the text, but the sub never runs, also tried detecting the tab event in my Main Form, thinking that perhaps the parent handles it and will receive that event, but.. No.I've thought of using an event like 'Activated' however, it will also run when the mouse is clicked.
View 4 Repliesmaking a class scheduling system. I want to detect conflict in day,section,start_time,end_time,room,teacher in the MSSQL database.
View 7 RepliesI have my own web browser and download manager... How can web browser detect when user wants to download a file? And how do I stop opening of IE window for file download?
View 1 RepliesIs there a way to detect if a My.Computer.FileSystem.CopyDirectory() has failed? It seems that if it fails the copy (i.e., not even space on the destination drive), it just quits and doesn't seem to throw me an error? I already have it in a Try/Catch block, but I'm using that to see if the source directory exists, I'm guessing I should use
[Code]...
detect if the system has Hibernation enabled, or in the case of Win2k if hibernation is even possible. I already know how to hibernate the computer via the Framework:
Application.SetSuspendState(PowerState.Hibernate, True, True)
but in my program I would like to provide the hibernate option only if the OS A) is new enough to be able to and B) has it enabled in the user's Power Options in the control panel.
I need to detect if a [blank] media (CD/DVD) is inserted into the D: drive for an internal software I'm writing. The drive is static as drive D:. How can I tell if media is inserted, first off, and secondly, is it possible to tell if it's blank?
View 2 Replieswhat are some ways to detect file tempering
View 10 RepliesI'm writing a program and it's got a textbox for the user to enter values. Since the textbox text property should only be a "number", my program need to detect invalid charaters like "*/&()$" and tell the user to only enter a number. Does anyone have an idea how to do that?
View 6 RepliesAdding How would you detect if the user is using the computer? I want a program to detect if the user is using the computer (i.e. mouse and keyboard movements), and if the user doesn't type or move the mouse for a specific amount of time, it executes a command. Normally I would do this with the Application.Idle, but I want it to be detected throughout the system. Any starters?
View 22 Repliescan anyone give me a sample on how to make in vb.net a Dialup Network Connection (DUN) i tried google, it gives me RASDialer w/c is kinda >.< basically.what i wanted to implement first is to detect Modems... coz we have a 3G sticks here where we can connect to the net. after detecting the modem. then it will dial it. even without having the panel or dashboard of our modem stick.
View 1 Repliesi have a two-dimensional char array that holds the values of a tictactoe board.Each element holds a value of either 'X','O', or and you can access the values with something like TicTacToe[0][1]with the first bracket containing the row # and the second containing the column #.
Whats the best way to detect the winner of a TicTacToe game? I was thinking about just making a function like this Private Function checkWin(Byval TicBoard as Char[][]) as Integer 'Return 0 if no winner, 1 if Player 1 wins, and 2 if Player 2 wins End Function Any ideas? I want to avoid using 8 if-else statements since that seems pretty inefficient and sloppy
In our program we track the moves in arrays by columns 0 means empty, 1 means black, 2 means red so it would look like this for example
column1(0) = "1"
column1(1) = "2"
column1(2) = "2"
column1(3) = "1"
column1(4) = "0"
column1(5) = "0"
for column 1, and we have seperate arrays for each column (7 in all) but they all have the same values 0,1, or 2 so how can we make it check the arrays and their values and detect a winner?
The program is currently trying to pull information from three different database tables and compiling the information onto one screen, to do this i am using three different connections and a function to handle the data at each stage. The issue is as my code hits PageLoadStage of "2" and runs the QueryDatabase() Function i am encountering an error of: "OleDB exception unhandled: No value given for one or more of the required parameters." This occurs on line 15 of the first code snippet. Can anyone explain this and/or identify any code issues if that is the cause.
[Code]...
I was looking for some stuff online, and i was looking through my reference sheets for vb.net, but it seems in the code i have found, there is declare in methods. Below is an example i am talking about. The thing is, that i dont recognize it and believe that it is an earlier version of Visual Basic ( 6 or earlier) which used it. Should i just keep looking for different code?
Public Declare Function RegOpenKey Lib "advapi32.dll" Alias "RegOpenKeyA" (ByVal hKey As Long, ByVal _
lpSubKey As String, phkResult As Long) As Long
Goal: Find information on how to implement a method which will check if a certain DSN exists, and then if it does, extract the information and use the information for connection purposes.
I have a text box where i am entering numbers of double datatype andon the Keytdown event of the textbox some checks take pace and in certain circumstances I want to be able to stop the user from entering other information until they enter the right information in the textbox (where it says right here) . now when I say exit sub the textbox somehow loses focus . but this is not how I want it to be I want the textbox to remain with the focus so the user can change the information . How can i go about this. And the other thing is why is my txtDestPayRate1.Focus() just befor the exit sub not working?
Private Sub txtDestPayRate1_KeyDown1(sender As Object, e As System.Windows.Forms.KeyEventArgs) Handles txtDestPayRate1.KeyDown
If e.KeyCode = Keys.Enter Then
[CODE]...
I am designing a backup/restore utility for work.atm i have been able to populate field for PC name, IP address, MAC address, number of printers installed on the PC but i am wondering is it possble to get all the printer information 'with the click of a button' to print all information like the prnmngr.vbs script down.I am able to run a batch file but i wanna get it to go from that app or even embed to batch file to the app and run it form there .
View 4 RepliesIm trying to to detect what is in the string and so something for each different result but im not sure howto, here was my first idea but it obviously doesnt work as you cant use contains that way:
Select Case omg.Contains
Case "1"
MsgBox("1")
Case "2"
MsgBox("2")
End Select
How can I make a application there detects when the webbrowser navigates to another website?
View 8 RepliesIs there any way to determine that a system has automatic updates enabled and has the little yellow security center icon indicating that updates are available? I'd like to drop a little service on one of my servers to monitor for that condition but can't find a good resource to get started.
View 12 RepliesIs there any way to detect when a link is clicked in the webbrowser control? It's loading the same page back again.
View 2 RepliesIs there a way to detect when a laptop is docked or undocked? I know how to get the "dock" status of a laptop using GetCurrentHwProfile. So is there some type of event raised when a laptop gets docked/undocked that we can catch? I did do something similar in the past for the detection of USB devices using a ManagementEventWatcher ...
View 2 RepliesI have an application that starts from Sub Main and I need to run a sub when the system is about to shut down, restart or logoff so it can save it's settings. I found some code on google:
Imports Microsoft.Win32
Public Sub Main
AddHandler SystemEvents.SessionEnding, AddressOf OnShuttingdown
[Code]....
But it doesn't seem to work, Windows shuts down yes but when I re-start the vm and run the app it opens with the old settings, not the ones that I changed before I shut down the vm. Anyone know of a way to do this or to fix the code above, I don't think my OnShuttingdown event is being handled.
I have searched everywhere, and have not found an answer. I would like to know how to enable your form to detect if a process is started. Something like this:
If Process.Start("Process.exe") Then
MsgBox("Process is running")
Else
MsgBox("Process is not running")
End If