889 Posted Topics

Member Avatar for toadzky

Can you post your code of where you attach the Map attribute to the Variant node in your application?

Member Avatar for toadzky
0
227
Member Avatar for CeeGee

Check your opening { and closing } throughout your file. The sample you provided closes the class very early in your code...

Member Avatar for samueal
0
2K
Member Avatar for almostbob

Hilarious post, thanks for sharing almostbob :) And all you lot, come to Australia and visit us eh?

Member Avatar for almostbob
2
403
Member Avatar for JakeA

You can use a [URL="http://msdn.microsoft.com/en-us/library/system.io.filestream.aspx"]FileStream[/URL] for this: [code] string filepath = "C:\\test.html"; using (FileStream output = new FileStream(filepath, FileMode.Create)) { provider.Export(document, output); } [/code]

Member Avatar for darkagn
0
535
Member Avatar for divin757

You could use the String.Split function to split each line according to where each space is. Then you could just substring from the = signs to get the digits. Something like this (untested but should give you an idea): [code] while ((s = sr.ReadLine()) != null) { string[] chunks = …

Member Avatar for Xcelled194
0
129
Member Avatar for Romil797
Member Avatar for lianpiau

Not sure what you mean by the first one, but for 2, it is easier and more accurate to use an identity field in the database.

Member Avatar for lianpiau
0
2K
Member Avatar for horserider

[URL="http://www.delphibasics.co.uk/index.html"]DelphiBasics[/URL] is a great starting point. Two very basic tutorials, lots of sample code and descriptions of many commonly used units will give you a start.

Member Avatar for PlotHost
0
105
Member Avatar for zachattack05

Check out the [URL="http://msdn.microsoft.com/en-us/library/system.io.fileinfo.aspx"]FileInfo[/URL] class. This gives access to creation, access and modified dates. Not sure about tags and the like, possibly the FileInfo.GetAttributes method might return these (and SetAttributes to modify them?)

Member Avatar for zachattack05
0
119
Member Avatar for WolfShield

I have never used the WebBrowser control, but my understanding of it was that it was simply a frame for viewing web pages. I believe you need to implement other controls such as a Back button and call the browser's GoBack function when the button is pressed.

Member Avatar for WolfShield
0
128
Member Avatar for markyoung1984

Use [URL="http://logging.apache.org/log4net/"]log4net[/URL], it is thread-safe and can log to various different appenders including a text file (RollingFileAppender).

Member Avatar for darkagn
0
207
Member Avatar for xanawa

Your SQL is attempting to put the value 'False' (as in the string) into a tinyint (which is numeric) column. You need to check the boolean value and assign it to a 0 or a 1. You are converting it to a string by setting it the way that you …

Member Avatar for xanawa
0
1K
Member Avatar for niketakapoor

Without a WHERE clause in your SQL statement the UPDATE function will change data of every record in the table. I would suggest changing the statement to something like: [code=sql] Update Lib_member_details set member_name=@member_name,member_address=@member_address,member_contact_number=@member_contact_number,member_email_id=@member_email_id,member_password=@member_password,membershiptype_id=@membershiptype_id WHERE member_id = @member_id [/code] Assuming that your database table has a member_id column and you …

Member Avatar for niketakapoor
0
258
Member Avatar for shyla

I don't think your main method belongs to the GeometricFigure class. The main method should go in the ShapesDemo class instead. Having said that, your project description tells you to accept a GeometricFigure parameter to a method in which it's figures (height, width, area) is displayed. Your method signature should …

Member Avatar for shyla
0
258
Member Avatar for salmap

So what have you come up with so far? We aren't allowed to just hand you code, we need to see some sort of effort...

Member Avatar for salmap
0
128
Member Avatar for zachattack05

I believe that it doesn't (although I could be wrong). However you can extend the class and override those operators to suit your needs.

Member Avatar for zachattack05
0
79
Member Avatar for nayansaurabh

Or if you want to do it in SQL: [code=mssql] SELECT * FROM salesdetail WHERE DATEDIFF(YEAR, Date, CURRENT_TIMESTAMP) = 1 -- OR SELECT * FROM salesdetail WHERE DATEDIFF(DAY, Date, CURRENT_TIMESTAMP) = 365 [/code]

Member Avatar for bhagawatshinde
0
479
Member Avatar for Nevillelajru

The only encryptions worth using are one-way encryptions. C# has a few classes that can do this, the only one I have used is the [URL="http://msdn.microsoft.com/en-us/library/system.security.cryptography.rijndael%28v=VS.90%29.aspx"]System.Security.Cryptography.Rijndael[/URL] class, however you should use AES instead if you need a more secure algorithm. There is lots of sample code on the MSDN website …

Member Avatar for Nevillelajru
0
331
Member Avatar for gunnerone

You are on the right track, except that your delimiter for the split function should be a comma ',' rather than a carriage return character '\r'. Once you have done the split, you will have three values in your split1 array - from unit, to unit and multiplier value. I …

Member Avatar for geekman92
0
334
Member Avatar for Kath_Fish

Rather than AppendLine, use Append. Your variable read contains an endline character since that is how the ReadLine terminates the line. [code] while ((read = f.ReadLine()) != null) { s1.Append(read); } [/code]

Member Avatar for Kath_Fish
0
98
Member Avatar for darkagn

Hi all, Can someone tell me if this is a delphi bug? I am using a Controls.TDate to store a date and using the SysUtils.EncodeDate function to set the value. [code] Invoice.DateReceived := EncodeDate(2011, 03, 16); [/code] When I store it in a MS SQL database field, it is adding …

Member Avatar for Wolfgan
0
165
Member Avatar for rannamaa

To build a GUI, choose Windows Forms Application for the project type. A console application is one that runs on a command line or via a batch file. You are correct about adding a class. Your exe file will be created in your bin folder from where you save your …

Member Avatar for rannamaa
0
124
Member Avatar for winrycool1

Don't get too hung up on which languages you need to learn. It's more about learning problem solving skills, design patterns, data structures and algorithms. I learned Java at university and about 1% of the commercial code I have written has been in Java. Once you know one language, subsequent …

Member Avatar for abelLazm
0
174
Member Avatar for pradvin

Hi pradvin and welcome to DaniWeb :) You will need to join your tables to get all of the information that you need. The syntax for a join statement is like so: [code] -- select which columns you need SELECT Table1.UnitID, Table1.Quantity, Table2.CostPrice, Table2.SellingPrice -- from which table FROM Table1 …

Member Avatar for debasisdas
0
76
Member Avatar for moni94

Yes you can remove the <T> from the name of the function, like so: [code] static void foo(this List<T> list, T t) { ... } [/code]

Member Avatar for Momerath
0
96
Member Avatar for ajinkya112

There are two ways that you can tackle this problem. Either make the ID field in the table an identity field then read it back after you insert the name, or you can retrieve the biggest ID number and add 1 to it using this value to insert.

Member Avatar for Mitja Bonca
0
345
Member Avatar for Fortinbra

What type of join are you using on the tables? Cross joins in particular can be very slow with so many records, are you able to change to inner or left/right outer joins? If not, you could try running three separate select statements and filtering down the result set each …

Member Avatar for Fortinbra
0
110
Member Avatar for nutrion

Your code should be correct, but you may possibly need to create a new object rather than trying to reuse your key object. [code] RegistryKey key = Registry.LocalMachine; var subKey = key.OpenSubKey(location, isWritable); // where location is the string of the address for the subkey // and isWritable is a …

Member Avatar for nutrion
0
239
Member Avatar for akshayinbox

Try C# using Visual Studio for a windows solution to your needs. C# uses the .NET framework and allows you to design forms and use a code-behind method to handle events, data etc. If you need cross-platform Java has similar capabilities using NetBeans design mode. C++, C# and Java are …

Member Avatar for John A
0
234
Member Avatar for PhiberOptik

Really your question has many different answers depending on the individual. Personally I prefer Eclipse, but NetBeans is very popular. I used to use jEdit and I always liked it, but it wasn't a true IDE, just a text editor with a few plugins for java development.

Member Avatar for mjason
0
214
Member Avatar for revjim44

The easiest way is to store the arrays as properties of a class, then set the data source of your DataGridView to an instance of the class and add columns with the DataPropertyName set to the two properties that you created. Example: [code] public class MyContainer { public string[] Items …

Member Avatar for Momerath
0
130
Member Avatar for arjunpk

You can traverse child nodes quite easily in C#. Example: [code] // assume here I have a DataSource node called node foreach (XmlNode childNode in node.ChildNodes) { string nodeValue = String.Empty; // use a case insensitive search on the node name string childNodeName = childNode.Name.ToLowerInvariant(); if (childNodeName == "name") { …

Member Avatar for arjunpk
0
298
Member Avatar for AngelicOne

The SQL WHERE clause allows boolean logic operators AND and OR. You can combine your statement into one like so: [code] SELECT * FROM person WHERE lastname = @lastname AND firstname = @firstname AND ID = @id [/code]

Member Avatar for debasisdas
0
226
Member Avatar for Zephyr-

The easiest way is to use the [icode]Add[/icode] method of the [icode]Items[/icode] property of the listbox: [code] myListBox.Items.Add(myObjectToBeAdded); [/code]

Member Avatar for Mitja Bonca
0
110
Member Avatar for Jessurider

You can set the Form's StartPosition property to CenterScreen, CenterParent, WindowsDefaultLocation or WindowsDefaultBounds. Alternatively you can use the Location property of the form to set the X and Y coordinates of the form, in which case the StartPosition property should be set to Manual. Most often in your situation I …

Member Avatar for darkagn
0
92
Member Avatar for darkagn

Hi, It appears that the code tags in the MSSQL forum aren't working today. Example: [URL="http://www.daniweb.com/forums/thread348193.html"]this thread[/URL].

Member Avatar for darkagn
0
101
Member Avatar for DoubleJump

Hi DoubleJump and welcome to DaniWeb :) I personally think you should do whichever interests you the most, and only you can answer that. If you can't decide perhaps think about what career are you would like to pursue after you finish your studies and do some research about what …

Member Avatar for Rashakil Fol
0
139
Member Avatar for Suzukaze

Hi Suzukaze and welcome to DaniWeb :) You need to join the tables, the syntax is like this: [code] SELECT g.GroupName, COUNT(m.MatricNo) AS "Member Size" FROM Group G -- join to the MemberOfGroup table INNER JOIN MemberOfGroup M -- describe how the tables are related ON m.GroupID = g.GroupID -- …

Member Avatar for BitBlt
0
116
Member Avatar for NewOrder

I think the easiest way to stop your thread would be to break out of your while loop in the Reader method on a certain condition. [code] while (true) { if (shouldIStop()) break; msg = sr.ReadLine() + Environment.NewLine; allMessages += msg; Invoke(new Action(Output)); Invoke(new Action(AddNameList)); } private bool shouldIStop() { …

Member Avatar for NewOrder
0
173
Member Avatar for AngelicOne

You can use the BACKUP statement to perform a backup of your database, and a RESTORE to perform a restore of a database. [URL="http://msdn.microsoft.com/en-us/library/ff848768.aspx"]Here[/URL] is a link to the documentation for MSSQL2008R2 versions of these functions. Post back if you need help deciphering the documentation.

Member Avatar for darkagn
0
48
Member Avatar for sachintha81

Not sure if this will work, but I think you could create your own IFormatProvider from the english culture info object and use that when formatting the names of the time zones. Something like (adapted from [URL="http://www.csharp-examples.net/custom-iformatprovider/"]this post[/URL]): [code] public class EnglishFormatter: IFormatProvider, ICustomFormatter { private CultureInfo enCulture = CultureInfo.GetCultureInfo("en"); …

Member Avatar for darkagn
0
1K
Member Avatar for gspeedtech

There are a couple of ways to approach this kind of problem but I prefer to use a subquery in this case. Your query will be the subquery for the larger query, and we will select totals from that based on the SequenceID. I suspect your query looks something like …

Member Avatar for gspeedtech
0
159
Member Avatar for Acidburn

Yes, you need to create the primary key as an identity field. Note that this is only possible for numeric key fields (which you have in this case so that's ok). Simply add the word IDENTITY with the first value and increment values in brackets into your field definition, like …

Member Avatar for darkagn
0
106
Member Avatar for AngelicOne

I would have one table, Visitor, then have a VistorType column that determines whether you are dealing with a student, employee or volunteer. This way you only have to join to one table from other tables that need to know about visitor information, rather than trying to join to the …

Member Avatar for darkagn
0
85
Member Avatar for p90pts

Create a property in your base class to house the gamescore enum like so: [code] public gamescore GameScore { get; set; } [/code] Then in the constructor of each class, set the GameScore property accordingly, for example: [code] public MotherShip() { GameScore = gamescore.MotherShip; } [/code] Then in your Die() …

Member Avatar for darkagn
0
111
Member Avatar for vavazoom

Do you need to initialise your Matrix temp to contain all 0's before performing your sums? The += operator might cause issues if the double temp.matrix[i,j] hasn't been initialised properly.

Member Avatar for ddanbe
0
184
Member Avatar for prosperr

Hi prosperr and welcome to DaniWeb, Unfortunately we aren't allowed to do your homework for you. We need to see that you have at least thought about these questions before we can even give you a point in the right direction. How do you think these questions should be tackled? …

Member Avatar for mrnutty
0
124
Member Avatar for MrCapuchino

Is the CHM file on the PC running the application or in a network location? A security issue exists where windows will block CHM content when served over a network.

Member Avatar for MrCapuchino
0
108
Member Avatar for MrCapuchino

From MSDN Docs: [QUOTE] The FormBorderStyle, MinimizeBox, and MaximizeBox properties allow you to control whether the form can be minimized, maximized, or resized at run time. [/QUOTE] The FormBorderStyle property has an affect on size and location of your form. Sizable is the default setting. [URL="http://msdn.microsoft.com/en-us/library/system.windows.forms.form.formborderstyle%28v=VS.90%29.aspx"]Here[/URL] is a link to …

Member Avatar for darkagn
0
188
Member Avatar for NewOrder

1. A static method belongs to the class, not to an instance of the class, so the instance variables have no meaning in a static context. You need to create an instance of your class in the static method, then access any public instance variables, properties or methods of the …

Member Avatar for tripleD
0
172

The End.