15,885,985 members
Sign in
Sign in
Email
Password
Forgot your password?
Sign in with
home
articles
Browse Topics
>
Latest Articles
Top Articles
Posting/Update Guidelines
Article Help Forum
Submit an article or tip
Import GitHub Project
Import your Blog
quick answers
Q&A
Ask a Question
View Unanswered Questions
View All Questions
View C# questions
View C++ questions
View Javascript questions
View Visual Basic questions
View Python questions
discussions
forums
CodeProject.AI Server
All Message Boards...
Application Lifecycle
>
Running a Business
Sales / Marketing
Collaboration / Beta Testing
Work Issues
Design and Architecture
Artificial Intelligence
ASP.NET
JavaScript
Internet of Things
C / C++ / MFC
>
ATL / WTL / STL
Managed C++/CLI
C#
Free Tools
Objective-C and Swift
Database
Hardware & Devices
>
System Admin
Hosting and Servers
Java
Linux Programming
Python
.NET (Core and Framework)
Android
iOS
Mobile
WPF
Visual Basic
Web Development
Site Bugs / Suggestions
Spam and Abuse Watch
features
features
Competitions
News
The Insider Newsletter
The Daily Build Newsletter
Newsletter archive
Surveys
CodeProject Stuff
community
lounge
Who's Who
Most Valuable Professionals
The Lounge
The CodeProject Blog
Where I Am: Member Photos
The Insider News
The Weird & The Wonderful
help
?
What is 'CodeProject'?
General FAQ
Ask a Question
Bugs and Suggestions
Article Help Forum
About Us
Search within:
Articles
Quick Answers
Messages
Comments by Richard.Berry100 (Top 36 by date)
Richard.Berry100
3-Nov-14 15:34pm
View
Thanks Bill.
I found this PHP which seems to be the closest to what I'm looking for... Now to learn PHP :(
http://www.sourcexref.com/xref/phpjmt/nav.html?Makernotes/nikon.php.source.html
Richard.Berry100
2-Nov-14 4:00am
View
It must be out there somewhere...
It does seem as though different Cannon models have a different MakerNotes. This site has quite a large number of Camera Specific tags for various Canon models.
http://www.sno.phy.queensu.ca/~phil/exiftool/TagNames/Canon.html
What I'm just not getting is that they all start with Tag 0 or Tag 1 - suggesting that these tags are within the MakerNotes blob of data.
I posted a dump of the makernotes data (7600 Bytes) on Stack Overflow:
http://stackoverflow.com/questions/26696074/read-makernote-exif-tag-in-c-sharp/26696961#26696961
But this blob of data does not seem to conform to the IDF hearder format:
4.6.2 IFD Structure
The IFD used in this standard consists of a 2-byte count (number of fields), 12-byte field Interoperability arrays, and
4-byte offset to the next IFD, in conformance with TIFF Rev. 6.0.
Each of the 12-byte field Interoperability consists of the following four elements respectively.
Bytes 0-1 Tag
Bytes 2-3 Type
Bytes 4-7 Count
Bytes 8-11 Value Offset
Pg 13/14.. in http://www.kodak.com/global/plugins/acrobat/en/service/digCam/exifStandard2.pdf
As far as commercial apps go, I'm new to photography, so the app I'm busy with is intended to view the images, see settings used where results were good/bad, and then move or copy the images to keep into a separate folder, delete the bad ones - basically analyse and sort, and perhaps later rate...
Richard.Berry100
2-Nov-14 1:57am
View
Thanks Bill. If you are referring to the Java App by D Noaks (Converted to C# by Ferret Renaud) - Pretty hectic. I cant make head or tail of it, and cant seem to get an output from the command line. It does however seem like if I could extract parts of this, it would work for my application. I browsed around DPReview a but, and only came accross an app called Thumber, but did not find anything about reading tags from code
Richard.Berry100
1-Nov-14 10:46am
View
Hi Bill. Thanks for your reply (And caution!!) The C# link, unfortunately does not decode the MakerNotes. The other links led me to some other source, but it was Java, and the executables would not run on my machine. But I could not find how they actually extracted the MakerNotes. I have update the question a bit with some of the info you pointed me to.
Richard.Berry100
23-Aug-14 12:02pm
View
Not sure why you would want to do this? I'd tend towards creating an Excel Template with correct column headings that users can populate and import? What would you do with the data after it is in the Database, if a field can have different data. Perhaps look at the database structure, and have a separate table with a Quote ID, and a number of rows with an ItemType, and Value.
Richard.Berry100
23-Mar-14 13:12pm
View
Hi Bill
I had been using the autocomplete on the combo, but unless you start with the correct characters, many combinations are excluded. EG IC501 may be incorrect, it should be U501, so I want to pick up '501' and show U501 even if IC501 was typed. Once a valid selection is chosen, then I need to get other data about that selection with another query. In other words, I want to display selectable options bvased on as query SELECT * FROM BlaBla WHERE Position Like '%TextBoxText%' if that makes sense? Did you have a look at the link?
Richard.Berry100
23-Mar-14 13:03pm
View
This works for me for single cell:
DataGridViewCellStyle CellStyle = new DataGridViewCellStyle();
CellStyle.BackColor = Color.Yellow;
this.dataGridView1.Rows[r].Cells[c].Style = CellStyle;
Richard.Berry100
28-Oct-13 0:50am
View
From what I remember you supply a SELECT command.
see: http://stackoverflow.com/questions/8171647/c-sharp-using-dataadapter-to-update-sql-table-from-a-datatable-sql-table-no
Richard.Berry100
27-Oct-13 18:04pm
View
There is a DataAdapter.Update(DataTable) method. So you would need to supply an 'updated' Datatable as a argument - derived from your datagridview
Richard.Berry100
27-Oct-13 16:05pm
View
Your command text is an INSERT statement, but you go cmd.ExecuteReader?
should it not be cmd.ExecuteNonQuery();
Richard.Berry100
13-Oct-13 1:45am
View
Thanks Ron - appreciated. I ran into a brick wall with the file association - I'm using clickonce deployment. It also seems there are different ways to get the info of the file clicked when using clickonce. Somthing along the lines of:
string[] activationData =
AppDomain.CurretnDomain.SetupInformation.ActivationArguments.ActivationData;
Richard.Berry100
12-Oct-13 15:21pm
View
I seldom use a dataset. What happens if you just put: dataGridView1.DataSource = DT;
and leave out all the code after that. If your select statement has 4 coulums, those should be displayed.
Also, put a breakpoint before you assign the datatable as the datasource for the dtatgridvied, and hover over the datatable. Are you sure the datatable contains data?
you could also put a statement like
MessageBox.Show("Datatable contains " + DT.Rows.Count + " Rows");
dataGridView1.DataSource = DT;
Richard.Berry100
12-Oct-13 15:08pm
View
I have had similar issues, but after asking a simple question: "Why would someone want to SEE thousands of rows of Data?" I ended up filtering the result set that is displayed, with the option to export larger subsets of the Data to Excel, where the user can use Excel to analyse the data
Richard.Berry100
12-Oct-13 14:37pm
View
@OriginalGriff +1 for your answer. Sounds like homework.. So you may want to provide the connection string as well. Probably something like:
string strConnect = "Provider=Microsoft.ACE.OLEDB.12.0;Data source=myDB;Mode=Share Deny None;"
(Not hundreds on the connection string for Access - burned my fingers badly there and will never use it again. SQLEXpress id working wonders for me :))
Richard.Berry100
17-Jul-13 17:43pm
View
I suppose something as setting the TopMost property of the form to true wont help?
Richard.Berry100
9-Jul-13 14:57pm
View
Sincere apologies - I did not read your question properly. Just out of interest though, I've done some very similar apps, why does the WINDOW lose focus?
Richard.Berry100
4-May-13 12:42pm
View
X86 Package (SharedManagementObjects.msi) http://go.microsoft.com/fwlink/?LinkID=188438&clcid=0x409
or
X64 Package (SharedManagementObjects.msi) http://go.microsoft.com/fwlink/?LinkID=188439&clcid=0x409
You can also try browsing to the actual dll - On my machine its:
C:\Program Files\Microsoft SQL Server\100\SDK\Assemblies\
Richard.Berry100
31-Jan-13 12:37pm
View
Thanks for your answer - see my comment to OriginalGriff's answer. That way I can make sure they clicked the date - even if it is today's date
Richard.Berry100
31-Jan-13 12:31pm
View
Oops my bad - I did not expect that the ValueChanged event would fire if you selected the current date. If they are selecting Today's date, I need to know that they intentionally chose Today's date, and did not forget to select the date - if that makes sense. I realize the date will always be a valid date. Thanks for the reply!
Richard.Berry100
25-Aug-12 10:05am
View
Hi Sergey
Sorry for the late reply...
I have not experimented with microtonal music. I would imagine that if you made a software keyboard, were you can play the note, and then increment or decrement the pitch wheel, and used a decent frequency counter (either hardware, or perhaps a software app (FFT?) your could calibrate the various tones by seeing how many pitch wheel increments are needed to get the desired frequency?
Richard.Berry100
25-Aug-12 9:54am
View
Hello Sergey
Sorry for the late reply :).
I have not experimented in micro-tonal music.
I did look into Equal Temperament tuning - one of my guitars has some intonation issues, and I found that by NOT using a tuner for all strings I get better results...
This was some of the info I looked at:
Equal Temperament is a musical tuning system that divides the Octave into 12 geometrically equal steps.
Each step is one semitone. When moving up one step, the frequency (or pitch) increases by 2^(1/12). Using this system, the Octave (12 semitones) is perfect, because 2^(12/12) = 2^1 = 2, an exact doubling of frequency. But the Fifth (seven semitones) is 2^(7/12) = 1.498 times the root. A perfect fifth, on the other hand is exactly 1.5 times. The difference is small, but it is significant. If you want to hear this, play the 6th string 7th fret harmonic. Now stop the string at the 7th fret and play the assisted harmonic at the 19th fret (effectively the new 12th fret). This note will sound very slightly flatter than the 7th fret harmonic. In Equal Temperament tuning, the slightly flat note is the correct pitch.
The best way to tune:
• Use a concert A tuning fork to tune the 5th string to A. You may use the 5th or 12th fret harmonics if you like, as octaves (and double octaves) are perfect. When the 5th string is tuned, don't alter it again!
• Play the 7th fret E on the 5th string (the stopped note, not the harmonic!!)
• Tune the open 6th string to this note (one octave down). If you prefer, you can use the 12th fret harmonic for unison tuning.
• Again play the 7th fret E on the 5th string
• Tune the open 1st string to this note (one octave up). If you prefer, you can use the 19th fret assisted harmonic on Master String 5 for unison tuning.
• Play the 5th fret D on the 5th string
• Tune the open 4th string to this note (by unison)
• Play the 2nd fret B on the 5th string
• Tune the open 2nd string to this note (one octave up). If you prefer, you can use the 14th fret assisted harmonic on Master String 5 for unison tuning.
• Play the 10th fret G on the 5th string
• Tune the open 3rd string to this note (by unison)
The advantage of this method is that any slight detuning tendency is not passed cumulatively from string to string, as every string is tuned directly to the Master String. However, you should only use this method if your 5th string passed the 12th fret harmonic test described above. If your 4th or 6th string is more accurate, the method can easily be adapted, but as concert A tuning forks are the most readily available, the A-string is best.
PS: I completed the little maths practice game for my son. It is not very fancy, but he likes it. He is only in Grade 1 (first year of school) so it gives him addition and subtraction sums and score etc I included round buttons as per your reference, and midi sound when the game is running (more as a continuous noise so that other noises in his environment do not distract him) So once again - thanks very much for all your input, much of which I think I will come back to for future versions of his program :)
Richard.Berry100
6-Aug-12 19:07pm
View
LOL - ok found it - looks a lil different - thanks!
Richard.Berry100
6-Aug-12 18:56pm
View
How risky is it to donate to his website?
Richard.Berry100
6-Aug-12 18:44pm
View
Lots in common! (I think I did accept answer? and vote too?)
Perhaps this should be in the Lounge or something - lots of subjects.
I use midi to playback midi files for live performance. Windows GS synth sounds are bad... I have foobar2k, which I use to convert midi to wav, then flv to convert wav to MP3 (small file) and use wimm.dll to play. Would be very interested to find way to play midi file properly in VB (not C#:() especially sysex messsages, bank changes etc, and to choose a different sound source to windows (i.e soundfont *.sf file)
Richard.Berry100
6-Aug-12 18:07pm
View
@Kenneth - The GP example is great, but a little beyond my current capability! Looks awesome though!
Richard.Berry100
6-Aug-12 17:35pm
View
@Kenneth - no kiddin!
@Sergey - Mmm thats a nice idea - midi - I'm a part time musician and have already done an app to play back midi files, so that should be pretty simple to copy some code across! (MCI - i used winmm.dll - sure i got vb code from Code Project - so anyone reading this.. Just search midi for vb code)
You guys must be very young and very bright.... Coz u bending my poor little brain now - maybe I should stick to rock n roll n dirt bikes and pack the pc away! (But no.. cant do that now) thanks so much hey. Its goindg to take me some time to go through all the links - I'll reply
Richard.Berry100
6-Aug-12 17:01pm
View
WOW! I dont think if I went to University I would get so much excellent knowledge offered to me in a matter of minutes! My son does appreciate simple things - we walk in the bush, and make a simple bow and arrow from a tree branch and a string - he loves it more than all these fancy toys full of bling and fancy noises! He's not doing great in math at school, so I'm gonna start with something basic for the beta version :) I will (thanks only to your answers, try a WPF app :) - and you make a good point - work with whats available now, but as a non-professional, whats quick to learn, and not going to be obsolete in a year's time means a lot to me..
Ok... I just opened a new WPF project and I get a window called MainWindow.xaml - Now what! (I dont expect you to answer that - just wanted to show my level of (or lack thereof) development expertise :)
Richard.Berry100
6-Aug-12 16:15pm
View
Thanks Kenneth - I suspected there was probably a better way of doing this than Win Forms. I'm not a professional developer, and most of the apps I do are more database related. I've been keen to change to C# instead of vb, but every time I start an app in C#, I end up getting frustrated with syntax and for the sake of getting the job done fast, I end up in vb again. What is the future of WPF? Metro? I know nice looking user interfaces make people think you can write great code, but whats really best? Be interested to hear your opinion!
Richard.Berry100
6-Aug-12 16:01pm
View
Thanks Sergey - I think you must be a great dad then!
Richard.Berry100
6-Aug-12 15:58pm
View
Ey richcb - that is soooo cool!!! Thanks so much! Already it looks so much better. Sure my kiddie is going to love it!
Richard.Berry100
19-Apr-12 23:30pm
View
Lets say you are getting the data to put in the cell from a textbox called txtPrice.
Dim Price as Integer = Cint(Me.txtPrice.Text) 'Convert the value in the textbox to an integer
Me.Datagridveiw1.Rows(1).Cells("Price").Value = Price 'Put it in the datagrid
Basically you can use one of many covert functions BEFORE you put the value into the datagrid (Cint, CDbl, CBool, CStr)
You could even write it like this:
Me.Datagridveiw1.Rows(1).Cells("Price").Value = CInt(Me.txtPrice.Text)
Richard.Berry100
26-Feb-12 4:12am
View
Thanks - I only read your link after posting :) It is a very good example, and easy to follow - also mentions SQL Injection attack, and yeah, concatenating SQL statements with all those single quotes, and hashes for dates etc - what a pain! I hope morrish7 follows your advice on a parameterized query
Richard.Berry100
26-Feb-12 2:59am
View
Perfect - Thanks!!!
Richard.Berry100
29-Jan-12 1:08am
View
Thanks SA. I did not realize the difference between 'Application' and my MainForm, and that the Application is opening the form from Sub Main. Is there a way to see the Sub Main in Visual Studio?
Also in my case, what I actually wanted to do was close the form properly, which would then cause the Application.Run to exit. (Not Application.Exit)
From the link you suggested, if the form is closed properly: The FormClosing event occurs as the form is being closed. When a form is closed, it is disposed, releasing all resources associated with the form.
I am largely 'self/internet' taught, and have clearly missed out on a lot of the basics, so thanks for your time to explain!
Richard.Berry100
28-Jan-12 3:14am
View
Thanks for the info. I set the frmMain as my Startup Form under Project Properties, so I'm not really using Sub Main() as your example above? Or maybe that is what Visual Studio is doing? It seems to work fine if I put the file validation in the Form Load event though. Not sure if there is a difference?
Richard.Berry100
28-Jan-12 2:54am
View
I'm not an expert, but if I put 'End' in place of Me.Close, it does kill the application?
If I type End, intellisense shows:
End Statement
Stops Execution Immediately
Show More