|
you can use
<br />
Imports System.IO<br />
public sub RunSQL<br />
Dim conn As New SqlClient.SqlConnection<br />
Dim sqlCmd As New SqlClient.SqlCommand<br />
Dim sqltxt As String<br />
<br />
conn.ConnectionString = ("Data Source= " + DS + " ;Initial Catalog= " + DB + ";Integrated Security=True")<br />
conn.Open()<br />
<br />
sqltxt = System.IO.File.ReadAllText("SP.sql")<br />
sqlCmd.CommandText = sqltxt<br />
sqlCmd.Connection = conn<br />
sqlCmd.ExecuteNonQuery()<br />
conn.Close()<br />
<br />
this code will read the file once and execute it
|
|
|
|
|
Hi all,
i need to edit file on the target folder and this editing must run in Uninstalling this program
what exaclty shall I do?
|
|
|
|
|
In your setup project open up the Custom Actions Editor. Here you can specify other actions to do during installation or uninstallation. You'll have to make a new .exe to edit the file and place that .exe it in the Uninstall folder here.
|
|
|
|
|
i create new class that display warning message if he find string in text file and this code inside Sub of the class so
how can i call this function from the dll in the setup project while uninstall
Code :
<br />
Imports System.IO<br />
Imports System.Windows.Forms<br />
<br />
Public Class Uninstall<br />
Dim str As String<br />
Public Sub FixDynamics()<br />
str = System.IO.File.ReadAllText("Test.txt")<br />
If str.Contains("Auto") = True Then<br />
MessageBox.Show("Exist txt")<br />
End If<br />
<br />
End Sub<br />
-- modified at 3:26 Thursday 25th May, 2006
|
|
|
|
|
|
hi there,
we have to go front and back as there is option in web pages , can we accomplish in standalone application?
bharath.s
|
|
|
|
|
Are you referring to a windows app? If that's the case then you just set the button to load the appropriate form.
|
|
|
|
|
hi there, i wanted to have that navigating front and back option in windows standalone application. Can that be done?
bharath.s
|
|
|
|
|
hello, i want a form to show me a username i write in a textbox from a database. if i want to search for username: adrian a datagrid will contain all adrian usernames. how can i do this?? thanks alot for all of your help!
Adrian De Battista: .Net Programmer, Java Programmer and Web Designer.
|
|
|
|
|
You need to set up your SQL query to be something like this
strName = "adrian"
sSQL = "Select * from Table where username like '%" & strname & "%'
That search statement will get everything that contains adrian in the username.
|
|
|
|
|
hellow to all ..
i am looking for a code or a artical that can help me format textbox the way i like , for exsample , i wanna the textbox only to recive dig numbers and to attach "-" , after the 3d number ,,
thxx for anyhelp .
|
|
|
|
|
|
i deployed the VB.net program with crystal reports.
but a strange bug appear on client machine.
when the user open the crystal report, the data is printed and everything is fine but when he is scroll down or up, left or right... sudenlly the program become not response and freezed, and he should terminate and restart the application.!!!!1
Faris Madi
Nothing Comes Easy (N.C.E.)
|
|
|
|
|
Hi,
am looking for som1 who has already done or is doing work on "Software estimation tool" am using OP, FP and LOC as sizing techniques and for the remaining am working with COCOMO early-staged estimation, COCOMO II, and UCP's....coding wiz vb.net and SQL Server as back-end.
Thanx
Shai
|
|
|
|
|
Instead of using all the SMS-SPK and acronyms, why not try actually putting your question in full English. Your chances of getting any sort of answer will improve loads!!
Current blacklist
svmilky - Extremely rude | FeRtoll - Rude personal emails | ironstrike1 - Rude & Obnoxious behaviour
|
|
|
|
|
Hi can some1 help me out with vb.net codes for email addres validation with vb.net.
Thanx
|
|
|
|
|
Hi,
For this you can use RegularExpressionValidator.
Best Regards,
Apurva Kaushal
|
|
|
|
|
Hi, there!
As mentioned above you could use the RegularExpressionValidator control in a form, or you could use this function in your code:
Function IsValidEmailAdress(emailAdress As String) As Boolean<br />
Retrun Regex.IsMatch(emailAdress, ("\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"))<br />
End Function
Be sure to include System.Text.RegularExpressions in your class:
(Imports System.Text.RegularExpressions )
Good luck!
Best regards
j-on
|
|
|
|
|
|
Hi All,
I searched the net for applications that upload binary data files from client machine to server one.multiple clients can send at the same time.
All the samples i found works correctly if the size of the file is small ==> 1024 bytes or less only.
I need to make it work for larger files too. i don't have much experience in IO and Sockets issues
I can bring the code here.if any one can help me...
any comment will be very usefull..
Thanks in advanced..
shelal
shelal
|
|
|
|
|
It sounds like you're trying to create an FTP program. I remember seeing some sample FTP programs on Microsoft's site not that log ago. The basic idea is that the "server" will stay open at all times. When it starts you'll bind the app to a local unused socket. Then your clients will connect to that socket and a connection is created. All you have to do then is use the socket.send command with the correct parameters.
If you do a search for source code for an ftp server and ftp client you'll get a lot more examples. then you can customize it to fit your specific need.
|
|
|
|
|
thanks Leeland for your comment, but i should not use the ftp protocol.
i have just use sockets in vb.net...
|
|
|
|
|
how can i check if the date 28/5/2006 > date of today
|
|
|
|
|
hello amarni
u use this function
DateDiff()
this function help you.
thanks
vipin paliwal
|
|
|
|
|
Amarni wrote: the date 28/5/2006
Thats my Birthday!! 28 on the 28th
You didnt mention the language, but .NET allows you to compare 2 DateTime instances using the exact operator you used... >
<br />
DateTime jcBirthday = new dateTime(2006,5,28);<br />
DateTime today = DateTime.Now;<br />
<br />
bool isJCBirthdayInTheFuture = (jcBirthday > today);
Current blacklist
svmilky - Extremely rude | FeRtoll - Rude personal emails | ironstrike1 - Rude & Obnoxious behaviour
|
|
|
|