2,155 Posted Topics

Member Avatar for xirosen
Member Avatar for amitash

You should try Google as your friend :) Try the following - Sub OpenExcelFile() Dim oExcel As Excel.Application Dim oWB As Workbook Set oExcel = New Excel.Application Set oWB = oExcel.Workbooks.Open("C:\Documents and Settings\MyExcelFolderHere\Import.xls") oExcel.Visible = True Set oWB = oExcel.Workbooks.Open(sPath) 'Rest of code End Sub To run a macro contained …

Member Avatar for Dieter123
0
499
Member Avatar for locsin

@zp18, start a NEW and your OWN thread by clicking [URL="http://www.daniweb.com/forums/newthread.php?do=newthread&f=4"]THIS[/URL] link. You will not get any help from members by hijacking others threads.

Member Avatar for yokoshima.mur
0
3K
Member Avatar for 2mhzbrain

This will make the connection for you. Change the detail as needed... Dim cnServer As ADODB.Connection Dim rsServer As ADODB.Recordset Set rsServer = New ADODB.Recordset Set cnServer = New ADODB.Connection cnServer.ConnectionString = "DRIVER={MySQL ODBC 3.51 Driver};" _ & "SERVER=MyIPAddressOfServerHere;" _ & "Port=3306;" _ & "DATABASE=MyDatabaseNameHere;" _ & "UID=MyServerUsernameHere;" _ & …

Member Avatar for ikocrush
0
928
Member Avatar for eukiandfhull

Are you using a data control or code to create your recordset? It looks like a data cobtrol, which I do not believe in because of its basic functionality.

Member Avatar for rishif2
0
527
Member Avatar for sshinde

Have a look at [this](http://mdn.morovia.com/kb/Printing-2D-barcode-fonts-Visual-Basic-6-10095.html) link with sample code. Also helpful - [here](http://www.idautomation.com/font-encoders/visual-basic/) or [this](http://www.barcodingfonts.com/pdf/bar93.pdf) link.

Member Avatar for asaa
0
3K
Member Avatar for santhakumar

sshinde, This thread is over 6 years old. I doubt that anyone will respond to your question. Please open a new thread with your question and as much info as possible. We will gladly help from there.

Member Avatar for Clintonzz
0
3K
Member Avatar for androidz

Your call to set the datasource of the grid is in the incorrect place. You are calling it whilst you expect there to be no records. [CODE]If rec_rs.EOF = False Then Set dbgrid.DataSource = rec_rs End If rec_rs.Close 'Change this to... Set dbgrid.DataSource = rec_rs ' irrespective of data or …

Member Avatar for Adrian779
0
1K
Member Avatar for jaai

Bad news, I know, but you will have to re-install vb6 and then start again. Save all your projects, un-install vb6 and then re-install. Good luck bud.

Member Avatar for darprogra
0
3K
Member Avatar for problematic:)

Update will be something like - [CODE]RS.AddNew RS!MyFieldNameHere = Text1.Text 'and so on.... RS.Update[/CODE] Delete something like this - [CODE]RS.Delete 'Use bookmark etc for a specific record etc...[/CODE] Search - [CODE]RS.Open "SELECT * FROM YourTable WHERE TheFieldName LIKE '" & Text1.Text & "'", cn, adOpenStatic, adLockOptimistic[/CODE]

Member Avatar for Mark Alonzo16
0
182
Member Avatar for Skate Bart

Lets presume that you are searching for a id in coloumn 1 of your grid - Dim xString As String, xRow As Integer, xNext As Integer xString = txtSearch.Text For xNext = 0 To mshFlexgrid.Rows ''Use -1 if you do not have titles in the first row and data starts …

Member Avatar for jamunadevi.v
0
1K
Member Avatar for haviansyah

Thank you for posting a tutorial here. :) You do however need to make sure that all of your code and setup data is correct... You have created 3 text boxes named nama, username and pass yet in your code you have Text1, Text2 etc. You have also closed your …

Member Avatar for jemartalaban_1
1
4K
Member Avatar for sidnei

@labq5, There are easier ways to make your form borderless. You do however need to open a new thread of your own. This was only a code snippet from 2009, I doubt it if anyone will answer your question. I'll reply on your new thread once it is open.:)

Member Avatar for anbarasan
-1
703
Member Avatar for ziphyx

I have ask that your post be moved to .Net. I'm sure someone over there will help. This is unfortunately vb4/5/6 forum.:)

Member Avatar for Mr.M
0
1K
Member Avatar for happygeek

LOL, and so they all train to come play REAL rugby against the Springboks and Aussies. We usauly do let the world sort themselves and then throw the challenge out there to come play real rugby. (OUCH - a few feet stepped on now, I know) ;)

Member Avatar for diafol
1
1K
Member Avatar for archangel1177

As far as my knowledge stretch, the msgbox can not accept pictures... That made me develop my own message box which works wonders. Below is some code you can use to create your own message boxes. You can add pictures to your hearts content... In a module, add the following... …

Member Avatar for AndreRet
0
290
Member Avatar for fx.eko

Ithink the part of creating a new report from CR is looking for files/want to save to files where you do not have access to. Which windows OS are you using? Do you have admin rights on that pc?

Member Avatar for AndreRet
0
2K
Member Avatar for jovstudios

a Lot of code which can be done in less lines using OOP. :) Try the following - eliminate LIKE in your statement and use the actual month selected. Because of LIKE you are getting other months as well because it contains characters that forms part of January... First off, …

Member Avatar for jovstudios
0
149
Member Avatar for Jake.20

Do you HAVE to use the datacontrol? If not, there is a much easier way by just looping through the records returned...

Member Avatar for Jake.20
0
149
Member Avatar for masterfact18

There are 2 ways to do this - 1. When your textbox looses focus, trap the error... If Not IsNumeric(Text1.Text) Then MsgBox "Numeric input only!", vbCritical, "Invalid Input" Text1.Text = "" End If OR, you can just delete the letter that was typed so it only accepts numbers... Private Sub …

Member Avatar for AndreRet
0
449
Member Avatar for jemartalaban_1

Your first question was answered. Please open seperate threads for the other 2 questions. It keeps the question and answers clear for future users. We can not allow multiple questions in one post. All other users, please answer OP's questions on his new posts and not here. Thanx.

Member Avatar for AndreRet
0
199
Member Avatar for jovstudios

This should work - acd.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=\\192.168.0.10\YourPCNameHere\POS.mdb;Persist Security Info=False" acd.CursorLocation = adUseClient Make sure that the database is under your c: drive, not in any folders. That will eliminate user rights... Also change the ip address to what you have for your server.

Member Avatar for AndreRet
0
143
Member Avatar for jovstudios

As per your new thread, your select statement was incorrect. Please correct to the sample I gave you there. If this is answered, please mark as solved, thanx.

Member Avatar for AndreRet
0
2K
Member Avatar for kimangel

If there is no code under the listview double click event, it will not do anything. If you want it to NOT do anything, remove the code from the double click event... On single click, remove the code that lets the user edit teh data... It seems that you have …

Member Avatar for kimangel
0
3K
Member Avatar for jovstudios

Change your select statement to - rsReport1.Open "Select purchase_date, BarCode, Price, ProductName, Quantity, TotalPrice From Dailyrecord where purchase_date = '" & DTPicker1.Value & "'", acd, adOpenStatic. adLockOptimistic

Member Avatar for jovstudios
0
184
Member Avatar for user777

ComputerHacker, firstly please read our posting rules. You need to open your own thread with your question/problem. This is a VERY old post that has been reraised from the dead, and normally we would not even reply on this. You are however a new poster, so I'll answer the basics, …

Member Avatar for AndreRet
-1
2K
Member Avatar for kimangel

The error means that rs has not been assigned. you need to set a new type for rs... dim rs as ADODB.Recordset Set rs = New ADODB.Recordset if that doesn't solve your problem, it lies with cn. do the same for cn...

Member Avatar for QVeen72
0
326
Member Avatar for dbellerue

> IIf(Nz([AnotherFieldName],0)=0,3,[AnotherFieldName]) I'm not sure what the above is for... In vb6, open connection. open recordset. code should look similar to this - If rs!Fieldname1 = rs!fieldname2 Then ''code here to handle returned boolean of true Msgbox "field1 is equal to field2" End If

Member Avatar for QVeen72
0
614
Member Avatar for jovstudios

I agree with you tinstaafl. When creating an application we think that it is running smooth, nothing will change. 6 months down the line the user wants additional features or something changed... It is so much easier to just work with blocks than entire pages of code.

Member Avatar for AndreRet
0
163
Member Avatar for kimangel

This is how I would've done it, I CONTROL the code then... Private Sub cmdSearch_Click() Dim sTrID As String Dim xTotal As Integer ''DO NOT USE TOTAL, IT IS A VB RESERVED WORD... sTrID = txtSearch.Text xTotal = 0 Set rs = New ADODB.Recordset rs.Open "Select Date_In, sTrID from Time_In …

Member Avatar for kimangel
0
304
Member Avatar for mfbi23681

What database, access, MySql, MSSql? What field names in table for dates? What code do you have thus far?

Member Avatar for AndreRet
0
52
Member Avatar for maytham
Member Avatar for aderogba08

Not exactly sure what you are asking here. :) Do you mean that when a textbox size is 2 cm long but you type "This is one veeeeerrrryyyy long text sentence, please fit in"you want the cursor to be at the end "fit in"?

Member Avatar for aderogba08
0
135
Member Avatar for Ancient Dragon

LOVED IT!! and shared, thanx ancient. All from MD5, Hash 1 - 100000237 to some personal credit card numbers, identity numbers, mothers name, dogs birth place and lastly the drop of virgin blood... :)

Member Avatar for vegaseat
4
242
Member Avatar for kayjenx

Are you using macros inside Access, Access itself as the report generator or are you using vb6 to do the reporting etc?

Member Avatar for tirror69
0
210
Member Avatar for archangel1177

What sheet do you need to search from - excel? If you have problems uploading, just post your search code here.

Member Avatar for archangel1177
0
182
Member Avatar for rishif2
Member Avatar for ahmad.aiman.35

Unfortunately we do not do others assignments here. Please see our posting rules. If you received an assignment with the requirements as stated, you should be fairly versed in vb6 already. You can use vb6 and databases. You can also use the reader to interact with your application in vb6.

Member Avatar for AndreRet
0
191
Member Avatar for silversurf

The problem is because you are referring to only the first coloumn - ListItems only returns the first. For any other coloumns after that you will need to call the SubItem as well... ListView1.ListItems(1).ListSubItems

Member Avatar for hyesin
0
1K
Member Avatar for rahul.gour

Youir error is here - > If .SubItems(19) = "Y" Then Your listview does not have a coloumn number 19 (20 - starts from 0), hence the error. Make sure you have the correct amount of coloumns...

Member Avatar for AndreRet
0
176
Member Avatar for pinkxhmile03

I'm not sure what you are asking here. upgrading what? long picture to another picture?

Member Avatar for AndreRet
0
87
Member Avatar for fx.eko

Your database was saved in a different folder than you application installed folder (normally the case). Your app is trying to read from the database or the reposrts that is saved in a folder that you do not have permission to write or read from... Make sure that the database …

Member Avatar for AndreRet
0
171
Member Avatar for PinoyDev

You would have somethjing like this (not sure, you will have to play with the code a bit, have not worked on CR for quite some time now...) With CRV ''Where CRV is your crystal report name... frmEdit.Show 1 ''vbmodal End With This will go under the report click event.

Member Avatar for AndreRet
0
531
Member Avatar for mikaichan13

Try the following... hold1 = "[Username] like'" + txtUserName.Text + "'" hold2 = "[Password] like'" + txtPassword.Text + "'" Set Adodc1.Recordset = hold1 ''Or hold 2, what you want to use... Your error is referring to your recordset wich is invalid. Use hold1/2 as the recordset.

Member Avatar for AndreRet
0
150
Member Avatar for javanoob101

I know there is a way by using javascript. Have a look at [this](http://www.htmlhelpcentral.com/messageboard/showthread.php?12261-JavaScript-No-Right-Click) link... Or [this](http://www.sapien.com/support/forum#/discussion/4149/disable-right-click-in-vbscript-/p1) link...

Member Avatar for javanoob101
0
374
Member Avatar for asaness

Firstly read our posting rules. Please open your own post with your own question. Secondly, I have absolutely no idea what you are talking about in your question. What virus? What language? What's your code and error?

Member Avatar for amiladinusha
0
275
Member Avatar for kimangel

It will update every time you click on your cmdUpdate button because you are telling the form to update. Add a cmdCancel button to your form. If the user do not want to update, they can click on cancel and then exit the form... cmdCancel_Click ''Write some code to clear …

Member Avatar for kimangel
0
146
Member Avatar for wondering_ed

Wondering, I was wondering what you have coded thus far. Show us some effort and we will most definitely help you out with a solution. Please read the rules about asking questions at the top of any posted page - > Our Software Development forum category encompasses topics related to …

Member Avatar for Reverend Jim
0
498
Member Avatar for kimangel

Your Time_Out must update the already existing record that you created when the user clocked in... Private Sub cmdTimeOut_Click() Set rs = New ADODB.Recordset rs.Open "SELECT * FROM Time_Out WHERE Employees_IdNo = '" & txtEmployee_IdNo.Text & "'", cn, adOpenKeyset, adLockOptimistic ''rs!Employees_IdNo = txtEmployee_IdNo.Text - Will not need this, already existing... …

Member Avatar for kimangel
0
183
Member Avatar for Bile

Not sure what you need Bile... After the user found the file (via your code above), you want to open say a word document, picture etc? Seems that you will be making use of the shell command then.

Member Avatar for AndreRet
0
3K

The End.