in VB .net
how do I arrange that the items in a list box will be used in
calculations in a formula,
thanks in advance 7 1726
Hi Portroe,
Let the user select the row(s) and calculate with the item(s) the user has
selected.
That can with the click event from a button (multiselect) or just with an
event from the listbox, by example selected itdex changed
I hope this helps a little bit.
Cor how do I arrange that the items in a list box will be used in calculations in a formula,
Hi Cor,
can you possbly do this with a for... next loop, item by item?
thanks
Portroe
Cor wrote: Hi Portroe,
Let the user select the row(s) and calculate with the item(s) the user has selected.
That can with the click event from a button (multiselect) or just with an event from the listbox, by example selected itdex changed
I hope this helps a little bit.
Cor
how do I arrange that the items in a list box will be used in calculation s in a formula,
Hi Portroe,
I thought yes in a multiselect, therefore you can have to look for the
selectedItems property
Cor can you possbly do this with a for... next loop, item by item?
* portroe <bo*@sleigh.com > scripsit: can you possbly do this with a for... next loop, item by item?
Set the control's 'SelectionMode' property to 'MultiExtended' , then you
can use this code:
\\\
Dim Sum As Integer
For Each i As Integer In ListBox1.Select edItems
Sum += i
Next i
MsgBox(Sum.ToSt ring())
///
--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>
* portroe <bo*@sleigh.com > scripsit: how do I arrange that the items in a list box will be used in calculations in a formula,
What's your exact problem? Selecting the items, calculating, ...?
--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>
my problem is selecting the items which are sitting in a listbox,
I then want process each item inside a for... next loop to , with a
formula, placing each result in the next list box,
thanks
portroe
Herfried K. Wagner [MVP] wrote: * portroe <bo*@sleigh.com > scripsit:
how do I arrange that the items in a list box will be used in calculation s in a formula,
What's your exact problem? Selecting the items, calculating, ...?
* portroe <bo*@sleigh.com > scripsit: my problem is selecting the items which are sitting in a listbox,
I then want process each item inside a for... next loop to , with a formula, placing each result in the next list box,
You can select items programmaticall y by calling
'listbox1.SetSe lected(<item index>, True)'.
--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet> This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Simon |
last post by:
Hi,
I'm hoping you could show me examples of how a functional/declarative
language could be used to consicely describe resticted subsets of elements.
I'm looking for a 'specification' style definition so any ideas/input would
be very welcome.
Thanks for your time,
Simon.
--
|
by: NickB |
last post by:
Please could someone tell me what is wrong.
Ther error is:
An unhandled exception of type 'System.NullReferenceException' occurred in
microsoft.visualbasic.dll
Additional information: Object variable or With block variable not set.
I am trying to print the contents of a list box on another form.
This is the sub, and the highlighted line is where it is falling over.
|
by: massimo |
last post by:
Hey,
I wrote this program which should take the numbers entered and sort them
out. It doesn¹t matter what order, if decreasing or increasing.
I guess I'm confused in the sorting part. Anyone has any advices??
#include <iostream>
using namespace std;
|
by: Rick |
last post by:
I want to add items to a list and then submit these items via POST in a
form. Below is my code and it adds the items fine but they are not selected
when I submit the form how can I have them all selected when I submit the
form?
Any help would be most appreciated!!!
Thanks in advance!!
<script type="text/javascript">
|
by: Jeremy Owens-Boggs |
last post by:
We are trying to implement a dual list box selection where you have two list
boxes, You highlight items in the right side list box, click a button and
this moves those items over to the left hand list box. The problem is that
if there are many items selected (thousands), then removing the items from
the right side list box takes for ever because we are removing them one at a
time, which causes the listbox to re-index everything before we...
| |
by: Kriston-Vizi Janos |
last post by:
Dear Mr. Kern, and Members,
Thank you very much for the fast answer, my question became
over-simplified.
My source code is appended below. It uses two text files (L.txt and
GC.txt) as input and merges them. Please find these two files here:
http://kristonvizi.hu/L.txt
http://kristonvizi.hu/GC.txt
|
by: puja |
last post by:
hi all,
I have a form which has checkbox list which has items as below
1) Input 1
2) Input 2
3) Input 3
4) Input 4
5) Input 5
|
by: Michael McGarry |
last post by:
Hi,
Please excuse me if this is not the right forum for this question. I
would like to create a random permutation of a list of numbers. How can
I do this in C?
I was just going to draw a number from 1 to n. n is the number of items
in the list and place the items in a new list in the order that their
index is drawn from the random number generator. Is there a library
function to do this?
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
| |
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
|
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |