652 Posted Topics

Member Avatar for saurabh.verma

Hi, Open the Second form in MODAL form: [code=vb] Form2.Show 1 [/code] Regards Veena

Member Avatar for saurabh.verma
0
78
Member Avatar for Sliders

Hi, Not sure, try this, change your code: listSeat.Items.Add(sr.ReadLine[b]( )[/b]) Regards Veena

Member Avatar for QVeen72
0
113
Member Avatar for tekrum

Hi, From VB6, just before Viewing the report, Set the DB location for each tables used in the report.. What is your Database..? Access/Oracle/SQL...? Regards Veena

Member Avatar for freshface001
0
84
Member Avatar for Rups``

Hi, Change your "Do--Loop" code to: [code=vb] Do While Not rs.EOF For j = 0 To rs.Fields.Count - 1 frmReport.MSGrid1.TextMatrix(HSE,j) =IIf(IsNull(rs(j)), "", rs(j)) Next j rs.MoveNext HSE = HSE + 1 Loop [/code] Regards Veena

Member Avatar for Rups``
0
534
Member Avatar for hell_tej

Hi, Use On Error Resume next: [code=vb] Dim sSQL As String On Error Resume Next sSQL = "Create Table EMP(ENo Number(10,0), EName Varchar2(50))" Conn.Execute sSQL [/code] Or, Check for the table name in "TAB" Collection.. [code=vb] Dim sSQL As String Dim RST As New ADODB.Recordset sSQL = "Select * From …

Member Avatar for hell_tej
0
89
Member Avatar for erikt

Hi, In Procedure, you Have not defined the OUT parameter.. Try this procedure: CREATE PROCEDURE FormatDate(OUT IDate Char(20)) BEGIN SELECT date_format(now(),'%d-%m-%Y') INTO IDate ; END; Regards Veena

Member Avatar for QVeen72
0
93
Member Avatar for swapna7999

Hi, When you are showing Form2 in Form1, dont unload it, Just Hide it.. and in form2, show form1 Code in Form1: Me.Hide Form2.Show Code in Form2: Form1.Show Regards Veena

Member Avatar for swapna7999
0
95
Member Avatar for wrichardson530

Hi, Chage Second part of your code to : [code=vb] PosOfSpace2 = InStr((PosOfSpace1 + 1), cboItems.Text, " ") txtItemValue = Mid(cboItems.Text, PosOfSpace2 + 1) [/code] Regards Veena

Member Avatar for QVeen72
0
101
Member Avatar for Pgmer
Re: Exel

Hi, Yes, MS Excel can be used as a Database, You can connect it with ADO with the following Connection sring: "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\MyExcel.xls;Extended Properties=""Excel 8.0;HDR=Yes;IMEX=1""" Regards Veena

Member Avatar for QVeen72
0
88
Member Avatar for swapna7999

Hi, Do you have the module..? if yes, then goto menu: Project >> Add Module Select "Existing", tab browse and add Regards Veena

Member Avatar for swapna7999
0
73
Member Avatar for laoballer

Hi, No Events are Fired when the Control is disabled.. But there is a way around, : Place a label on the Form (near to the command button) and in Form's Mouse Move, find the Pointer, if it is hovering over the disabled Command button, then, show the label (as …

Member Avatar for QVeen72
0
828
Member Avatar for dinilkarun

Hi, Collection has already a [b]Count[/b] property: [code=vb] Dim MyCol As New Collection MyCol.Add "First Item" MsgBox MyCol.Count [/code] What are you actually looking for...? Regards Veena

Member Avatar for QVeen72
0
91
Member Avatar for williamrojas78

Hi, I guess, you can use this : [code=vb] MsgBox("Selected Rows : " & DataGridView1.SelectedRows.Count.ToString()) [/code] Regards Veena

Member Avatar for williamrojas78
0
152
Member Avatar for lisheen

Hi, If you want to Jump to another form, Create a Public Procedure in the new Form, and call the Procedure, write the codes in the new proc. Once the code is executed, the excution point returns to the main form. in Second Form declarae proc like this: Public MyProc …

Member Avatar for sendoshin
0
300
Member Avatar for swapna7999

Hi, Write this Code in Main Form: [code=vb] Form2.Show Form2.txtNew.Text = Me.Text1.Text Form2.lblNew.Caption = Me.Label1.Caption [/code] Regards Veena

Member Avatar for swapna7999
0
76
Member Avatar for Yogesh Sharma

Hi Sonia, [QUOTE=sonia sardana;583050][B][B][COLOR="Red"]1) [/COLOR][/B]In VB,there is no insert ,update,delete statements as in VB.net. [/quote] WRONG... VB6 also supports all DML Statements Connection Object and Command Object has Execute Method, which can be any DML statement: [code=vb] Dim Conn As New ADODB.Connection Conn.Open <My Connection String> Conn.Execute "Insert Into MyTable …

Member Avatar for choudhuryshouvi
0
986
Member Avatar for drpaur

Hi, You have to maka a Set-Up file for your project (Using Package and Deployment Wizard) and Install on another system.. Make exe, copy Exe+Database on the the other system and run.. Regards Veena

Member Avatar for wrichardson530
0
165
Member Avatar for sam1

Hi, Try this condition : [code=vb] If Combo1.SelectedIndex = 0 Then ' Code to disable Else ' Code to Enable End If [/code] Regards Veena

Member Avatar for Jx_Man
0
119
Member Avatar for SpnIslander

[QUOTE=sonia sardana;582064] I want only Capital letters are allowed. But the error is coming,Plz help me to sort it out.[/QUOTE] Instead of Blocking Lower case chars, Convert the Lower case chars to upper case: [code=vb] Private Sub Text1_KeyPress(KeyAscii As Integer) KeyAscii = Asc(Ucase(Chr(KeyAscii))) End Sub [/code] Regards Veena

Member Avatar for cometburn
0
265
Member Avatar for Tekito
Member Avatar for msantosh18
Member Avatar for sonia sardana

Hi, A Function Declaration in VB6 is as : [code=vb] Private Function sum(a, b) As Double sum = a + b End Function [/code] Return is the same as Function Name..("Sum" in above case) Regards Veena

Member Avatar for choudhuryshouvi
0
214
Member Avatar for sonia sardana

[QUOTE=sonia sardana;582610]Hi,There is no tab of such name.[/QUOTE] Hi Sonia, In VB6 it is called [b]ToolBar[/b] and it comes with : Microsoft Windows Common Controls 6.0 Regads Veena

Member Avatar for sonia sardana
0
196
Member Avatar for rajeshkhanna_in

Hi, Create a Table with "OLE Field" and [b]Databind[/b] the OLE Control on the Vb6 Form to the field.. use a ataControl and ind it.. Add/edit/update /delete will be done automatically Regards Veena

Member Avatar for rajeshkhanna_in
0
145
Member Avatar for Jhakda

Hi, Not sure about this, but you can try.. Instead of Command object.. Try RecordSet object of ADO.. You can Open the recordset in [b]adLockBatchOptimistic[/b] mode (for the Dest DB) , disconnect it from the Database .. Now add all the records.. manipulate records.. and Then Reconnect it to the …

Member Avatar for Jhakda
0
563
Member Avatar for praveenakandhi

Hi, Check this link: [url]http://www.a1vbcode.com/app-3859.asp[/url] REgards Veena

Member Avatar for QVeen72
0
45
Member Avatar for rajeshkhanna_in

Hi, You need to save RichTextbox's "TextRTF" and then retrieve the same .. So all the fomatting is Intact.. REgards Veena

Member Avatar for QVeen72
0
167
Member Avatar for rrocket

Hi, Declare Events for the Connection: Write this at FormLevel : [code=vb] Dim WithEvents MyMsg As ADODB.Connection 'and collect the Events in event: Private Sub MyMsg_InfoMessage(ByVal pError As ADODB.Error, adStatus As ADODB.EventStatusEnum, ByVal pConnection As ADODB.Connection) MsgBox pError.Description End Sub [/code] I have not used, but it is done this …

Member Avatar for rrocket
0
86
Member Avatar for mukund_Sadrani

Hi, Reference a "Microsoft Access" Object library in your Project and try this code: [code=vb] Dim MyAcc As New Access.Application MyAcc.OpenCurrentDatabase "C:\MyDb.mdb" , True MyAcc.DoCmd.OpenReport "MyReportName", acViewPreview 'Open Form MyAcc.DoCmd.OpenForm "MyFormname" 'Quit access MyAcc.Quit Set MyAcc = Nothing [/code] Regards Veena

Member Avatar for QVeen72
0
154
Member Avatar for ITech

Hi, Try this : [code=vb] "Select CI.name,I.ServiceID,P.packagename,P.duration,P.price,I.date,I.timeIn,I.timeOut From CustInfo CI, InDate I, PakInfo P Where CI.CustID = I.CustID And I.ServiceID = P.ServiceID And I.Date Between #" & DtPicker1.Value & "# And #" & DtPicker2.Value & "#" OR " And I.Date Between CDate('" & DtPicker1.Value & "') And CDate('" _ & …

Member Avatar for jireh
1
284
Member Avatar for sonia sardana

Hi, Mastering Visual Basic 6.0 By Evangelos Peutrotsis All series of Teach Yourself VB6 By Sams Publications REgards Veena

Member Avatar for ladyjade
0
82
Member Avatar for Yogesh Sharma

[QUOTE=Yogesh Sharma;577908]HI, I have made a menu with two menu Items Colors Size. [B]But as u right click on The form in the Client Area, Its hows ViewCode MenuEditor[/B] .[/QUOTE] Hi, I guess, by "Client Area"...? You are talking about [B]Design Time[/B]...? Whatever Menu you have created is shown at …

Member Avatar for choudhuryshouvi
0
206
Member Avatar for ITKnight

Hi, Write this in FormLoad event: [code=vb] Me.MousePointer = 99 Me.MouseIcon = LoadPicture("C:\windows\cursors\3dgno.cur") [/code] Change the path accordingly Regards Veena

Member Avatar for Jx_Man
0
214
Member Avatar for Neji

Hi, One more Simple way: Add a [b]DriveListBox [/b] on the form and loop thru all the list items.. it lists all the drives Regards Veena

Member Avatar for Neji
0
148
Member Avatar for sonia sardana

Hi, You have to set the Property "MDIChild = True" @ design time. You cannot set it during run-time in VB6 Regards Veena

Member Avatar for sonia sardana
0
76
Member Avatar for ITech

Hi, After Selection of ComboBox, To filter out records use this query: "Select CI.name,I.ServiceID,P.packagename,P.duration,P.price,I.date,I.timeIn,I.timeOut From CustInfo CI, InDate I, PakInfo P Where CI.CustID = I.CustID And I.ServiceID = P.ServiceID And Month(I.Date) = " & (Combo1.ListIndex+1) & " Order By CI.Name" Assuming, Your ComboBox is not sorted and it is in …

Member Avatar for QVeen72
0
193
Member Avatar for ruchika beddy

Hi, UseMnemonic property of Label, when set to False, displays the Text as it is(With all the ampersands). This is very useful when the Label is Bounded to a Datasource on form. when False, It does not have a short cut key. When set to true, It behaves differently.. Say …

Member Avatar for ruchika beddy
0
147
Member Avatar for sonia sardana

Hi, Are Controls on your Form locked...? To unlock, Right-Click on Form (anywhere) and Click on menu :Unlock Controls Regards Veena

Member Avatar for sonia sardana
0
65
Member Avatar for denniskhor

Hi Sonia, To select an Item in ListBox, Which is in Textbox , use : [b]List1.Text = Text1.Text[/b] If text1.Text is found in the ListBox, That Item is selected/highlighted, or else, if not found then, No item in Listbox is selected.. Regards Veena

Member Avatar for Jx_Man
0
2K
Member Avatar for archangel

Hi, [b]ActiveForm[/b] refers to Active Child Form of the MDI Form. In your project make both the form's as Child of the mdi form, by seting [b]MDIChild=True[/b] Regards Veena

Member Avatar for QVeen72
0
161
Member Avatar for mansi sharma

Hi, Right Click on [b]Edit [/b] menu, and Check the [b]Edit[/b] Button Toolbar for edit is inserted in VB IDE Regards Veena

Member Avatar for QVeen72
0
95
Member Avatar for rrocket

Hi, I guess, you want the code for "DataList" box control..: add a "DataList" control on the form and set these Properties..: RowSource = ADODC1 ListField ="MyFieldName" BoundColumn = "MyFieldName" if you dont have ADODC, then @ runtime, you can open a recordset and set rowsource to that ADOrecordset Regards …

Member Avatar for QVeen72
0
263
Member Avatar for macka007

Hi, Say, you want to lock the Computer, if there is no activity for 5 mins continus.. then you need to have a Timer. Timer's Interval is 1000 ms(1 sec) By Default Timer is enable all the time. Declare a FormLevel Variable MyVar as Integer. Make Form's property Keypreview=True. In …

Member Avatar for QVeen72
0
182
Member Avatar for dragonheart

Hi DragonHeart, While Installing CR11, you need to Install with the [b]Developer Key [/b] not the designer/liscence key.. and there is no Report Control, You have a Report Viewer here. You need to add a CRViewer Control on the form, Prepare a report and View it.. [code=vb] Dim CrApp As …

Member Avatar for dragonheart
0
276
Member Avatar for ITech

Hi, In 6th line, you need CustomerInfo.AddNew (To add new data) You dont require that, if you are Editting the last record. And as Shouvik, said, Multi-step error is due to Field data type differences. It is always a good Idea to Set MaxLength property of the Textbox. Regards Veena

Member Avatar for QVeen72
0
96
Member Avatar for dinilkarun

Hi, the problem is, you have not mentioned Array's Index , Try this : col_values.add var_list1(2), "k" Also check Key (k) should be Unique in the Collection. What is the error..? Regards Veena

Member Avatar for QVeen72
0
89
Member Avatar for ITech

Hi, Check this code: [code=vb] Dim InDate As Date Dim NewDate As Date InDate = Format(txtIn, "hh:mm:ss") NewDate = DateAdd("n", Val(txtDur), InDate) txtOutTime = Format(NewDate, "hh:mm") [/code] Regards Veena

Member Avatar for QVeen72
0
87
Member Avatar for t_yalthis
Member Avatar for mariegomez84
Member Avatar for mariegomez84
0
979
Member Avatar for purplestar86

Hi Keep 2 Form Level Variables: Difference Shown is in Seconds Divide By 60 and Convert to Minutes. [code] Dim StartTime As Date Dim EndTime As Date ' Private Sub cmdStart_Click() StartTime = Now End Sub ' Private Sub cmdEnd_Click() EndTime = Now MsgBox DateDiff("s", StartTime, EndTime) End Sub [/code] …

Member Avatar for Jx_Man
0
254

The End.