Answer Questions
killfr0g reports
Hi, I have a problem with crystal reports. I have a project (VB by vb.net) that views the records of db Access 2003 in a report and it runs good, but if I try the same project with the same db (but db with password) it do not works and tell me user a pass in a windows... why ... I pass the password in the code, but it don't works. thanks bye Ok, I prepare the text, one moment please because I have the information like jpg, thanks I did prepared a ".doc" with passages, can I send to you from e-mail I you want send me your email, thanks in advance Hi Please post the exception message and also your code so we can lo ...Show All
DonRajah populating an Access database using visual basic 2005
I am trying to create a new employee application that gets input from a user in text boxes and then take that information and populate a database in Access that will later be pulled to the Track IT! database on SQLserver2005. How do i do it Thank you. a) the OleDbCommand is a command object in order for you to do some things with the database, such as executing queries (insert/delete/select/delete). Here is some documentation about it: http://msdn2.microsoft.com/en-us/library/system.data.oledb.oledbcommand.aspx b) the code is up to you where you are wanting to place it - it depends what you want to do really and what the "code" does. In my first example I am selecting all reco ...Show All
cwest Transferring data from FoxPro dbf to Sql
Dear All, I need all your help urgently. I wanted to write a small piece of vb code to sychronize a few FoxPro dbf tables to SQL tables that having the same structure or at least a few fields that i selected. I had tried a code which I found on the net that running row by row and column by column to update the SQL tables but this code is too slow. In my dbf table it contains around 3000 records at least. Please help. Thanks in advance. Regards, Weoi Li ps: Happy 2006!!! mahes wrote: i'm sure, this code will work in VB.net. if possible, can you please provide me VB 6.0 code. Hi, Sorry mahes, but this forum is dedicated on the .Net language. SO VB6 is not quite supported here. I suggest scanning the microsoft ne ...Show All
NP Rudra Unloading a picture from a picturebox in VB.net
I have done some code to load a picture in an array of bytes. The data is saved in a file in the Hard drive. There is also another piece of code to display the image. My issue is that I need to unload the picture before the user press the button to refresh and therefore reload the image. Generally I would have an error when I try to download the file and save it. I will have an error that the file is being used by another process. Noticed that picturebox1.load = nothing will unload the picture from the picturebox but it will not close the file completely before going the next instructions. Checking "If picturebox1.load is nothing = true will be true and therefore there will no way to identify if the file has been closed or not. I do ...Show All
AlexBB ? Textbox
I am probably doing this wrong BUT I put a form together with the following: Datagrid - all read-only and most of the cells hidden for a reason 3 textboxes from the same datasource as the datagrid Now when I select a record from the datagrid, the textboxes change accordingly to match the record that was selected in the datagrid, I can change a value in the textbox and update the datasource and it changes(everythings fine) but when I change the visible property to false, I run into a little snag. I cannot reference the textboxes content. I change change it back and its fine. How can you hide the textbox I changed the color of the box and text to the background color and you can still see the text. I also tri ...Show All
chawacho selected Items in Listbox are disseleceted by Messagebox; vb.net
Hi folks I have migrated from VB 6.0 to VB2002.net. I upgraded my project with the upgrade-manager. Now I find out, that the functionality of the listbox isn't the same since VB 6.0. The same code works in VB 6.0 fantastic; in VB.net not. Here is the code: Dim i As Integer i = MsgBox("Really delete the marked items ", 4) If i = 6 Then 'Yes For i = 0 To List1.ListCount - 1 If List1.Selected(i) Then 'delete dataset in the background table ..... End If Next i 'show new background table.... End If (I filled the Listbox manually with List1.AddItem "item from background table".) Anyone who can say, how to get the same functionality in vb.net , whithout having much more code Or is there anyon ...Show All
bkaye My SQL Update function isn't working in VB, can someone help?
My SQL statements are perfectly fine when I test them in the Query Builder, but I can not, for the life of me, figure out why they won't work in my application. Here is what I have as my SQL statement within my UpdateQuery function: UPDATE members SET id = @id, first_name = @first_name, last_name = @last_name, phone_number = @phone_number, date_joined = @date_joined WHERE (first_name LIKE @first_name and last_name LIKE @last_name) Here is how I am calling the function: Me.DsAllMembersBindingSource.EndEdit() Me.DsAllMembersTableAdapter.UpdateQuery(Me.IdTextBox.Text.Trim(), Me.First_nameTextBox.Text.Trim(), Me.Last_nameTextBox.Text.Trim(), Me.Phone_numberTextBox.Text.Trim(), Me.Dat ...Show All
LeoXue Is it possible?
How would I fill a picturebox with an image ramdomly selected from a bank of images whether in a class, or a set of dimensioned images Please give me a piece of code that depicts this idea. Private Sub btnRandom_Click(By Val...etc.) Dim i as integer For i = 1 to 65535 Picturebox1.image = RANDOM IMAGE etc. Next i End Sub . . I think you get what im trying to say! Very basic usage: Open a windows application Add an ImageList control, Picture Box control and a Button control to your form in the design view add your images to the imageList's image collection And add the codes shown below Public Class Form1 Private Sub Form1_Load( ByVal sender As System.Object, ByVal e As S ...Show All
fmatias AccessKey for Custom Button Control in VB 2005
Hi all, I have a custom button Control converted from VB 6.0 to VB 2005. I need to know how to set accesskeys property for the custom button control. This is the error i get in the converted project. 'UPGRADE_ISSUE: UserControl property UserControl.AccessKeys was not upgraded. Click for more: 'ms-help://MS.VSCC.v80/dv_commoner/local/redirect.htm keyword="CC4C7EC0-C903-48FC-ACCC-81861D12DA4A"' Thanks, Hello Mick, Me.OnClick did not fire the click event of the button control. I had five custom button controls in the sample application. After the if condition is passed, the Me.OnClick did not fire the onclick event. Also what is the difference between Me.OnClick and MyBase.OnClick Can they be used interchange ...Show All
Terry A. King Obtain MAC Address
How can my application to obtain the MAC adress of the PC in wich is installed Como puede mi aplicacion obtener la direccion MAC de la PC en la que esta instalada Thanks! Gracias! For Each NI As System.Net.NetworkInformation.NetworkInterface In System.Net.NetworkInformation.NetworkInterface.GetAllNetworkInterfaces MessageBox.Show(NI.GetPhysicalAddress.ToString) Next On Error Resume Next Const wbemFlagReturnImmediately = &h10 Const wbemFlagForwardOnly = &h20 arrComputers = Array("localhost") For Each strComputer In arrComputers WScript.Echo WScript.Echo "==========================================" WScript.Echo "Computer: " ...Show All
corbin Button that swaps between tabs
I have various tabpages in my program, and i wish to code a button that goes to the next tabpage when i press it... How to do it Thanks XiON, glad this worked for you, One thing I want to point out, and not that it is a big deal, but I'm sure you picked up on it. I mentioned that I had 5 tabs when in fact I have 6, and the Tab index starts from 0. Also, in my application, if I wanted to use the shift key to go to previous tabs, I am checking for Keys.F12, Keys.Shift and Control.ModifierKeys. then instead of incrementing the SelectedIndex I decrement it. Regards tattoo Works perfectly, thanks ;) I crea ...Show All
Speedy2171 Status Bar Icons
I have a form that I would like to hide and show an icon in the statusbar to represent the form, I can handle that with no problems, But after you hide the form, how do you handle the icon with the mouse, so that when a user double clicks on the icon the form reappears Davids Learning Thats what I was looking for How do you refresh the icons in the statusbar, My icon hangs around after you close the application until you click on it then it goes away Davids Learning are yout talking about a notifyicon in the system tray Private Sub NotifyIcon1_MouseDoubleClick ( ByVal sender As System .Object, ByVal e As System . Windows . Form ...Show All
Chris McLeod A question about the CheckedListBox.CheckedItemCollection
Hi, I would appreciate it if somebody could give me some insight to my question. What is the best (safest) way of saving a CheckedListBox.CheckedItemCollection outside of the created (and used) CheckListBox, such that, if the user clicks numerous Checkboxes and then clicks a "Cancel" button... the CheckedListBox.CheckedItemCollection will be repopulated with the checks that existed before the user made changes Also, please let me know if I have the wrong idea about how to go about finding a solution to this problem. Thank you! not sure I quite follow - are you trying to uncheck the checked checkboxes Or are you trying to "restore" back the original checked items Public C ...Show All
Deedhun Custom Dialog Help
I created Dialog1 in my current project. I cannot figure out how to get it to come up when my "New" button is clicked. The various ways I have tried all fail. Thanks for the help. Then you haven't created a class called Dialog1 at all, or it exists in a different namespace to the code that is trying to call it. *grin* NO need to apologise. Glad we got it sorted. I have done that before but I get the error "Type 'Dialog1' is not defined." Double click on the new button in the designer to create a click event. Inside put Dim dlg as Dialog1 = new Dialog1() dlg.ShowDialog() That will work. Now, go and buy a book to help yo ...Show All
RostaB Working with Byval and ByRef keywords
Hey, Could anyone show me how to work with ByVal and ByRef Keywords in Visual Basic.Net Thanks Can you give me a dummy code Check out: http://msdn2.microsoft.com/en-us/library/ddck1z30.aspx byval: private sub DoDisplayMessage( ByVal theMessage as String) MessageBox.Show(theMessage) end sub 'Some button1 click event Me.DoDisplayMessage("Hello! I pressed the button and now I am being called/shown from the DoDisplayMessage, giving this long message to the sub!") ByRef: private sub DoChangeMessage(ByRef theMessage as String) theMessage = " ...Show All
