|
Dear All,
i am VB.Net User with Visual Studio.Net i want to genrate a project for FM Radio. They have some secrete MP3 files. So, they want to store them in there Data Base.
Dear All my Question is that how can i do that Using Visual Studio with Visual Basic.Net. If Someone has complete knowledge about this so plz help me.
Waiting for ur reply
Abdul Rouf
|
|
|
|
|
storing bulk data is always the same, whether it is one image, one movie, one audio track.
CodeProject has lots of entries on storing images, and so does Google.
|
|
|
|
|
They (you) really want to store the MP3s in the DB? Personally I prefer to store them in the file system and then store meta-data about the files in the DB (ie: keywords, title, musician, etc...) along with the storage location in the file system.
|
|
|
|
|
Hello To all
I have a text box that displays the date and it work my problem is it dont change when the date changes to the next day ??
here is my code Textbox1.text is the text box with the date in it
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Timer1.Enabled = True
TextBox1.Text = Format(Now, "M")
Timer1.Interval = 60000
Timer1.Start()
Thanks everyone for your help
everyone has been grate here
Bob
|
|
|
|
|
Ask yourself when and how often does Form1_Load execute.
|
|
|
|
|
Thanks Luc i shold have no that hehe
Thanks to good pepole like your self
pepole like me can lern vb
This is what i did to fix it and it seems to work
Private Sub Timer2_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer2.Tick
TextBox1.Text = Format(Now, "M")
End Sub
Thanks agine for every one help
|
|
|
|
|
I want to create "views" of a web page, to do that I´m retrieving and editing the html code to show what I want in a new small webbrowser:
Dim PageHTMLBytes() As Byte
Dim htmlText as string = ""
PageHTMLBytes = webClient.DownloadData(url)
' Convert result from byte array to string
Dim utf8 As New UTF8Encoding()
htmlText = utf8.GetString(PageHTMLBytes)
...
-Edit of the html code-
...
miniWebBrowser.DocumentText = editedhtmlText
The problem is that one part of the editedhtmlText I´m showing, is a flash object which checks if you are logged in, but it doesn´t matter if I logged before, as soon as I set my own, edited code, the session is lost. I tried setting cookies like this:
Dim request As HttpWebRequest = WebRequest.Create("http://www.cam4.com")
'Set cookies.
request.CookieContainer = New CookieContainer()
request.CookieContainer.Add(New Cookie("user", "usuario1", "/", url))
request.CookieContainer.Add(New Cookie("password", "password1", "/", url))
Dim response As HttpWebResponse = request.GetResponse()
Dim reader As IO.StreamReader = New IO.StreamReader(response.GetResponseStream(), True)
Dim html As String = reader.ReadToEnd()
web.DocumentText = html
..which throws no errors but no luck at all in keeping my session. I started to fiddle about with webrequest and responses instead of downloading the html code, but I couldn´t go much further.
I´m on Windows XP 32 bits, VB 2008 Express, Net. Framework 2.0 SP1 (for legacy support). Some assistance on how can I aboard this problem will be appreciated.
|
|
|
|
|
|
Hi all
I am creating a program in which I am executing a bach file, which requires a "Enter key" hit to execute, as below :
Dim prc As New Process
With prc.StartInfo
.FileName = "e:\abc.bat" 'batchfile to execute
.UseShellExecute = False
.RedirectStandardInput = True
End With
prc.Start()
prc.StandardInput.WriteLine("{enter}")
prc.Close()
Now the above code run successfully and it appears a command prompt window showing "e:\abc.bat" file is executing but the code
prc.StandardInput.WriteLine("{enter}") is not redirecting enter key to completely execute the batch file.
How can I use "Enter key" hit on that command prompt window in vb.net.
Thanks.
Gagan
|
|
|
|
|
Lookup Console/StandardInput.ReadLine() or .ReadKey() and test for enter.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
Thanks Henry for your suggestion but I have already tried these methods and there is no effect when a command window appears showing "abc.bat" is running.
I only want to do that when my batch file start executing, it takes a "Enter key hit" from program to completely execute my batch file(because it requires a Enter key hit for further execution)and not wait for hitting Enter mannually from user.
Suggest me how can I do that.
Thanks.
Gagan
|
|
|
|
|
Hi,
I hava piece of code which creates a networl drive on the user's system. I need to hide the network.
The purpose of doing this is that the user while using an application need to connect to the Access db on a file server. But shouldn't know that the drive is mapped onhis computer.
Thanks
Sanjeev
Sanjeev
|
|
|
|
|
I may be misunderstanding your problem but doesn't the standard Data Source parameter accept a URI - ServerMachineName\PathOnServer.mdb?
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
Then don't map the drive. Use the UNC path that the map points to instead.
|
|
|
|
|
I have one form in which I am searching the database table as :
cmd = New SqlCommand(" SELECT * FROM client_details WHERE DateofJoining BETWEEN #" + ddfrm + "# AND #" + ddto + "# ")
con.Open()
where, "client_details" is my database table name. And "DateofJoining" is a column.
In 2nd form, I have a datagridview, in which I have stored the data with several columns.
I want to get the number of rows from the updated datagridview in 2nd form using the filtered criteria which I did in my 1st form above.
I am trying but not able to update the datagridview using the filter.
Do i need to call any public function in 2nd form from the 1st form?
|
|
|
|
|
Yes.Make it as a Public Function in form1 and then call it from form2.
|
|
|
|
|
hi,
was wondering if it is possible to code a program to "right click" / bring up context menu for a file.
so to be a little less vague;
i have heaps of templates (win word, excel...), you right click and select "New"
which opens the respective office app with the template loaded into a fresh doc.
how could i do this programatically, rather that simply opening the file through vb or doing it manually?
apologies if this has already been answered, i have searched for it
-N
|
|
|
|
|
Right click on what?
There is an article around with global keyboard and mouse hooks I saw recently.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
|
Yeah but you must be viewing the list of templates in something, explorer presumably!
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
Hi, Friends
How I can Edit My Image In Databsae?
With Command Sql("Update Tabal Set ... ")
Thank You.
modified 3-Aug-12 18:22pm.
|
|
|
|
|
There are a number of good articles [^]in this lot.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
write a windows application that allows the user to enter a seven-digit number in a multiple line textbox when the user clicks the generate words button.
<br />
<br />
Public Class Form1<br />
Dim digits As Integer() = New Integer(6) {}<br />
Dim letters As String(,) = New String(,) {{" ", " ", " "}, _<br />
{" ", " ", " "}, {"A", "B", "C"}, {"D", "E", "F"}, _<br />
{"G", "H", "I"}, {"J", "K", "L"}, {"M", "N", "O"}, _<br />
{"P", "R", "S"}, {"T", "U", "V"}, {"W", "X", "Y"}}<br />
<br />
Dim phoneNumber As Integer<br />
Dim Number As String<br />
Dim OutPut As String<br />
<br />
<br />
Private Sub GenerateButton_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles GenerateButton.Click<br />
<br />
phoneNumber = Convert.ToInt32(Number)<br />
<br />
For i As Integer = 6 To 0 Step -1<br />
digits(i) = phoneNumber Mod 10<br />
phoneNumber \= 10<br />
' MessageBox.Show("Number = " & Str(phoneNumber))<br />
<br />
For loop1 As Integer = 0 To 2<br />
For loop2 As Integer = 0 To 2<br />
For loop3 As Integer = 0 To 2<br />
For loop4 As Integer = 0 To 2<br />
For loop5 As Integer = 0 To 2<br />
For loop6 As Integer = 0 To 2<br />
For loop7 As Integer = 0 To 2<br />
OutPut &= String.Format("{0, -10}", _<br />
letters(digits(0), loop1) & _<br />
letters(digits(1), loop2) & _<br />
letters(digits(2), loop3) & _<br />
letters(digits(3), loop4) & _<br />
letters(digits(4), loop5) & _<br />
letters(digits(5), loop6) & _<br />
letters(digits(6), loop7))<br />
Next<br />
Next<br />
Next<br />
Next<br />
Next<br />
Next<br />
Next<br />
Next<br />
<br />
End Sub<br />
<br />
<br />
Private Sub PhoneNumberTextBox_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles PhoneNumberTextBox.TextChanged<br />
Number = PhoneNumberTextBox.Text<br />
End Sub<br />
<br />
Private Sub PhoneNumberWordsListBox_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles PhoneNumberWordsListBox.SelectedIndexChanged<br />
OutPut = PhoneNumberWordsListBox.Text<br />
End Sub<br />
End Class<br />
but I couldn't output the words can some one help me please.
thanks
|
|
|
|
|
This looks like a mess, I don't see how you expect it to work. You have nested loops, which means each inner loop will run completely for each iteration of an outer loop. That makes sense only if you're building a list of strings that way, not outputting as you go.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
I'll give you a clue, to get you started.
Dim numberToWord As New Dictionary(Of Integer, string)
numberToWord.Add(0, "Zero")
numberToWord.Add(1, "One")
numberToWord.Add(2, "Two")
numberToWord.Add(3, "Three")
numberToWord.Add(4, "Four")
........
........
or since the user enters the number as text you could do it as:
Dim numberToWord As New Dictionary(Of Char, string)
numberToWord.Add("0"C, "Zero")
numberToWord.Add("1"C, "One")
numberToWord.Add("2"C, "Two")
numberToWord.Add("3"C, "Three")
numberToWord.Add("4"C, "Four")
........
........
Look up anything you don't understand on MSDN or Google it.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|