|
Got this web application that lets a user create a form which is written to an sql database. It contains various textboxes and dropdownlists etc. It creates the form no problem but when it comes to updating this form i do. First off the user searches for their form.
Once found they click update, which retrieves all the info stores this in a session and returns the appropriate text to the appropriate control eg. if conor was the name of the user in the database the application would set the text attribute of the username control to conor.
the user is able to modify these controls again and click on update. Here is the problem. once the update button is clicked no event take place so the updates are not being saved to the database.
If i get this sorted it's the end of my project so it will greatly appreciated if anyone can help me.
|
|
|
|
|
mcgannmcgann wrote:
Here is the problem. once the update button is clicked no event take place so the updates are not being saved to the database.
Is the button dynamically generated ? Have you defined an event for it ?
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
Can someone teach me how can I begin writting one simple appliaction which can read barcodes...
Regards
|
|
|
|
|
In this website there are an example about barcodes and examples
Try this one:
“VBScan barcode software
by demm”
If you just want to input the values throw the scanner it work like a second keyboard, set focus to the location and scan.
|
|
|
|
|
Hi All,
using Vb.Net i want to connect to internet and send a mail programatically . can any body give me some guidelines?
regards
sumedha
|
|
|
|
|
Dim Message As System.Web.Mail.MailMessage = New System.Web.Mail.MailMessage
Message.To = "<to-emailid>"
Message.From = "
|
|
|
|
|
ciacia wrote:
send a mail programatically
using the solution of the guy above
ciacia wrote:
i want to connect to internet
using HttpWebRequest/HttpWebResponse (I dont remember exactly the namespace)
<< >>
|
|
|
|
|
Ok, my situation is like this. I have two forms in my application (Form1 and Form2), and on each form, I have one button (button1). I put the following code in button1 for Form1.
"Dim frm2 as new Form2"
"frm2.show()"
and in Button1 of Form2
"Dim frm1 as new Form1"
"frm1.show()"
I noticed that if I clicked on these buttons a couple of times, multiple Form1 and Form2 gets created. Anyway to avoid this, like maybe when I click Form1 Button1, it closes the Form1 and opens Form2 and vice versa..?
|
|
|
|
|
icowa wrote:
when I click Form1 Button1, it closes the Form1 and opens Form2 and vice versa
I think u dont need to close form1 and open form2 and vice versa...
u can let 2 forms are opened concurrently.
below is just my suggestion:
- In each form, u have a variable (boolean), named as isActive to store the status of the other form (this will be initialized as false, that means form2 is not activating),
ie: when click form1 button1, the code should be as below:
"Dim frm2 as new Form2"
"if isActive then " //form2 is being actived
" frm2.active()"
"else " //form2 has not been showed yet
"isActive = true"
"frm2.show()"
and certainlly, before form2 is closed, u need to set isActive = false in form1
and do the same thing for form2
<< >>
|
|
|
|
|
I'm not sure if I got it correctly.....
if you want to have a single form1 and form2 then the solution is not to re-declare them inside the procedure but just once at the beginning of the code. Thay way you are going to recall always the same one without creating a new instance.
|
|
|
|
|
How do you go about doing that? Any help that you can offer will be greatly appreciated... Thanz
|
|
|
|
|
My point is to move the declaration outside the form.
A way of accomplishing it could be the following.
Create a module with a Sub Main (it has to be the starting sub of the project
Module xyz
public F1 as new Form1
public F2 as new Form2
public sub Main
F1.Show
while F1 is not nothing
application.doevents()
wend
end sub
and then for each form/button event
private sub Button1_Click(..)
F1.Hide (F2.Hide in the other form)
F2.Show (F1.Show in the other form)
end sub
Remember to unload Form1 to end the application
|
|
|
|
|
what command do you use to unload a form?
|
|
|
|
|
Just issue the close method over the form. It'll be closed (passing through the closing and close events) and then destroyed.
|
|
|
|
|
Hello again friends!!
I've a fairly simple problem w/c im unfortunately stuck at. Well, i'v 2 forms. form1 is the main page which shows some companies' names as a link. form2 is the page which allows you to edit, update and/or delete the given company. now here's my problem...everything works fine except for my date picker. Upon clicking my "setdate" button it shows the calendar and actualy sets the coresponding text box with the date you pick but when i try to save the form the date doesn't save at all. everything else including the company name, adress, tel number, etc is saved accordingly only the textbox with the date picked is not. Any ideas why not? here's my query on insert:
Public Function fInsert(ByVal strName As String, ByVal strID As Integer, ByVal strInbound As Integer, ByVal strOutbound As Integer, ByVal strDstart As String, ByVal strDend As String, ByVal strRemarks As String)
Try
strSQL = "Insert into Splits"
strSQL += " (SplitID, SplitName, Inbound,"
strSQL += " Outbound, DateStarted, DateEnded, Remarks)"
strSQL += " Values ('" & strID & "',"
strSQL += " '" & strName & "',"
strSQL += " '" & strInbound & "',"
strSQL += " '" & strOutbound & "',"
strSQL += " '" & strDstart & "',"
strSQL += " '" & strDend & "',"
strSQL += " '" & strRemarks & "')"
Dim cmdInsert As New OdbcCommand()
cmdInsert.CommandText = strSQL
cmdInsert.Connection = cnn
cmdInsert.ExecuteNonQuery()
Catch e As OdbcException
Throw e
End Try
Return True
End Function
Tanx so much!
Kampai!!!
-- modified at 3:03 Thursday 15th September, 2005
|
|
|
|
|
hi,
i think you should use ToDate convetion like Format or sonthing which you normaly use for database i use Format statement...... otherwise change that StrDStrart to a datetime format and then try to save in database instead of string .....
regards
ciacia
|
|
|
|
|
good call! thanx so much for the assistance!
Kampai!!!
|
|
|
|
|
Has anyone tried using the API NetSessionDel in VB.Net? I haven't had any success in my attempts so far - but I'm still not sure that I have the declaration correct.
Is there another method of deleting a user's session on a share?
Thanks in advance,
Paul.
|
|
|
|
|
I defined a Procedure
Public Sub SetDBConf(ByRef CN as ADODB.Connection)<br />
CN.Provider="Microsoft.JET.OLEDB.4.0"<br />
CN.Properties("Data Source")="[path to mdb file]"<br />
CN.Properties("Jet OLEDB:Database Passowrd")="Password"<br />
End Sub
When I call this procedure
Dim myCN as New ADODB.Connection
SetDBconf myCN
This procedure produces type mismatch error. How can I resolve it.
Shoaib Nawaz
|
|
|
|
|
HI,
I Have made a small change in you code . you initialize the ADODB object in called procedure insted of calling procedure.
here is the code
calling procedure
Dim CN As ADODB.Connection
Call SetDBConf(CN)
and
Public Sub SetDBConf(CN As ADODB.Connection)
Set CN = New ADODB.Connection
CN.Provider = "Microsoft.JET.OLEDB.4.0"
CN.Properties("Data Source") = "c:\frmmain\pathsoft.mdb"
CN.Open
MsgBox "opend"
End Sub
i think this will solve your problem......
bye
Regards
ciacia
|
|
|
|
|
suppose i want to connect to a site through ftp over SSL.how could i do it. i have downloaded many
source code for ftp, they work fine but can not connect to a specific site becasue those code
can not connect to that ftp site through SSL.so pls tell me how could i solve this problem
or give me few url from where i can download free cost advance ftp library which comes with all
the advance ftp feature.pls help me out.
tbhattacharjee
|
|
|
|
|
|
sir first of all thanks for ur response but my ftp problem is not solved. according to you i download the library for ftp over ssl but ftp client has only function for connection to remote server but i want that library should have function like filelist,uploadfiles,downloadfiles,rename,remove etc.so this type of feature was not, so if u know any other better solution then please help me.
tbhattacharjee
|
|
|
|
|
suppose at specific time or at specific time of sunday and monday a function will be called.
pls help me with sample code or give me a url from where can download free cost scheduling
library.i have download few library for scheduling but those are useless.so pls help me.
tbhattacharjee
|
|
|
|
|
have u tried this?
http://www.codeproject.com/csharp/taskschedulerlibrary.asp
|
|
|
|