What's new
  • Welcome to PHCorner forums. Take a moment to sign up and gain unlimited access and extra privileges that guests are not entitled to, such as: All that and more! Registration is quick, simple and absolutely free. Join our community today!

Help Project vb.net help

xValk

Elite
Joined
Jul 1, 2016
Messages
964
Reaction
1,099
Age
28
hi goodeve po pwde po magpatulong about sa vb.net and connecting data base.

here is my idea to my project.
gagawa sana ko game like who wants to be a millionaire ung gameplay.but ung questions nya is nakarandomize galing sa database.

if possible po .give me some tips or hint .baguhan lng po sa pag porprogram.saba po ay matulungan nyo ko.
 

damnpython

Honorary Poster
Nakagawa rin ako ng ganitong game before, but in C# though hindi ko na alam saan ko nalagay haha.

Before the tips, ask yourself first: Para saan ba tong app na to, for deployment sa store or school project?
Another is, anong alam mong database na gamitin?

Most of the time, I would use ADO.NET since smaller and easy deployment compared to others.

Now, let's move on to the tips kung paano gawin yung randomization ng questions.

Ilagay mo yung questions mo sa database with this format.
QuestionID | Question | Choice 1 | Choice 2 | Choice 3 | Choice 4 | CorrectAns
1 | What does SQL stands for? | Structured Query Language | Simple Query Language | Saving Query Language | Stored Query Language | Structured Query Language

Then, sa code-behind mo. Gawa ka ng method na mag-gegenerate ng RANDOM numbers. Note: Ang range is the total number of your questions. For example, meron kang 50 questions in total so ofourse i-set mo to 50 yung range ng RANDOM variable mo. BUT WHY?
- The answer is, once nakagenerate ka na ng random number pwede mo ng i-retrieve yung data galing sa database mo then make a method para sa assigning of data into your respective textbox.

You get the idea. :)
 
Comment

xValk

Elite
Nakagawa rin ako ng ganitong game before, but in C# though hindi ko na alam saan ko nalagay haha.

Before the tips, ask yourself first: Para saan ba tong app na to, for deployment sa store or school project?
Another is, anong alam mong database na gamitin?

Most of the time, I would use ADO.NET since smaller and easy deployment compared to others.

Now, let's move on to the tips kung paano gawin yung randomization ng questions.

Ilagay mo yung questions mo sa database with this format.
QuestionID | Question | Choice 1 | Choice 2 | Choice 3 | Choice 4 | CorrectAns
1 | What does SQL stands for? | Structured Query Language | Simple Query Language | Saving Query Language | Stored Query Language | Structured Query Language

Then, sa code-behind mo. Gawa ka ng method na mag-gegenerate ng RANDOM numbers. Note: Ang range is the total number of your questions. For example, meron kang 50 questions in total so ofourse i-set mo to 50 yung range ng RANDOM variable mo. BUT WHY?
- The answer is, once nakagenerate ka na ng random number pwede mo ng i-retrieve yung data galing sa database mo then make a method para sa assigning of data into your respective textbox.

You get the idea. :)

salamat po sir.mejo na enlighten ako sa sinabi mo.and nadagdagan ung ideas ko kung pano ko sya magagawa.
 
Comment

xValk

Elite
ung sa pag generate ko ng random question.pano po kapag nag generate ulit dapat hindi nya na uulitin ung na generate. using if statement po ba?
 
Comment

Online statistics

Members online
1,818
Guests online
2,008
Total visitors
3,826

Forum statistics

Threads
1,071,205
Messages
18,111,285
Members
1,515,844
Comments
1,079,208
Attachments
1,386,857
Profile posts
97,573
Top