568 Posted Topics

Member Avatar for dilse4sk

ok lets assume you have a form , have so many controls , and a datetimepicker , now you want to save records of the current date , and restrict user to save records of past date , then you can do like this . [CODE] if datetimepicker.value.date.tostring() < now.date.tostring() …

Member Avatar for dilse4sk
0
277
Member Avatar for dilse4sk

i cant get your point , but for getting id , you can get the max id by using datareader and then +1 and show it to your textbox.it is very simple.now can you please little bit explain your point. do you want to create whole form consisting of textboxes …

Member Avatar for dilse4sk
0
187
Member Avatar for Farhan_B

i think you have to use the where clause instead of having .just for your information WHERE is used to filter rows. HAVING is usually used to filter rows after performing an aggregation.now in your case you are filtering rows and want to showrecords those fulfil your criteria . you …

Member Avatar for M.Waqas Aslam
0
208
Member Avatar for dilse4sk

well , it is much better if you tell us about the column of your grid , now lets assume you have two columns in your gird column 1 is roll no and column two is name , now we gernate a email like this , hello! this is auto …

Member Avatar for dilse4sk
0
2K
Member Avatar for dilse4sk

yes you can do like what saleem says , but tell me how you are getting the rate of the product , ? then we are able to provide you useful code . Regards

Member Avatar for P.manidas
0
973
Member Avatar for dilse4sk

in this code you are just dealing with customer table , just you should have one thing always in your mind , always first delete the related record then the main records , for example we have a customer name ali , now we also have 3 records in table …

Member Avatar for M.Waqas Aslam
0
169
Member Avatar for huskarit

you can simply do this like this [CODE] 'Can only accept future dates(from today to the future, not the past) if datetimepicker.value.date >= now.date() then ' if true then code here else 'if false then here end if 'Can only be AFTER departure date if datetimepicker.value.date > departuredate then 'true …

Member Avatar for laxmanpathare
0
1K
Member Avatar for saleem.mukhtiar

just change your query with this. [CODE] sql = "select * from tblSchdule where CheckIn between '" & DateTimePicker2.Value.ToShortDateString() & " and '" & DateTimePicker2.Value.ToShortDateString() & "'" [/CODE] Regards

Member Avatar for adam_k
0
98
Member Avatar for saleem.mukhtiar

well , you can do this by declaring a global variable , named invoiceno , and then get the value of invoice from the grid and use that value at the new form load event , for example you have two forms , frmchoose , frmshow, and a global variable …

Member Avatar for saleem.mukhtiar
0
205
Member Avatar for poojavb

i cant get you pooja , what do you mean by instance , well if you just want to know is * is in text file ? please check this attachment. Regards

Member Avatar for Mitja Bonca
0
198
Member Avatar for huskarit

here is an idea sample code , not tested and not the best solution. [CODE] 'lets take for loop . now do this dim buttonclick as boolean = false dim i as integer for i = 0 to 100 while buttonclick= false end while next 'and use this code at …

Member Avatar for Reverend Jim
0
4K
Member Avatar for M.Waqas Aslam

hello ! how are you all , hope all of you are in great state of health and peace , well i have some questions , 1- WHAT IS MSSQL TRANSACTIONS . 2- where we use it. 3- Advantages /Disadvantages 4- Any imp information or point which you think it …

Member Avatar for M.Waqas Aslam
0
342
Member Avatar for obwills
Member Avatar for dilse4sk
Member Avatar for M.Waqas Aslam
0
194
Member Avatar for Denden17

please mark this thread solved , as you get the answer. so that others may find it helpful and they saved their time. Regards

Member Avatar for Mitja Bonca
0
127
Member Avatar for Farhan_B

you have to use simple head detail concept or you can call it master detail concept . now here is a sample layout of your master - detail or head- detail tables head/master table 1- headid PK 2-orderdate 3-orderid- 4-customerid detail table 1-detailid PK 2-headid FK 3-productid 4-qty 5-rate 6-total …

Member Avatar for Reverend Jim
0
128
Member Avatar for BeeKeeper18
Member Avatar for Reverend Jim
0
356
Member Avatar for metagoth
Member Avatar for choboja621

i think this is your second thread you are posted for same question , please DO NOT ask any question more then once . Regards

Member Avatar for M.Waqas Aslam
0
78
Member Avatar for darthswift00

please be more specific , there is not that much time to read your all code , please tell me where you have prob and what you really want to do Regards

Member Avatar for darthswift00
0
146
Member Avatar for dilse4sk

you have to connect both laptops , one laptop have db server , and one has just your application , make users , and assign user roles , then just get the data of any kind inserted deleted , etc of specific user. Regards

Member Avatar for M.Waqas Aslam
0
141
Member Avatar for bernardz26

well bernardz26! there are two simple ways to perform this , one is to declare a global or public variable and just access it at any part of your prog , and second way is to call the form then the call the control , here are both ways to …

Member Avatar for Mitja Bonca
0
110
Member Avatar for remya1000

if it is working then please mark this thread solved so that other people can also visit it for answer .. Regards

Member Avatar for M.Waqas Aslam
0
609
Member Avatar for choosechrist

can you please tell me , this listview is also at the same form where you are inserting some data in your db , if yes then just place the same code which you used to show values in your listview just after the code you are using to save …

Member Avatar for M.Waqas Aslam
0
288
Member Avatar for dilse4sk

as adam_k said , it is better to use view or query to get sum of total payment. this is fast way to generate the reports, well you can also use group by and get sum of payment in your reporting tools , for example crystal reports , telerik reports …

Member Avatar for M.Waqas Aslam
0
228
Member Avatar for bernardz26

please be more specific about your requirement , explain your prob , in order to get good and quick solution. Regards

Member Avatar for M.Waqas Aslam
0
130
Member Avatar for M.Waqas Aslam

hello! i have shifted my application from mssql server 2000 to mssql server 2005 , now the prob is the command object is not returning the recordset if command text is stored procedure , here is my code please check it and guide me through errors . [ICODE] dim cmdsp …

Member Avatar for BitBlt
0
235
Member Avatar for collin_ola

hye , is in this thread you are asking some new question , [URL="http://www.daniweb.com/software-development/vbnet/threads/417441"]http://www.daniweb.com/software-development/vbnet/threads/417441[/URL] this is also your thread and you ask here same question , please do not post single question multiple time ,

Member Avatar for M.Waqas Aslam
-1
536
Member Avatar for shilpanayar

your code will look like this . use this code at the click event of your list box. [CODE] listbox2.items.add(listbox1.selecteditem) [/CODE] Regards

Member Avatar for Jx_Man
0
126
Member Avatar for george8

well i am working in mssql , so i am writing this code for mssql , but u can change the sqldataadapter with oledbdataadapter etc , and if this code not solve your prob then it will surly give you an idea . [CODE] 'code for department combo dim con …

Member Avatar for george8
0
215
Member Avatar for Denden17

well , there is another way to do this , for example if you save record of a person save the date of that saving in db ,now at every time before saving it first check it whether the last date and the current date has the difference of 15 …

Member Avatar for Begginnerdev
0
145
Member Avatar for Om Alooi

well answer of your first question is , you just add a button in toolstrip and set the background image or image property and select the image .it will set the image to the backgroud of your button 2-answer of your second question is use tabcontrols , select it from …

Member Avatar for Begginnerdev
0
181
Member Avatar for bernardz26

well i dont know what is the prob with this code but here is a code of insert . [CODE] dim con as new sqlconnection("connection string ") dim cmd as new sqlcommand con.open() cmd.connection=con cmd.commandtext="insert into table1 (id) values ("& txtid.text &")" cmd.executenonquery() con.close() [/CODE] this will insert your records …

Member Avatar for M.Waqas Aslam
0
89
Member Avatar for dilse4sk
Member Avatar for dilse4sk
0
121
Member Avatar for Farhan_B

hello ! check this [CODE] "UPDATE cg_security_user_right SET user_id=@user_id, right_id=@right_id ,enable_flag=@enable_flag WHERE LastName= " & tuser.Text & " right_id = " & tright.Text & " enable_flag = " & CheckBox1.Enabled & "" '@name they are the variables and you can also replace them with you textboxes or using command parameters …

Member Avatar for cyberdaemon
0
363
Member Avatar for bernardz26

ok you can do like this [CODE] dim con as new sqlconnection("connection string") dim cmd as new sqlcommand con.open() cmd.connection= con cmd.commandtext="insert into table1 (field1) values ("& combobox1.text &")" cmd.executenonquery() con.close [/CODE] you can use this code at any button click event to save the value of combo in db …

Member Avatar for M.Waqas Aslam
0
122
Member Avatar for venky.skcet

what you had done so for ?? , please show some efforts then we will help you in this.

Member Avatar for M.Waqas Aslam
-1
101
Member Avatar for poolet25

well please try this code [CODE] dim con as new sqlconnection("connectionstring") con.open() dim da as new sqldataadapter("select * from table",con) dim dt as new datatable Date.fill(dt) datagridview1.datasource = dt [/CODE] this will solve your prob :) Regards

Member Avatar for poolet25
0
5K
Member Avatar for M.Waqas Aslam

hello ! i want to get some information about LAN traffic . in my office there are 15 employees are there , we are connected with modem ,i want to moniter there activities for example which sites they are visiting,uploading , downloading . some one tell me about netstat but …

Member Avatar for JorgeM
0
265
Member Avatar for kingsonprisonic

hello ! please check these links , [URL="http://www.codeproject.com/Articles/34360/vb-net-AT-commands-to-send-SMS"]http://www.codeproject.com/Articles/34360/vb-net-AT-commands-to-send-SMS[/URL] [URL="http://www.computerhope.com/atcom.htm"]http://www.computerhope.com/atcom.htm[/URL] [URL="http://www.dialogic.com/support/helpweb/lasat/manuals/saf/Command/atlist.htm"]http://www.dialogic.com/support/helpweb/lasat/manuals/saf/Command/atlist.htm[/URL] [URL="http://www.sics.se/~bg/GC75-AT-Commands-R2A.pdf"]http://www.sics.se/~bg/GC75-AT-Commands-R2A.pdf[/URL] this will give you an idea , :) Regards

Member Avatar for kingsonprisonic
0
944
Member Avatar for Denden17

please check this thread , hope you will find any idea , [URL="http://www.daniweb.com/software-development/vbnet/threads/412558/1761197#post1761197"]http://www.daniweb.com/software-development/vbnet/threads/412558/1761197#post1761197[/URL] Regards

Member Avatar for Denden17
0
2K
Member Avatar for Naveed_786

it is very basic thing that your phone should connect to your pc in any way , you can use bluetooth , or some cable for this.

Member Avatar for Naveed_786
0
121
Member Avatar for roshu10

ok you can do like this , use a timer as king said , but do this [CODE] ' declare a variable dim myDelay as boolean = false 'now here is ur code AxWindowsMediaPlayer1.URL = "c:\vids\a.avi" AxWindowsMediaPlayer1.Ctlcontrols.play() 'start your timer here timer1.enable = true timer .interval = 5000 'use a …

Member Avatar for Gé48
0
157
Member Avatar for tendaimare

i think you should set your application form prop , show in task bar = false ,then use this code at the closing event of your form [CODE] System.Diagnostics.Process.Start("shutdown", "-s -t 00") [/CODE] this will shutdown the computer when somebody close your application , then when you built your application …

Member Avatar for Gé48
0
283
Member Avatar for bernardz26

for this declare a public variable , like this [CODE] public Name as string 'now place this code at the selected index change event name = combo.text [/CODE] now you can get name variable value at any place in your form, Regards

Member Avatar for chewmp
0
114
Member Avatar for khizer03

well you can do this [CODE] 'declare the variable name openNumber 'and use this code the form1 button click event If openNumber <= 2 Then Form2.Show() openNumber = openNumber + 1 Else MsgBox("your limit is ended") End If [/CODE] please see the attached file , hope this will solve your …

Member Avatar for codeorder
0
127
Member Avatar for shivya jain
Member Avatar for Pgmer
0
97
Member Avatar for M.Waqas Aslam

hello ! well today i got two down votes , i dont think that there is any thing wrong with my post , as we know who add reputation to us , can we know the person who is down voting us , and is there any way to balance …

Member Avatar for diafol
1
169
Member Avatar for easterbunny

you want to show the name of button or caption/text of button in msgbox when you click it ? please rephrase it .

Member Avatar for easterbunny
0
4K
Member Avatar for tendaimare

hello! you can save value of radio button by using radiobutton1.checked , and as you have prob which radio button is selected by the user , then there are two ways to perform this , 1- you can use two fields in your database , male and female , because …

Member Avatar for Mitja Bonca
0
141

The End.