|
|
What's the best way to convert a string containing Unicode characters like accented letters to the most logical ASCII representation? Converting to ASCII turns all non-ASCII characters into question-marks, which doesn't seem very helpful. The best approach I can figure is to concatenate each character of the string onto each letter a-z, and then check whether the resulting string sorts between that letter and the next higher character using the default culture. If a letter is found where the string sorts properly, then check whether the string is identical to the uppercase version of itself. If not, the string is a letter a-z; otherwise it's a letter A-Z.
Rather a clunky way to do things, but I don't know of any better fundamental method (obviously performance can be improved considerably if one caches the results, but I know of no better way to determine them initially). Is there any good method?
|
|
|
|
|
Sub Connectionopen()
Try
oraConnection = New OleDb.OleDbConnection(strConnectionString)
If (oraConnection.State = ConnectionState.Closed) Then
oraConnection.Open()
End If
Catch ex As Exception
'MsgBox(ex.ToString & "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!open")
End Try
End Sub
**** i want to put a timer on
oraConnection.Open()
that timer will check in 10 seconds either connection is open or closed.and i want to check this before oraConnection.Open()
thxxx
|
|
|
|
|
rashid2009 wrote: **** i want to put a timer on
oraConnection.Open()
that timer will check in 10 seconds either connection is open or closed.and i want to check this before oraConnection.Open()
Why ? What is the purpose of the Timer over here ? Just Set ConnectionTimeOut Properties for it.
Abhijit Jana | Codeproject MVP
Web Site : abhijitjana.net
Don't forget to click "Good Answer" on the post(s) that helped you.
|
|
|
|
|
Sir, i want a detailed explanation with screen shots of Master Pages, User Controls and Authorization and Authentication in ASP.NET 2.0.
Sir , I also want a detailed difference between GET AND POST METHOD.
|
|
|
|
|
Sir, what is stopping you from buying a book? Read this[^] before you post questions.
|
|
|
|
|
Swastik Das wrote: Sir, i want a detailed explanation with screen shots of Master Pages, User Controls and Authorization and Authentication in ASP.NET 2.0.
Sir , I also want a detailed difference between GET AND POST METHOD.
I want Carmen Electra to come round to my house and give me an oiled rubdown tonight. It looks like we're both going to be disappointed.
"WPF has many lovers. It's a veritable porn star!" - Josh Smith As Braveheart once said, "You can take our freedom but you'll never take our Hobnobs!" - Martin Hughes.
My blog | My articles | MoXAML PowerToys | Onyx
|
|
|
|
|
Pete O'Hanlon wrote: I want Carmen Electra
I thought that was a ladies' hair dryer
|
|
|
|
|
So, she blows???
"WPF has many lovers. It's a veritable porn star!" - Josh Smith As Braveheart once said, "You can take our freedom but you'll never take our Hobnobs!" - Martin Hughes.
My blog | My articles | MoXAML PowerToys | Onyx
|
|
|
|
|
what is the code to attach the database to data grid using List box
|
|
|
|
|
jjppyy wrote: what is the code to attach the database to data grid using List box
Probably in here[^] somewhere.
|
|
|
|
|
It doesn't exist; you'll have to write it.
|
|
|
|
|
hiiiiii
I m running a .exe from asp.cs page .job of exe is to generate images in a folder which is already there in my application.exe is running and woking properly when i m running the application in my system at localhost.but when i m running my application in the clint side on there application server then exe is running but it is not doing any thing ,i have seen in my
task manager that exe runs but take no cpu storage.
its really urgent........
thanks in advance......
|
|
|
|
|
|
If you want to run the exe in the client machine, you need to make the user download the exe to their machine and then run themselves.
You cant have access to the client machine directly.
|
|
|
|
|
Hello,
looking web base multi format video convector.
please help
thanks
|
|
|
|
|
Hi all,
I have created a setup project with Visual Studio 2008 to deploy my C# application. Everything is fine, but I want the installer to offer the user to choose which language has to be used during the installation process. I haven´t found any where how to do it. Any suggestion? Does the setup project includes this feature? Any other tool to make the installer?. Thanks in advance.
Best Regards
|
|
|
|
|
I have not tried. But the MSI project allows you to add custom actions. That should do the trick.
|
|
|
|
|
Hi,
I created a form that is invoked as a modeless dialog:
MyForm dlg = new MyForm();
dlg.Show(); // instead of ShowDialog()
This form should be closed after a user hits the Escape key. Unfortunately, neither the assignment of a cancel button (with Dialogresult 'Cancel') to the form's property 'Cancelbutton' nor any attempt to catch a key event (KeyDown, keyPress) are working. I even tried to catch a WM_KEYDOWN (0x100) by overriding OnWndProc, no success. Does anyone have an idea where this message gets stuck or how to trap it?
Thanks a lot in advance!
|
|
|
|
|
Hi,
a dialog is modal by definition; it has focus and gets all user input (mouse, keyboard) for as long as it is visible.
a modeless Form (any Form shown with Show() method) may loose focus, in which case it does not get user input events, as something else now has focus and gets them.
You could organize your code in such a way that the ESC key closes a particular form no matter what, but that would take some doing and be very counterintuitive.
Luc Pattyn
Local announcement (Antwerp region): Lange Wapper? Neen!
|
|
|
|
|
Thanks,
unfortunately, it's not a focus problem. Nevertheless, it seems that handling the 'escape' button click is the only way to get around. Still wondering why i can't trap a key event.
Thanks again.
|
|
|
|
|
It worked for me. Added a button on to the form, wrote this.Close() on that button's click event handler, set that button as CancelButton of the form. It works well.
|
|
|
|
|
Looks like it'll be the only way. For some reasons i would have favoured an approach to trap the key event and handle it by myself. For now, it remains a mystery to me why i can't do so. Anyway, thanks!
|
|
|
|
|
You have to think of it in the Windows way. Under normal circumstances it is the active window that receives the keyboard input. So if you have a modeless dialog that does not have the focus then it will not receive the escape key. The only way to signal that dialog is by making it the active window.
|
|
|
|
|
If you are catching the Escape key in the Form's Keypress or KeyDown events, you must set the form's KeyPreview property to true.
|
|
|
|