Topics
-
-
- Leaders
- 3 replies
- 3.3k views
Hi, (sorry for my english!) I have a file like this: "string1","string2","string3","string4".... I want the string between the " without the " and the , In php, my co-worker used this: preg_match_all('|"([^"]*)",?|i', $content, $matches); $content = the file We upgrade in C# With c# I use something like this: MatchCollection Matches = Regex.Matches(fiche, "\"([^\"]*)\",?", RegexOptions.IgnoreCase); I put the result in an array: for (int i = 0; i < Matches.Count; i++) { array.Add(Matches[0].Groups.ToString(); } I have this result 0: "string1", 1: string1 2: (empty) 3: (empty) .... But I have the right count of string. I real…
Last reply by HJB417, -
-
- 0 replies
- 4.9k views
Ladies and Gentlemen, I am presently developing an application that will watermark .TIFF images we have on our system. These images are strictly black-and-white, so they are stored in 1 bit-per-pixel indexed format (Imaging.PixelFormat.Format1bppindexed) which naturally leads to them being very compressed. Now, I know that you cannot assign a Graphics object to an indexed-pixel image, so I create a mediary bitmap in Imaging.PixelFormat.Format24bppRGB and use the first bitmap as a source to draw into the second one, to wit: ' Read source TIFF into new bitmap object Dim m_clsSource As New Bitmap(strPath) ' Create destination bitmap object with the same featu…
Last reply by CMousseau, -
-
- Leaders
- 4 replies
- 1k views
how to create a form without blue bar on the top. I can say windowstyle as none. but if i say like that the window becomes flat. The window should show some shadow (as in regular form).
Last reply by kaisersoze, -
-
- 0 replies
- 843 views
Im currently developing an IM application to work with windows CE , however within the development in VB.NET i was going to use the data adapters etc which are usually found under the data tab in the toobox but they dont seem to exsist when developing a mobile application throught vb.net ? Does anybody know how to get round this to create a connection to a database ? The database im using is a MS Access 2002 one. Please Help Zed
Last reply by ZedEx, -
- 1 reply
- 2.4k views
hi, this might be a dumb question.... but i can't open a workbook from c#... i have already insert the COM reference into the project, it was the MS Excel 11.0 Object Library, TypeLib-Version 1.5. my code looks like this : object oMissing = Type.Missing; Excel.Application oApp = new Excel.ApplicationClass(); Excel.Workbook oWB; Excel.Worksheet oWS; oWB = oApp.Workbooks.Open(@"myxlfile.xls", oMissing, oMissing, oMissing, oMissing, oMissing, oMissing, oMissing, oMissing, oMissing, oMissing, oMissing, oMissing, oMissing, oMissing); it says : "Old Format or Invalid Type Library" on the Workbooks.Open part.... if i write Excel.Application oApp =…
Last reply by ThienZ, -
- 1 reply
- 529 views
I'd like to read version of windows (and service packs) my client is using. tx
Last reply by michael_hk, -
-
- Administrators
- 2 replies
- 1.1k views
I just don't seem to understand what the h*ll I am doing wrong. I know that there is something I haven't quite understood, but I just can't seem to figure out what. I have created two rectangles, one blue and one red. Each rectangle are created by four triangles, where the two first are facing out, the other in. Just to avoid transparency when the object is rotated. That's at least what I thought. Here are two images. The first is what I like it to be. The second image is the source of my frustrations. The two images (screenshots) are taken while the two rectangles are rotating. I use VB.NET, and I have attached my code if something's missing. I am just so cl…
Last reply by theHollow, -
-
-
- *Experts*
- 4 replies
- 5.1k views
Hi, Anyone out there familiar with the old WinInet routines for httpsendrequest and httpopenrequest and such? Although it wasn't as easy to work with as HttpWebRequest, it did have features that seem to be missing in HttpWebRequest. For example, the whole cookie thing... by default the WinInet libraries would get the current cookie for the domain you were requesting the page for from IE, and put it in the headers, that way sites that a user was logged into that I was interacting with, automatically found the login information. With the HttpWebRequest, that is completely lacking... now that said, I know it is possible to add a cookie manually to the header, but they …
Last reply by zeko, -
-
- 2 replies
- 1.1k views
I was curious about CRC32 so I did a quick google search and it brought up some examples. They weren't all that exceptional so I figured I'd post here to get more information. From what I gathered, you take a message that is 32 bit of data in length, then shift it left bitwise 3 places. Take the lowest 5 bits from that message and add 1 to it which would become the checksum. you then append the checksum on the end of the message. To check you would take the message modulo the checksum and shouldn't have a remainder.Is that correct or did I not fully understand it?
Last reply by coldfusion244, -
- 2 replies
- 5.8k views
Hi... I'm having a problem trying to print to DOS printer from a .net program. I use the following line: System.Diagnostics.Process.Start("PRINT", "/D:LPT1 " & Application.StartupPath & "\CodeBarPrint.txt") 'OR System.Diagnostics.Process.Start("C:\WINDOWS\system32\PRINT.EXE", "/D:LPT1 " & Application.StartupPath & "\CodeBarPrint.txt") 'OR System.Diagnostics.Process.Start("PRINT", Application.StartupPath & "\CodeBarPrint.txt") but nothing is printed... Tho, directly in the shell, the print command works and prints the file perfectly. Notes: 1- This is running on a Windows 2003 Server machine 2- This has already worked with the la…
Last reply by AlexCode, -
-
- *Experts*
- 4 replies
- 861 views
i have a cartesian point. i want to insert it into an arrayList of cartesian points. before i insert it, i want to make sure it doesnt already exist. how would you go about this?
Last reply by DiverDan, -
-
-
- *Experts*
- 2 replies
- 1k views
i checked this sql code with swl enterprise manager and it says "Syntax check successful!". But if i run my code it says unhandled exception, system error on the executenonquery line... string createtbl = "CREATE TABLE typicals (typical varchar(200),typicalnr int);"; SqlCommand myinsertcommand = new SqlCommand(createtbl, mycon); myinsertcommand.ExecuteNonQuery(); actually i want to use "create table if not exists", but if i check the syntax from this command it won't accept the "if not exists" part... can someone help me? thx in advance.
Last reply by Nerseus, -
-
I have a timer that is been called every 3 second. As state I add two new objects, but how do I retrieve the information of ID and Line in the Callbackfunction ? report = new System.Threading.Timer(new TimerCallbackthis.Callbackfunction),new object[2]{ID,Line},3000,System.Threading.Timeout.Infinite); private void Callbackfunction(object data) { id = data[0] // Does not work since it is not an array. How do I retrieve data }
Last reply by Jedhi, -
AddMinutes
by Jedhi- 2 replies
- 672 views
long a = DateTime.Now.Ticks; DateTime.Now.AddMinutes(15); long b = DateTime.Now.Ticks; Following example shows that a and b have same value. Instead I have expected that b would have 15 minuttes more than a. How do I make it that way ?
Last reply by Jedhi, -
- 5 replies
- 935 views
I have created a hashtable class with key id and 3 values id, column and error. _hashtable.Add(id,new object[3]{id,column,Error}); To get information about the id and how many Errors the id have, I write Info = (object[])((ArrayList) _hashtable[id])[0]; int _theIdError = (int)Info[2]; _theIdError++ Now the hashtable must be updated to contain the lastest number of errors (_theIdError) for the specific id. How do I do that ?????
Last reply by Jedhi, -
- 6 replies
- 931 views
hi @ all, i have a table in a webform and i must create a link in the table, for example with a link button. i am using vb.net and i have created the link button already, but my problem is to create the click event for the button, which can execute the link when the user clicks the button... please help me... :confused: Apollo0130
Last reply by fizzled, -
- 2 replies
- 999 views
Hello: From a class I want clean a place holder contained in a web form. I�m using this code: using System; using System.Collections; using System.ComponentModel; using System.Data; using System.Drawing; using System.Web; using System.Web.SessionState; using System.Web.UI; using System.Web.UI.WebControls; using System.Web.UI.HtmlControls; namespace WUC_CreDes { public class Class1 { public static bool Hay_PostBack() { WUC_CreDes.WebForm1 parent1 = (WUC_CreDes.WebForm1) this.Page; pa…
Last reply by see07, -
-
- Administrators
- Leaders
- 3 replies
- 785 views
hi ive created a new project which has 7 forms in the program i have a drop down menu which i want to when clicked display other forms. The code i have used to do this is form2.show how ever when i put this in a get this error message "Reference to a non-shared member requires an object reference" Any ideas on how to correct this ? any help would be greatly appriciated. Many Thanks Zed
Last reply by snarfblam, -
-
- 1 reply
- 1.2k views
hi, I have a datagrid that lists documents attached to an article. It has a header row and the details. When there are no documents attached (i.e. Datagrid is empty), the header row expands to the height of the datagrid and the header text is centered vertically which makes it look very ugly. How can I stop the header from expanding , and is there a way I can show blank lines when the datagrid is empty. Thanks
Last reply by kahlua001, -
-
- Administrators
- 2 replies
- 2.9k views
I have started to get the following error message quite often on this forum (the last time was when I tried to post this new thread :) ) There seems to have been a slight problem with the database. Please try again by pressing the refresh button in your browser. An E-Mail has been dispatched to our Technical Staff, who you can also contact if the problem persists. We apologise for any inconvenience. Just wondering if it is something to do with my browser or is anyone else getting it?
Last reply by pendragon, -
-
Who's Online 0 Members, 0 Anonymous, 106 Guests (See full list)
- There are no registered users currently online