I want to insert module file in specific folder by module categories in VB.net
I want to insert module file in specific folder by module categories in VB.net
For example:
If "modul_category" = "OPTO" Then "@modul_filePath" values "notes/OPTO" * from "ModulContents" ElseIf
Is it correct? Or any suggestions? i want to call specific modules by their module categories only.
Full coding :
Protected Sub addSyllabusButton_Click(ByVal sender As Object, ByVal e As
System.EventArgs) Handles addSyllabusButton.Click
Dim myConnection As New SqlConnection()
Dim myCommand As SqlCommand
Dim str As String
Dim filepath As String = Server.MapPath("notes/")
'Dim filepath As String = "C:\Uploads"
Dim uploadedFiles As HttpFileCollection = Request.Files
Dim i As Integer = 0
Using myConnection
myConnection = New SqlConnection("server=mtmwhs;uid=private;pwd=private;database=elearning")
'you need to provide password for sql server
str = "INSERT INTO ModulContents (modul_name,modul_filePath,modul_vidPath,course_name,deptName,modul_status,modul_category,modul_file Name,modul_mediaName) values (@modul_name,@modul_filePath)"