473,395 Members | 1,706 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

C#-> Notifyicon.Text

I tried to do this:

string count = "0";
count = count + 1;
notifyIcon1.Text = "Testing " & count & " numbers"; <- generated error
It doesnt accept "&" or "||"

Any suggestions?

I got the idea fom vb so Im not exactly sure.
Nov 16 '05 #1
3 2139

"Hareth" <ab******@hotmail.com> wrote in message
news:e$**************@TK2MSFTNGP11.phx.gbl...
I tried to do this:

string count = "0";
count = count + 1;
notifyIcon1.Text = "Testing " & count & " numbers"; <- generated error

this should be
notifyIcon1.Text = "Testing " + count + " numbers";

& is a VB operator, the + operator is the C# equivilent.
Nov 16 '05 #2
Thanx.....

It worked
"Daniel O'Connell [C# MVP]" <onyxkirx@--NOSPAM--comcast.net> wrote in
message news:OE**************@TK2MSFTNGP12.phx.gbl...

"Hareth" <ab******@hotmail.com> wrote in message
news:e$**************@TK2MSFTNGP11.phx.gbl...
I tried to do this:

string count = "0";
count = count + 1;
notifyIcon1.Text = "Testing " & count & " numbers"; <- generated error

this should be
notifyIcon1.Text = "Testing " + count + " numbers";

& is a VB operator, the + operator is the C# equivilent.

Nov 16 '05 #3

"Hareth" <ab******@hotmail.com> wrote in message
news:uM*************@TK2MSFTNGP09.phx.gbl...
Thanx.....

It worked
NP, it's one of those things that is only obvious once you know the answer,
;)

"Daniel O'Connell [C# MVP]" <onyxkirx@--NOSPAM--comcast.net> wrote in
message news:OE**************@TK2MSFTNGP12.phx.gbl...

"Hareth" <ab******@hotmail.com> wrote in message
news:e$**************@TK2MSFTNGP11.phx.gbl...
I tried to do this:

string count = "0";
count = count + 1;
notifyIcon1.Text = "Testing " & count & " numbers"; <- generated error

this should be
notifyIcon1.Text = "Testing " + count + " numbers";

& is a VB operator, the + operator is the C# equivilent.


Nov 16 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: petterl | last post by:
I have tried to find the error in the code below but I always get " An unhandled exception of type 'System.NullReferenceException' occurred in Unknown Module. Additional information: Object...
2
by: Derrick | last post by:
I've been working on an application which has a NotifyIcon (system tray icon), and a corresponding ContextMenu. I want to be able to update this menu dynamically. However, when I make changes to...
2
by: Randall Powell | last post by:
I am in the process of developing a Windows Service which will: (1) monitor multiple network shares; (2) marshal text file transfers into an SQL Server 2000 instance; and (3) provide messaging...
2
by: Erik Cole | last post by:
There doesn't seem to be a mouseover event for the notifyicon, but I want to fire an event that shows the user an updated status message on mouseover...sort of like hovering over the network icon...
2
by: Amjad | last post by:
Hi, I'm using the NotifyIcon to process some text files in the background periodically. I want to display one icon in the task bar when the program is in stand by mode, and I want to display...
2
by: JR | last post by:
Hi, I need to change the notifyicon in a countdown. after about 3000-5000 times there is an error. Here is all the code. what is wrong please help
0
by: sherifffruitfly | last post by:
.... I need somewhat more to show when I hover over the icon - are there any straightforward ways to do this? Thanks for any ideas, cdj
1
by: \Ji Zhou [MSFT]\ | last post by:
Hello Jason, Thanks for using Microsoft Newsgroup Support Service, my name is Ji Zhou and I will be working on this issue with you. I have tried to but cannot reproduce your issue on my side....
8
by: starrysky | last post by:
I have a program which puts an icon in the notification area and has a menu associated with it available by right clicking on the icon. I want the menu items to be selected by single left clicks but...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
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,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
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,...
0
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...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.