|
OriginalGriff wrote: ForColor
I didn't realise you'd been affected by the great Welsh "E" drought. Here, have a few of mine to use:
Eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee!
I think you meant "ForeColor".
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|
|
No, I'm trying to convert my monitor to CMYK and missed out the "U"...
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
|
|
|
|
|
how can we share files in .net on a single pc while files are stored in same database?
|
|
|
|
|
Share with who? And what files woul you store in a database?
|
|
|
|
|
Elaborate more, this insufficient information to get exact problem.
modified 20-Sep-20 21:01pm.
|
|
|
|
|
i have been workinng with how to make androide xml analser. i cant come up with the answer.
|
|
|
|
|
what do you want to specifically?
Life's like a nose, you've got to get out of it whats in it!
|
|
|
|
|
You need to make a specification of what you want this analyser to do. Once you have the specification you will then be able to break it down into smaller jobs and it wont seem so hard.
Every day, thousands of innocent plants are killed by vegetarians.
Help end the violence EAT BACON
|
|
|
|
|
Hey,
first, if i writing on bad category, im sorry, i didnt found the help category..
Okey, to my problem. I have a RGB STRIP connected to Arduino, when im communicating via Serial. All works great! So next i wanted to make some audio visualisation.. So i found some samples etc.. and then i created the Audio Visualisation via C# using BASS.NET, when R has been BASSes, G medium frequency and B high frequency. But isnt looking good, so i started thinking, what 3 variables in song has can use, but this is bad idea.. I got idea to change to random color when its get "beat" or BASS hit some value. I tryied 4 hours of doing it, searching, programming... But i cant do it... Im only 15 and non english so im limited in searching etc...
So, my question is how to detecting the beat or just anything event for Audio Visualisation. Best output form WASAPI. Im out of ideas and anything.. Only what i can do is get FFT and Audio Spectrum from WASAPI by BASS.NET, but thats all. My audio skills is so low for this. Anything is welcome!
Thanks.
|
|
|
|
|
You might want to search for the term BPM (Beats Per Minute). (if not done so already)
Hope this helps.
|
|
|
|
|
Yes, i found something with BPM, but i cant integrate that for the BASS.NET, and i didnt found any example for using it in WASAPI. Is possible to provide some example to BPMCounter for WASAPI in bass.net?
Thanks
|
|
|
|
|
I have a form with a few textboxes and checkboxes. I want to store in database values from them. But, I also have a button that selects an image from computer and show link of the image in a textbox. Well, I want to insert data but without inserting an image and here comes my problem, I receive: Empty path name is not legal . Can anybody help me? Thanks
Code is here:
try
{
byte[] imageBt = null;
FileStream fstream = new FileStream(this.textBox5.Text, FileMode.Open, FileAccess.Read);
BinaryReader br = new BinaryReader(fstream);
imageBt = br.ReadBytes((int)fstream.Length);
SQLiteCommand com = new SQLiteCommand("insert into questions(question,answer1,answer2,answer3,option1,option2,option3,category,qcategory,indexrow,indexyes,indexno,cherowstart,cheyes,cheno,currentrow,image) values('" + textBox1.Text + "','" + textBox2.Text + "','" + textBox3.Text + "','" + textBox4.Text + "','" + result1 + "','" + result2 + "','" + result3 + "','" + comboBox1.SelectedItem + "','" + comboBox2.SelectedItem + "',0,0,0,0,0,0,0,@IMG)", Conexiune.getConnection());
com.Parameters.Add(new SQLiteParameter("@IMG", imageBt));
com.ExecuteNonQuery();
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
Code for image selection:
try
{
OpenFileDialog dlg = new OpenFileDialog();
dlg.Filter = "JPG Files(.jpg)|.jpg|PNG Files(.png)|.png|All Files(.)|.";
if (dlg.ShowDialog() == DialogResult.OK)
{
string picLoc = dlg.FileName.ToString();
textBox5.Text = picLoc;
}
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
|
|
|
|
|
I don;t see you loading anything in the picturebox, but I do see a SQLite database being opened. Is the connection opened correctly?
You would start by showing not "ex.Message", but "ex.ToString()", as that will also include a hint as to "which" code went wrong.
You should also read up on SQL-injection, as that is one of the worst ways to build a SQL-statement. It is hard to read, hard to maintain, and it is a security issue.
When done, check out what a using-clause is. That way your connection and command would be disposed when done.
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
|
|
|
|
|
Start by assuming TextBox5 contains no text, and your error should appear - so the most likely thing is that your user pressed Cancel instead of selecting an image, or that code was never called. So check - if it's empty, don't continue.
But...there are other problems here, from the trivial:
Why do you think you have call ToString on a string? What do you expect that to do?
string picLoc = dlg.FileName.ToString();
To the very serious: Do not concatenate strings to build a SQL command. It leaves you wide open to accidental or deliberate SQL Injection attack which can destroy your entire database. Use Parametrized queries instead.
You are clearly aware of the existence of parameterized queries and how to use them, but you leave your code wide open to anyone with a keyboard and your application anyway? Why? Do you not like your data?
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
|
|
|
|
|
Sincer am luat acel cod de pe youtube. So, I'm sorry if is wrong, but I need to upload a photo in table with sqlite..I will try do to what you said, what can I say. And about conection, I have a class where I have the connection and a function that returns connection, this way is better than to open it and close it on every time you need it. Thank you
|
|
|
|
|
I'm sorry, but could you try that again but in English this time?
That makes no sense to me at all!
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
|
|
|
|
|
Sorry, I wrote that very quickly and I was thinking at something else in the mean time )))) It's ok, I solved it
|
|
|
|
|
Dear All,
Kindly let me know the code and and steps for create SMS sending program by using C#.net via my GSM dongle that connected to Laptop. I'm new to this field and as a student still studying so I'm expecting your favorable response..
Thank you.
|
|
|
|
|
|
|
Hi all,
I'm new with C# and I need your help to start my new way.
I want to create C# form that get server address from user and start query and modify the remote server (Linux\Unix).
I looked up in the web and find staff related to RPC and REST.
is this the right diraction ? if yes is there a open source of RPC or REST servers for Linux\Unix ?
Thanks in advance,
Eldad
|
|
|
|
|
Whichever way you decide to go, you will need a client process running on the remote server. You cannot directly modify Linux/Unix systems this way. You would be better looking into one of the remote shell applications such as Putty or SCP.
|
|
|
|
|
If the Linux machine has a webserver and is running webservices, then yes, you can "invoke" the webservice. The term query rather implies a database-server, for which you'd use a specialized data-provider, just as under Windows.
As for Open Source; if you have Mono installed with some webserver (like Apache) then you have all the components required to create and invoke webservices.
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
|
|
|
|
|
Hi Eddy,
Tnx for your answer.
I think I didn't expline my self properly.
I want to make a cross platform connection class that will fit windows,Linux and FreeBSD hosts type and then execute remote command and return the command RC and stdout or stderr.
my current project run over ssh but I want to adjust it to windows host also.
do you think mono will be appropriate solution for me ? I must use webservice to work with mono ?
Thanks in advance, Eldad
|
|
|
|
|
elza63 wrote: my current project run over ssh but I want to adjust it to windows host also. Windows supports SSH. It is based on TCP/IP, which is cross-platform; it is what makes the internet work.
elza63 wrote: do you think mono will be appropriate solution for me ? I must use webservice to
work with mono ? You're not required to use webservices; again, depends on what you want to communicate with. I'm using Putty as a client, works nicely under Windows.
I was assuming you'd want to use C# to write your application; under Linux, that would imply using Mono. I'm not sure whether the SSHNET[^] library works under Mono, but you could give it a try.
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
|
|
|
|
|