how to get different backcolors and how to change them using ListView.ItemCheck.
I am using ListView in a self written control (basically to improve padding). In some deployments, CheckBoxes is set to true and I use a RaiseEvent to return the Index of the row selected using an ListView_SelectedIndexChanged event.
In other deployments, I am using the control with the CheckBoxes set to false. But clicking on a row does not fire the ListView_SelectedIndexChanged event to be able to use RaiseEvent to return the Index of the row chosen. I have tried using a MouseUp event to capture the mouse Y coordinate. But conversion of that coordinate to an Index position is both inconsistent and inaccurate with my primative code of
return = (point.Y - me.top) / some constant
I have used ItemHeight on a ListBox in a similar situation but ListView does not have an ItemHeight property.
how I can capture the Index of a row clicked in a ListView without checkboxes?
I would like to know if there is a command to make a program choose between certain integers. For example, I would like my program to make a random choice between the numbers 12, 118,224 and 300.
In previous I have great experience on Vb 6.0 And Now I am getting train on Vb.Net. But some well adviser saying you should study C# instead of Vb.Net. In this case I don't know which language I should study.
What I wanna do is really simple, I just want to select 2 Listboxed by clicking one..For example .. if I select the 1st item of listbox1, it should select automaticly the 1st item of listbox2 if I select the 3rd item of listbox1, it should select 3rd item of listbox2, and so on, is this possible?
choosing a combo box event for placing this code. I have tried with ostfocus,leave,mousefocuschanged,displaymemberchanged like this but nothing works and Lable26(Default I set Visible:false ) is visible even after I select an Item.
If combotype.SelectedIndex = -1 Then Label26.Visible = True Label26.ForeColor = Color.Red
I am using Printdialog control in VB 10 but I am not able to choose de printer. Even choosing a specific printer in the Printdialog, it always prints in the default printer of the computer.
I am trying to figure what is the best way of using SQL in my app in the manner of run time.I need to select data from my database let say 60 times a day maybe more I can use the dataset and its adapters or use the SqlCeCommand to build my own Q What do you recommend?
I am writing a .NET program which will run on a computer with several IP addresses. The program makes HTTP requests to given web addresses. I want to choose which IP address I use (so I can determine which IP address will appear on the log of the other server).
I have 9 numbers 1,2,3,4,5,6,7,8,9. I want different combinations of 5 numbers out of 9 numbers (no repeat of same numbers in a row). E.g. 1,2,3,4,5 - correct, 1,1,2,3,4 - wrong
I want no duplication either E.g.: 1,2,3,4,5 1,2,3,5,4
Any formula which works for 8 or 9 or 10 or n numbers. I know there is 126 ways C(9,5)=(9!)/(4!.5!)=...=126 ways. I need the code to generate unique set numbers E.g.: 1,2,3,4,5 1,2,3,4,6 2,3,4,5,6
I am making a program to enter random phrases and words into an object on a web browser. I am not sure how to make the program choose a random phrase or word though.Basically I need to have a list of 100 or more words and phrases inside a program, and for the program to choose one when called upon.
I'm working with a connection to a Access db. I noticed that when the mdb file is not found in the location it should be, an exception OleDbException is thrown. I would like to create some kind of form where the user specify the new position of the Access mdb file to continue to work. Then, it would be useful to save the new location as well I suppose. But, where do I have to handle that exception?
I have a VB.NET application with a connection to an SQL Server 2003. On the server there are two databases, MyDatabase and MyDatabase_Test. What I would like to do is to show a dialog when the program starts that let's the user choose which database to use. My idea is to create a new form as the starup form that sets this property and then launches the main form.Currently the connectionstring is specified in the application config file. Best would be if I can specify two different connection strings in that file to choose from, but for now it is also acceptable with other solutions like hardcoding the two connectionstrings into the startup form.EDIT: In the dataset.xsd file there seems to be the relevant part
<Connections> <Connection AppSettingsObjectName="MySettings" AppSettingsPropertyName="MyDatabase_ConnectionString" ConnectionStringObject="" I
I have an app with a webbrowser, and I want to navigate from one webpage to another by selecting and submitting a value in a selectbox on the page. How do I do this? The selectbox on the website has a bunch of strings (my program knows which string to choose), and I want it to automatically submit the correct value.
I have a program issue I am trying to work on. I have multiple comboboxes(12 total) on a form.I am attempting to update some settings from what ever the user selects from the combo boxes. I am trying to keep the code as small as possible, so I thought about having all the comboboxes have similar names only different by a number being changed at the end. (ex: cbo_1, cbo_2, cbo_3, etc...)And using a For next loop to advance through each combobox and update the settings as the for next loop advances.(This might be a stupid way of doing it, but its the first idea that came to mind.)
I'm trying to design a windows form application. By default, .NET had put Tahome 8,25 on toolbar and Microsoft SansSerif 8,25 on everything else. To improve general look and feel of the forms I'd like to change them.
Which font family should I use as a default? And what size should they be? For:
Classic data input form (label + textbox, label + combobox...) Data grid
Is there any recommended way?
Application is a classic business app, you can think of it as an accounting type.
I have 7 radioButton options that allows the user to select which "Group" of guitar tuning they want. For example "General" and Dropped" Tuning". When the user selects rbGeneral a comboboxTuning gets items.add ("Standard") and others added to it. The same goes for when the user selects "Dropped": the comboboxTuning gets filled withe different terms. The problem is....I cannot figure out how to clear out the combobox.items (text) when switching between "Group" radio buttons. So, the comboboxTuning just keeps filling up.
I have 10 constant arrays of data that can be used throughout the program.[code]I also have an array that needs to be populated randomly depending on user input.array_user(8)If the user selects 3 for instance...I need the data in array_user to be populated by the data in array03.I know I can do that with if/then statements...but I'm sure there is a much simpler way to do it.
I am looking for a contol either listbox or listview to support my requirements. Basically how my application looks is:
[Code]....
Having said these things. I used to program in VC++6, VB6. But using those version now seems not realistic now as I lost touch. But if I have to use the latest 2008 versions, for which I do not have any experience seems scary. So, If you are reading this , and you have got some experience in these fields or using controls that support my requirement, can you please let me know which programming language or IDE and Control should I use to develop this application. PS: the image is made using mspaint and does not represent actual program.
I'm about to start translating my vb.net application, and I don't want to use the default methods provided by Visual Studio to do so. I need my application to be very light, and it nearly doubles it size to use the resources option.Therefore, I'm planning to use some thing like a class, of which I would have one instance per language. Since I don't want to distribute language files as separate files (I'd rather have them hard-coded), I would like to find an easy way to check if every field of the class is initialized. I was thinking of something like an Interface, where I would do something like this:
Public Interface Language Dim HelloMsg As String Dim GoodbyeMsg As String End Interface
[code]....
It's obviously not the right way to do it (although I could use properties instead of vars), but I was wondering whether the was a way to have the compiler check that everything is translated and warn about it if not.
I got a combobox which is filled with values from datasource. By default the first value is chosen which is fine but I need to display "Choose country" as the default combobox text. The user then can choose from the drop down list.
In my project I need to use a 190 very long strings with different number of characters (4-60).I want to mark them in a short form with the numbers 001, 002, 003 ... 190. Is there an easy way to display the full name of the string when I choose a short name ? Of course, I do not want to write 190 times "if - end if" and also I would like to avoid a complicated database. Onenew Visual Studio 2010
i wanna make a program for my little brother, that allows u to input a name then to display a msgbox with pres coded phrases such as "your a good boy" or "your a bad boy". my problem is how do i tell vb to randomly choose between the two phrases, not keeping on choosing the same one?
I am new in visual basic and I came up with a problem. I have text file with names in it and I want in a textbox everytime the user hits a button randomly choose a name from it.
I used to be visual basic 6 programmer, i was pleased with visual basic : it is high level language that do stuff fast,easy to learn, easy to do stuff in,you can drag and drop stuff to the form and write your code,it is simply amazing.however microsoft buried VB6 and pointed us to VB.NET which is so different that it is not the old VB anymore.I didn't like what microsoft did and would like to look somewhere AWAY from microsoft and from any other proprietary language I would like to look into a similar language that is easy,cross platform (windows / Linux), object oriented, visual design, non proprietary and compile (for some guarding against reverse engineering).
i am freelancer so the choice is entirely mine,i don't care about performance of programs, the time taken to develop a given programs is much more important. desktop / database / GUI /networking programming is what i am looking for.so any such language offered by our open source community ?
choosing a development platform to convert our current software. I work in an academic research lab, and our current software is written in VB6/ActiveX, and C. I was given the job to convert the software into a more 'modern' platform. I am trying to decide between VB.net and Python. In a nutshell, the software is used to control a system to collect live images from people's eyes. It consists of a number of activeX modules that control various hardware pieces, like ccd camera, frame grabber, deformable mirrors, motorized stages and so on. The core of the software processes the ccd images (huge arrays), and manipulates the hardware(the deformable mirrors) to try to get better images.