800 Posted Topics
Re: Something like this: Dim ts As TimeSpan = dtpTimeOut.Value - dtpTimeIn.Value txtDailyHrs.Text = ts.Hours & ":" & ts.Minutes Will display like this: Date1: 08:00AM 1/24/13 Date2: 05:15PM 1/24/13 Text: 9:15 | |
Upon playing with the graphics/random class - I have discovered something odd. Private Sub Me_Load(sender As Object, e As EventArgs) Handles Me.Load For i = 0 To 5000 DrawColor(GimmiRectangle) Next End Sub Private Sub DrawColor(ByVal rNew As Rectangle) Try Dim g As Graphics = Me.CreateGraphics g.DrawRectangle(New Pen(Color.FromArgb(New Random().Next(255), New Random().Next(255), … | |
Re: Are you using a custom DLL? If So, you can try [this](http://stackoverflow.com/questions/4897685/how-do-i-register-a-dll-on-windows-7-64-bit). If not - is it possible to post the code around Line 12 of the MakePayment form? | |
Upon aiding a friend - I have decided to post the example used here. The following is a snippet that shows basic class inheritance. The source file as well as a test case can be found attached. You can test these classes with the following code: Dim cNew As New … | |
Re: Try a parameterised query: "INSERT INTO @Table (col1,col2,col3) VALUES (@val1,@val2,@Val3)" | |
Re: Let me try to clarify this a little: You are: 1) Creating a toolstripdropdown 2) Adding a panel to the dropdown 3) Repeating this process for every time a button is clicked? Is this true? | |
Re: What error is being thrown? We can't begin to debug if we don't know the region to start. | |
Re: What do you mean by item analysis? What kind of items are you wanting to analyze? As for the code, we can't **GIVE** you code - We aren't a **DO** forum we are a **HELP** forum. | |
Re: I alsways ask the client to see what is the standard resolution that is targeted. I then design the GUI around this resolution. Always keep in mind that you are designing for the end user, and never for yourself. | |
Re: Query side, you can try this: Replace Type with the column that holds your values. SELECT * From Table ORDER BY Type ASC For list based, try this: Dim lstString As New List(of String) 'Add the items to your list lstString.Sort() 'The default sort function sorts Ascending - for sorting … | |
Re: Try a function like this: Private Function CheckIfYear(byval sYear As String) As Boolean Try Dim dt As New DateTime(Cint(sYear),1,1,1,1,1) Return True Catch ex As Exception Return False End Try End Function Then use it in the TextBox's Leave event: Private Sub TextBox_Leave(sender As System.Object, e As System.EventArgs) Handles TextBox1.Leave If … | |
Re: The brakets allow you to name a variable the same as a reserved word. [Here](http://bytes.com/topic/visual-basic-net/answers/352043-brackets-around-types) is an article on the brakets. As for the network stream - I have used [this](http://www.youtube.com/watch?v=SwG1-RXf6_8) video for a reference a while back. I hope it may help you. | |
Re: This is a very simplistic approach, see if it does what you want it to do. For i = 0 To dgViewClients.Rows.Count - 1 For j = 0 To dgViewClients.Rows(i).Cells.Count - 1 If dgViewClients.Rows(i).Cells(j).Value.ToString.ToLower.Contains(strSearch.ToLower) Then dgViewClients.Rows(i).Selected = True Return True End If Next Next Return False | |
Re: Dates will not hold just hours and mintutes, you will have to set a default month,day,year Dim s As String = "1642" Dim hourPortion As String = s.ToCharArray(0, 2) Dim minPortion As String = s.ToCharArray(2, 2) Dim dt As New DateTime(1900, 1, 1, CInt(hourPortion), CInt(minPortion), 0) MsgBox(dt.ToShortTimeString()) Will do what … | |
Re: Could you declare results as a list? Dim Results As New List(Of String) While Reader.Read() Results.Add(Reader(0)) End While | |
Re: Why don't you look into a VPN? (unless this is not an option) If you are wanting to broadcast a signal that far, you are talking about some serious equipment. A VPN would solve your problem completely. More info can be found: [Wikipedia](http://en.wikipedia.org/wiki/Virtual_private_network) [Open VPN](http://openvpn.net/) [Cisco](http://www.cisco.com/en/US/products/ps5743/Products_Sub_Category_Home.html) | |
Re: If you are using SQL as a backend, you try the command: Dim cmd As New Oledb.OledbCommand("INSERT INTO table2(YesCount) SELECT COUNT(*) FROM table1 WHERE table1.Status='Yes'",YourConnection) Give this a try | |
Re: You can use [this](http://technet.microsoft.com/en-us/library/cc755136(v=ws.10).aspx) for Microsofts instructions on setting the folder cache. The example is for Windows Server 2008, which I'm sure you can do the same for Windows 7. | |
![]() | Re: Something like this Dim diares As Windows.Forms.DialogResult = MsgBox("Test", MsgBoxStyle.YesNoCancel) If diares = Windows.Forms.DialogResult.Yes Then MsgBox("Yes pressed") ElseIf diares = Windows.Forms.DialogResult.No Then MsgBox("No pressed") ElseIf diares = Windows.Forms.DialogResult.Cancel Then MsgBox("Cancel pressed") End If |
Re: You will have to update the biding source be either recreating it or editing it in the GUI. | |
Re: No, the .Net framework/Oracle takes care of the rest for you. (Provided you coded the application correctly) | |
Re: Do as Adam_K has stated and enter the code inside the if statement: Define a password somewhere(in code or in db) Private Sub delete_Click() On Error GoTo Err_cmdDelete_Click Dim answer as String = Inputbox("Please enter the password:","Password") If answer = MyPassword Then DoCmd.SetWarnings False If MsgBox("Delete this VounteerRecord. Are you … | |
Re: For the server you can do the following: Get Client Name Check if new client: Dim pathscheme As String = PathOnServer & SomeUniqueClientValue 'Like a GUID If IO.Directory.Exists(pathscheme) = False Then IO.Directory.Create(pathscheme) End IF On client Side, you do the same: If IO.Directory.Exists(pathtoserver) = False Then MsgBox("No Directory Found @" … | |
Re: First thing is to be sure the crystal report is calling the same dataset as above. This being said, you are passing the DataRow in as ByVal, you need to pass this in as ByRef. ByVal only changes the underlying data while in the sub (All changes are lost on … | |
Re: [Here](http://www.daniweb.com/software-development/vbnet/threads/439117/xml-readwrite) is a link to code that will allow you to read on an element basis. | |
Re: Can you do us a HUGE favor and indent your code for easier reading? You can do this by pressing Tab to indent the code. You will see the text turn green when it is done correctly. | |
Re: Create a list of string and cycle through them: 'Where sr is a stream reader Dim lstIngredients As List(Of String) = sr.ReadLine().Split(",").ToList 'lstIngredients(0) = 150 'lstIngredients(1) = Flour 'lstIngredients(2) = Grams | |
Re: There could be a number of problems wrong, but first I would start small. The easiest test to do would be to plug the laptop into a desktop monitor using the VGA port. If this works, it could mean any of these: Bad LCD (Replace LCD) Bad Inverter (Replace Inverter) … | |
Re: Are you calling this from code? If so, can you please post the code that is giving you this problem? We're good, but we're not THAT good. =) | |
Re: Try something like an IIF statement: Col1 = IIF(IsDBNull(ds.Tables("myTable").Rows(intCurRow)("Caste")),"MY DEFAULT VALUE HERE",ds.Tables("myTable").Rows(intCurRow)("Caste")) | |
Re: Im sorry, but we can't give you ideas. That's not how the creative process works. You will have to find the ideas on your own, but if you need help with your code..We can help. We are offer help, not homework solutions. | |
![]() | Re: You could try to add it to an array then search the array for it: Dim lstString As New List(Of String) 'Assuming they have to press a button to submit their letter Private Sub Button_Click(sender as object, e as eventargs)Handles Button1.Click If lstString.BinarySearch(ListBox1.Text.ToLower) <> -1 Then MsgBox("You can only enter … ![]() |
Re: If you are popoulating the listbox with a dataset, you just need to refresh the data. What connection type are you using? | |
Re: Are you retreiving a large amount of records? | |
Re: Access databases can only be open by one user at a time. It would be wise to open a connection , read all data, then close the connection. | |
Re: Could be throwing a null reference exception as well. Try replacing: TextBox1.Text = myDataSet.Tables(0).Rows(SelectedIndex).Item("Equipment_ID").ToString With: TextBox1.Text = IIF(IsDBNull(myDataSet.Tables(0).Rows(SelectedIndex)("Equipment_ID")),"",myDataSet.Tables(0).Rows(SelectedIndex)("Equipment_ID")) | |
Re: [Here](http://www.codeproject.com/Articles/10154/NET-Encryption-Simplified) is an article on CodeProject that contains all the source code to do exactly what you are wanting. | |
Re: What I like to do when using listviews, is to load the table's identity column into the first column of the listview. (Then make the column width 0 to hide it from the user) Then to reference it, I use: Dim myUnique As String 'Your data type here If IsNothing(ListView1.SelectedItems) … | |
Re: Also, you want to use the DTP's .Value attribute, not .Text | |
Re: If you are not hearing the POST (Power On Self Test) Beep, or you are hearing multiple beeps (error) then I would first look at memory (most likely the culprit). Are you running Crossfire/SLI? (Dual Video Cards Crossfire(ATi) SLI(Nvidia)) | |
Re: Try This: Dim MyTable As String MyTable = "Table1" For i = 0 To ds.Tables(MyTable).Rows.Count - 1 'Do Work Next | |
Re: What problems are you getting with this code? | |
Re: Try If TextBox1.Text = "A" Or TextBox1.Text = "B" Or TextBox1.Text = "C" Then 'Do Work End If | |
Re: [Here](http://htmlagilitypack.codeplex.com/) is a free, open source, package that will do exactly what you are wanting. | |
Re: If you are making an app for "live" data manipulation you need to research what methods you want to use: [DataGrid](http://www.dotnetperls.com/datagridview-vbnet) [ListViews](http://vb.net-informations.com/gui/vb.net-listview.htm) [Reports](http://vb.net-informations.com/crystal-report/vb.net_crystal_reports_tutorials.htm) Ect... You will need to design your tables on an atomic level(3NF) and design your GUI for the end user (not your own preference). You will need … | |
Re: Also, if you are simply wanting to copy one file from one location to another, you can use this call: Dim outFileName As String = "myTXT.txt" Dim input As String = My.Computer.FileSystem.SpecialDirectories.Desktop & "\myTXT.txt" Dim output As String = My.Computer.FileSystem.SpecialDirectories.Desktop & "\TEST\" & outFileName If IO.File.Exists(input) Then If IO.Directory.Exists(output.TrimEnd.TrimEnd(outFileName.ToCharArray)) = … | |
Re: [Here](http://www.vbaccelerator.com/codelib/imalloc/imalloc.htm) is a link that shows you how to use "malloc()" (Or at least a interopted verison) | |
Re: From my experience with dells, it is most likely the inverter/inverter cable. The cables range from $10-$30 and the Inverter is around $100 (For the model I was repairing.) You can confirm this by plugging the laptop into a monitor using the vga port. | |
Re: You can prepare for Microsoft's new "Enlightenment" and learn HTML5/Javascript | |
Re: When Using Click Once: If you set the application to automaticly update in the publish settings, the next time the user starts the application - it will simply auto update for them. When using S&D packages: You must create a setup.exe for the application for every release |
The End.