|
Error is Operator '-' is not defined for types 'Char' and 'Char'.
If you can think then I Can.
|
|
|
|
|
Yeah, well you're trying to do math with characters. That's not exactly a defined operation.
What are you trying to achieve with this code?
|
|
|
|
|
But Sir,
- Operator is working fine for Strings.
If you can think then I Can.
|
|
|
|
|
So what?? Just because it works doesn't mean it's a good idea to use it. VB.NET does a lot of implied conversions if a type does normally work. In this example:
Dim x As String = "100"
Dim y As String = "40"
Debug.WriteLine(x - y)
results in 60 being output to the Output pane in Visual Studio. Why? Because both strings were automatically converted to Integers before the subtraction operator was applied.
There is no implied conversion for your '-' character because it doesn't translate to a number.
|
|
|
|
|
But sir it not works for Char.
If you can think then I Can.
|
|
|
|
|
But nothing. I already told you you shouldn't be doing this in the first place.
Rework the algorithm to eleminate doing math with characters and strings. You'll have far better and maintainable code.
|
|
|
|
|
Thank u sir
If you can think then I Can.
|
|
|
|
|
Has anyone heard about the new way to migrate VB 6 to the cloud? There was some stuff out there over the past few days.
|
|
|
|
|
What does this actually mean ? I can tell you for sure that VB6 is totally unsupported. Thank goodness for that......
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
|
Looks like a tool to convert VB6 to VB.NET. Microsoft either couldn't write one that works, or didn't care enough, but if someone's got a working one, then I expect that may work. It will work by ditching VB6 and creating a .NET app.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
aha just for my information i asked , i thought you might had tried
Best Of Regards,
SOFTDEV
If you have knowledge, let others light their candles at it
|
|
|
|
|
|
The only cloud I want to see VB6 migrated to is the one that came out of an elephants ass.
|
|
|
|
|
ROTFL !!! Let me just mark that as a good answer....
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Collect all the VB source codes, delete them after burning them into CD. Collect the VB documents. Place them in a bin, pour kerosene and set it on fire. It will send them to the cloud
|
|
|
|
|
'the cloud' is just a way of referring to the internet, right ? Making an application into a website would basically put it in 'the cloud' ?
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
you could always print out the source code onto paper, take it into the garden and set fire to it. It won't take long to get into the cloud!
|
|
|
|
|
Doh! should have read full thread before posting, just seen a similiar comment by someone else........sorry!
|
|
|
|
|
Hi,
Have a small problem. I have two generic lists that are bound to two separate Listboxes
Private sourceList AS New List(Of Person)
Private targetList As New List(Of Person)
Private p As New Person("Johnny","Chicago")
sourceList.Add(p)
lstSourcebox.DataSource = sourceList
lstSourcebox.DisplayMember = "Name"
lstTargetbox.DataSource = targetList
lstTargetbox.DisplayMember = "Name
So when I try to drag and drop a Person object the data is placed in the targetList but the lstTargetbox doesnt show any info. Is there someway that i have to refresh it or something.
Thanks
|
|
|
|
|
Well, first of all let me know if Name property is declared public inside the Person Class or not.
It can only be shown the members in the List using DisplayMember which are Exposed using Properies.
|
|
|
|
|
You just need to databind the control again, or manually add the item ( you may not be able to manually add to a databound item ). The control does not watch the source, it only binds when you tell it to
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
I doubt that the fact that your lists are generic is the cause of your problem.
Take a look at this thread[^], from a while ago, which basically had the same problem. Unfortunately any code is C# but you may be able to get enough from the textual parts to apply it to your situation.
If not and you are not sufficiently familiar with C# to use it as it is, please post back.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
Thank you very much,
That worked a treat.
Thanks again
|
|
|
|
|
My pleasure.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|