|
Your welcome
|
|
|
|
|
You could easily do this in a RegEx by itself and avoid looping through the matches. \W captures all non-word characters (anything not a-z A-Z or 0-9), so you can then just use the Replace method of the Regex class.
Dim resultString As String
resultString = System.Text.RegularExpressions.Regex.Replace("ABC$%123*>890!#XYZ", "\W", " ")
I haven't done VB since VB6, but I assume that should work as it's a simple statement.
|
|
|
|
|
Hi,
I need to write an Windows Application where the user authenticate against a SQL 2005 Server. What I need is to have a custom authentication and authorization system that's available when building ASP.NET apps.
How would I go about finding out how to type in a Username and Password and then authenticate against a SQL server.
Thank you
Illegal Operation
Making Computer Software Talk
|
|
|
|
|
Illegal Operation wrote: How would I go about finding out how to
Step #1: Read the documentation
Step #2: Have a beverage
Step #3: Repeat steps 1 and 2 until you understand the documentation
led mike
|
|
|
|
|
Hi all,
im working on a Solution to grab all Files in a Directory, but the Compiler woudn't accept my Code. He says all the Time (string have no definition for "GetFiles"
Here is my Code
private void Form3_Load(object sender, EventArgs e)
{
string dir = @Application.StartupPath + "\\XML\\";
DirectoryInfo tdir = new DirectoryInfo(dir);
FileInfo[] dateien = dir.GetFiles(); //<-- Here the Compiler underline GetFiles as a Mistake, why
}
Why he do that?
Thanks for helping
Daniel
|
|
|
|
|
Hi, if file name (string[]) list is enough for you, you could use Directory.GetFiles(dir) static method too. (That's what I usually use, dunno why your code shows error.)
Oh, your code should say "tdir.GetFiles()" I think
|
|
|
|
|
Hi,
climbah wrote: Here the Compiler underline GetFiles as a Mistake, why
climbah wrote: Why he do that?
it sits right in front of you, there is dir and there is tdir, they ar not the same.
if you want to program, you should be able to spot a mistake in the line the
compiler tells you is wrong; rest assured, the compiler will be right almost
all the time, and way more often than you are.
Luc Pattyn [Forum Guidelines] [My Articles]
This month's tips:
- before you ask a question here, search CodeProject, then Google;
- the quality and detail of your question reflects on the effectiveness of the help you are likely to get;
- use PRE tags to preserve formatting when showing multi-line code snippets.
|
|
|
|
|
Thank you alot, Ferenc Veres, it was that, what you said, the code should say tdir instead of dir.
if you want to program, you should be able to spot a mistake in the line the
compiler tells you is wrong; rest assured, the compiler will be right almost
all the time, and way more often than you are.
I know that i should be able to analyse and interpret compiler mistakes, and i even dont know, why i put dir before getfiles()
Maybe it wasnt my day yesterday, ... anyway thank you for your help and maybe next time i can help you
Daniel
PS: Sorry about my English, i know, it isn't the best
|
|
|
|
|
Hi,
I am looking to impliment the Security Application Block from the Enterprise Library 3.1.
Does anyone have a good tutorial or sample code I can look at?
Thanks...
Illegal Operation
Making Computer Software Talk
|
|
|
|
|
Illegal Operation wrote: Does anyone have a good tutorial or sample code I can look at?
They hide those in the documentation. Good luck, you're going to need it.
Reference Implementations are executable sample applications that demonstrate patterns & practices guidance in action.
led mike
|
|
|
|
|
How can I put the pixel in GDI+.Please don't go to image processing.
There is no tool avalible in C# to put the pixel.
Anybody hep me to get this answer.
Continue...
|
|
|
|
|
You can use Graphics.FillRectangle with a width and height of 1.
Standards are great! Everybody should have one!
|
|
|
|
|
why are you going to FillRectangle that is use for draw rectangle.
C++ and VC++ have set pixel.
Continue...
|
|
|
|
|
why are you going to FillRectangle that is use for draw rectangle
Well, I don't: I've never needed a SetPixel method, really. I'm just giving you a quick fix.
Standards are great! Everybody should have one!
|
|
|
|
|
What is a pixel if not a rectangle of size 1x1?
He who makes a beast out of himself gets rid of the pain of being a man
|
|
|
|
|
There is in fact a SetPixel method.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
There's Bitmap.SetPixel , but no Graphics.SetPixel .
Standards are great! Everybody should have one!
|
|
|
|
|
Well, you didn't say that you needed it on the graphics object. You spoke of image processing, there's no way you can do image processing without a bitmap, so I assumed you were working with a bitmap. A 1x1 rect or a line that is one pixel in size, are your best bets then, I guess.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
winform program,
I had a DataGridView, and Added some Columns.
the colum1's text is ABC,colum2's text is BCD.
query Data from sql:"select id, name from test"
this.dataGridView1.DataSource = ds;
this.dataGridView1.DataMember = "test";
the data biding at dataGridview new Column caudal.
how to biding at ABC and BCD of DataGridView's Column?
|
|
|
|
|
You have to use <boundfied datafieldname="ABC">
Best Regards,
Chetan Patel
|
|
|
|
|
Hi,
If you are looking to set the Column caption of DataGridView to "ABC" and "BCD" after binding it to DataSource (DS) then you can do it in the following manner:
BEGIN CODE
this.dataGridView1.DataSource = ds;
this.dataGridView1.DataMember = "test";
this.dataGridView1.Columns[0].HeaderText = "ABC";
this.dataGridView1.Columns[1].HeaderText = "BCD";
END CODE
I hope this helps .
Regards,
John Adams
ComponentOne LLC
|
|
|
|
|
Still won't do.
when buiding, report Index foul.
before dataGridView binding data,the DataGridView don't has columns,
so report Index foul.I think to is so.
|
|
|
|
|
Your suggestion is viable.
The index foul is my own problem.
Thank you very much.
|
|
|
|
|
Hi, i have a doubt..
I want to send an object to next page..directly....At there using this object, i want to use its memebers and methods. I need to send objects between aspx pages.
Please help me regarding this...
Thanking you
G. Satish
|
|
|
|
|
Store That object in Session
Best Regards,
Chetan Patel
|
|
|
|