Symbianize Forum

Most of our features and services are available only to members, so we encourage you to login or register a new account. Registration is free, fast and simple. You only need to provide a valid email. Being a member you'll gain access to all member forums and features, post a message to ask question or provide answer, and share or find resources related to mobile phones, tablets, computers, game consoles, and multimedia.

All that and more, so what are you waiting for, click the register button and join us now! Ito ang website na ginawa ng pinoy para sa pinoy!

[TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataReport

Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

Tapos na po yung Add eh. Try mo download ung last part. Andun ung pinoproblema mo. Yung Adding. Try to understand, logic logic. And mga commands, searchable naman.



ok thanks, di ko nadownload ung laspart.
 
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

ok thanks, di ko nadownload ung laspart.

Yan na yun. Ganda pala ng nagawa ni sir eric. Madaming makukuhang style and technique. :thanks:
 
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

Yan na yun. Ganda pala ng nagawa ni sir eric. Madaming makukuhang style and technique. :thanks:


oonga eh, kaya nagkainteres akong pag-aralan. ok to for future use, basta study and practice lang...
 
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

Ano pa ba ang gusto nyo makita dyan sa sample?

baste generic database functions ha, walang kinalaman ang SMS or barcode or kung ano ano.

what im showing you guys is a TOOL na magagamit nyo sa bawat projects nyo,
di lang sa vb6 pati sa vb.net, same lang ang style ko.


gusto nyo ba yung may CLASSES na?
aral kayo about classes tapos apply natin sa database as data layer class

mas matutuwa ako kung meron pa kayo makitang pwede i improve sa coding.
 
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

sir question to your program.

Function WriteImageToDB(source As String, t As Recordset, sField As String)

jump po tau dito:

'Open the source file.
SourceFile = FreeFile

where did you get the FreeFile?; and
Const BlockSize = 32768?

what does it mean 32768? ito po ba ung size ng picture in pixel?;

and other one is FileData = String$(LeftOver, 32);
FileData = String$(BlockSize, 32)
sir what is the function of this and logic?

ito pa po:
FileLength = LOF(SourceFile)
If FileLength = 0 then
WriteImageToDB = 0
Exit Function
End If

tanong ko po kung ang filelength = 0 walang ira-write sa database? then exit function;

FileLength = LOF(SourceFile)
ung LOF po ba is Length Of File na ang value ay galing sa SourceFile, i imumultiply ung LOF sa value ng SourceFile, tama po ba?

thanks.
 
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

sir question to your program.

Function WriteImageToDB(source As String, t As Recordset, sField As String)

jump po tau dito:

'Open the source file.
SourceFile = FreeFile

where did you get the FreeFile?; and
Const BlockSize = 32768?

what does it mean 32768? ito po ba ung size ng picture in pixel?;

and other one is FileData = String$(LeftOver, 32);
FileData = String$(BlockSize, 32)
sir what is the function of this and logic?

ito pa po:
FileLength = LOF(SourceFile)
If FileLength = 0 then
WriteImageToDB = 0
Exit Function
End If

tanong ko po kung ang filelength = 0 walang ira-write sa database? then exit function;

FileLength = LOF(SourceFile)
ung LOF po ba is Length Of File na ang value ay galing sa SourceFile, i imumultiply ung LOF sa value ng SourceFile, tama po ba?

thanks.

ssshhhh....
lahat ng sasabihin ko sayo ay nasa MSDN, Google or microsoft

everytime you open a file, the OS assigns a handle or file number.

Freefile = Function to get the first file number that is free, ayaw ko mag assign ng number dahil di ko naman alam kung free yung number na yun
yung mga tamad they open a file this way
SourceFile = 1 ' do you know kung may isang open file na gumagamit ng 1?
ako di ko alam and i dont care to know,
i just call Freefile to give me the first free file number, pwedeng 1 or 32768, i dont care.


if you are paying attention sa school, 32768 is the largest value of your integer.

in ADODB, you can not assign a binary data directly into a datafield then save, unsafe yun.

waht we do, the safest way, maski malaki or maliit na image yan, is to break up the file into CHUNKS

Const BlockSize = 32768 '32768bytes per chunks

we read the image/binary file 32768 bytes at a time then insert it into the field sa databse natin

so kung may 130kb ka na image
it will take 40 chunks + yung sobra,

pagdating sa database magdidkit lahat yung chunks
ImageField:
chunk1 + chunk2 + chunk3 + .......... + remainder (leftover)

actually pwede din naman na isaksak mo lahat yung image sa field
pero as i said this is the safest way to do it.

that code will not have any problem loading large images into the database dahil by chunks ang pag load nya.

FileLength = LOF(SourceFile)
get the length of the file, sa computation ng chunks to ginagamit

LOF("C:\Windows\Notepad.exe") = file size ng notepad
if you get the size, you know how to loop by chunks.

at pag ang file lenght ay ZERO, ano pa ang gagawin mo, wala naman laman yung file.

FileData = String$(BlockSize, 32)
String("x", 20) = "xxxxxxxxxxxxxxxxxxxx" 'get mo?

nag gawa lang ako ng container ng string 32characters long

as i said nsa MSDN or M$ or Google yan

i remember may comment din yung code
 
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

Hay...after all..mow lang ako nakuha ng mga code na galingsa prof..salamat po d2 malaking tulong toh...salamat..mahirap kc sakin ang vb..kea kelangan ng maraming time para matutunan ko toh at mga sample code...salamat..more powers
 
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

THANKS! edit ku tu gawin ko invetory system. Pero parang invetory system na din tu dba? :noidea:
 
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

THANKS! edit ku tu gawin ko invetory system. Pero parang invetory system na din tu dba? :noidea:

yes same structure, mag dagdag ka nalang ng transactions
 
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

ang tagal ko ng naghahanap ng ganitong program! So need this tutorial kasi parang ganito din ung project ko. Haha! Thank you so much! :)
 
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

Hi can you help me with my problem. need it badly. thanks
 
Last edited:
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

Hi can you help me with my problem. need it badly. thanks

about lovelife po ba yan?


why dont you tell us po in detail about your problem para naman alam namin kung papano ka tutulungan

50% of the solution is understanding the problem
 
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

Sir Eric may alam kabang site kung paano iconnect mySQL sa VB6?
 
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

Sir Eric may alam kabang site kung paano iconnect mySQL sa VB6?

dapat installed and client drivers ng mySQL sa pc tapos palitan mo lang yung connection string ng project na nandito gagana na yan

ang connection string ng mySQL ay medyo naiiba
Code:
DRIVER={MySQL ODBC 3.51 Driver};SERVER=123.456.789.100;DATABASE=mysqldatabase;UID=sampleuser;PWD=12345;OPTION=16427

hanapin mo dito kung ano ang bagay sa purpose mo
http://connectionstrings.com/mysql
 
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

hope it is! lol

anyways, im creating a system. basically it's a simple VB program where you can view your database using VB6.

My problem is, I need to put some documents (images, pdf files) to my database. Then, pwde ma search sa VB6. Unfortunately, I don't know how to do this. lol


PLEASE! PLEASE HELP ME! :))

I am using adodc btw kasi I'm not really familiar with adodb.
 
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

hope it is! lol

anyways, im creating a system. basically it's a simple VB program where you can view your database using VB6.

My problem is, I need to put some documents (images, pdf files) to my database. Then, pwde ma search sa VB6. Unfortunately, I don't know how to do this. lol


PLEASE! PLEASE HELP ME! :))

I am using adodc btw kasi I'm not really familiar with adodb.

ayan po medyo malinaw na.

everything you need is right on the sample na po.
ADD/EDIT/DELETE/UPDATE (CRUD)

about the pdf and images, you can save the binary file into the database just like the image saving found in the sample
or you can just save the filenames of the images and pdfs

as it is we have no way of searching inside the images and documents so an alternative is to assign fields for keywords for which you can search

for your database you can do this
option1:
Title....................|Keywords..................................|BinaryFile............................
The Art of C pdf...|C programming; Art, language|0XADFCDG1(binary nga e)

or option2
Title....................|Keywords..................................|Filename............................
The Art of C pdf...|C programming; Art, language|C:\Files\AAA.pdf


then simple menus and buttons and search box
all of which you can find here

sorry i cant give you anything for ADODC, that would be against my principles in life
 
Last edited:
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

I downloaded your tutorial about it and tried my best to understand it, but obviously, I fail :(

I also tried to make my own VB project with the adodc as my data source and an image box but it's not working. I really don't know what to do now :(
 
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

I downloaded your tutorial about it and tried my best to understand it, but obviously, I fail :(

I also tried to make my own VB project with the adodc as my data source and an image box but it's not working. I really don't know what to do now :(

take it step by step po,
study the connection object, the recordset, the sql query.

create small project to practice the concepts i mentioned
you have a pattern from the sample, you can follow it
then you can ask detailed questions about a particular code

i suggest you design your GUI also using simple drawing tools suach as paint or MSWord, then describe its functionalities and process.

then pag malinaw na sayo ang vb programing you can start coding

we can help you every step of the way
 
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

i'll give it a try. thanks so much :)
 
Re: [TUT] VB6 MSAccess Sample using ADO (UPDATED V3 20100216) now with ADD and DataRe

aus to otor.. thanks dito.. nasusundan ko naman kahit papano.., galing ahh.. nasa login pa lang ako.. try ko pa bukas kung pano magadd ng user.. otor, nalalagyan ba ng checkbox ung listview?
 
Back
Top Bottom