Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

SAVING DATA TO A VISUAL DATAMANAGER DATABASE

Posted on 2000-04-04
2
160 Views
Last Modified: 2010-05-02
I HAVE A DATABASE WITH THE FIELDS "SURNAME", "NUMBER",M AND "ID", AND WOULD LIKE TO KNOW THE CODE TO STORE A NUMBER TO A LOCATION RANGING FROM 1 - 10.

I.E.
TYPE IN A NUMBER INTO TEXT1.TEXT AND THEN PRESS A STORE BUTTON, THEN TO SELECT THE LOCATION, PRESS THE BUTTONS RANGING FROM 1 - 10

E.G.
TYPE IN A NUMBER, PRESS THE STORE BUTTON, AND THEN THE NUMBER 2 BUTTON, AND IT WILL BE STORED TO LOCATION 2 IN THE FASTDIAL DATABASE.


THEN BE ABLE TO RECALL THIS DATA IN THE SAME WAY AS A TELEPHONE FASTDIAL WORKS.

I.E.
PRESS A BUTTON RANGING FROM 1 - 10 AND IT RECALL THE NUMBER IN THAT LOCATION

E.G.
PRESS BUTTON 1 AND IT RECALLS LOCATION 1'S NUMBER AND NAME INTO THE DISPLAY. WITH SURNAME BEING DISPLAYED IN TEXT3.TEXT AND NUMBER IN TEXT4.TEXT
0
Comment
Question by:Warsteiner99
2 Comments
 
LVL 10

Expert Comment

by:caraf_g
ID: 2683113
PLEASE DON'T SHOUT AT US!!!!!
0
 
LVL 1

Accepted Solution

by:
riduce earned 100 total points
ID: 2683163
dim fdNumber as String

Private Sub butStore_Click()
Data1.RecordSource = "select * from [FastDial] where [storenr] = '" & text1.text  & "'" & " order by [storenr]": _
      Data1.Refresh: _
Data1.Recordset.Edit
Data1.Recordset![storeNr] = Text1.Text
Data1.Recordset![Surename] = Text2.Text
Data1.Recordset![Number] = Text3.Text
Data1.UpdateRecord
End Sub

Private Sub butFastDial_Click(Index As Integer)
fdNumber = butFastDial(index).index
Data1.RecordSource = "select * from [FastDial] where [storenr] = '" & fdNumber  & "'" & " order by [field7], [field5]": _
      Data1.Refresh: _
text3.text = Data1.recordset![Surename]
text4.text = Data1.recordset![Number]
End Sub
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Adding to a VBA? 6 78
SLMGR Switches Are Not Working On KMS Host 3 110
vbModal 12 57
Set WorkSheet  not Working 9 41
Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

861 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question