Well, seems to be still some problem there.
When I try to compile the exe, which I must, to run it on my second PC, it gives me an error: "Wrong number of dimensisons" in this line:
For SNo = 0 To UBound(Smilie(0))
Edit: in the Private Sub Do_Smilie(StartLoc As Long, Length As Long) which appears two times within the program.
I first thought UBound was used wrong here and changed it to Ubound(Smilie, 0) which should deliver the UBound of the first dimension in the array (being 1, I guess since it is dimmed Smilie(1,9)). With this it compiles, but then giving me a runtime error.
I changed it to UBound(Smilie, 1) which should produce the UBound of the second dimension. Therewith it compiles and runs.
Is that ok, Gremmy? The chat works then as expected.
And if so, I still have no idea as how to use and produce the smilies now...
(Maybe I'm just blind or don't get what is meant. I thought you could now integrate smilies into your messages, but I don't find how???)
And if so, I still have no idea as how to use and produce the smilies now...
(Maybe I'm just blind or don't get what is meant. I thought you could now integrate smilies into your messages, but I don't find how???)
I haven't looked at the code, but I think I get the gist of it. The chat box is a RTF textbox.
The above is how a smile : ) is coded into the RTB (he took this from Word). So when someone sends you a message with " : ) " in it, you replace it with the above string and you get a Smilee.
Right. I took a look at the coding, too, and found the mistake.
That's how the UBound statement works: Ubound(Smilie, 2)
You have to change it in both Do_Smilie subs.
What a fancy coding with that RTF pictures, but curiously I like it.
Sat and looked at the problems posted and realised that I've lost my mind and put this in the wrong context/Syntax.. Or just plain wrong...
WOF.. thanks for finding the error, I've corrected it now..
But this is one of the reasons why i like to have the code posted on an open forum. Other can rip your code appart and find all the stupid things you do...
Well done so far, Gremmy, but you are not done yet. There's still some oooops pending.
Ok, it's not too grave. When I send Otto or Dummy, the first letter gets mingled with the colon from the senders name and becomes a smilie. Maybe after the username's colon to write a blank would remedy matters... but I couldn't find the proper place ad hoc. There are so many ":" written...
And even if I really admire the way, the smilies are coded , as an afterthought I might have put the images in a ressource file, which would allow to replace them with own images in, cause I never knew how I would transfer one of my favourite smilies in the program.
Yeah, but putting them in an .ini file would also require that fancy RTF coding, isn't it?
When I want to change smilie image, I think I'd like to see the actual image I'm replacing. Sure, the ressource file cannot be changed at runtime without more effort.
Otherwise you'd need a utility to convert images into RTF code.
Hmm.. i might have to write in some code to do the RTF coding for any specified image, My prelim tests with animated smilies shows that it wont work... RTF is not able to cycle gif images.. If seems to hold a single image (Looks like first only).
Using a resource file i'd still need to store images in the RTF coding, unless i write somthing that can convert them at a reasonable speed...
* The Best Reasons to Target Windows 8
Learn some of the best reasons why you should seriously consider bringing your Android mobile development expertise to bear on the Windows 8 platform.