473,748 Members | 2,223 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Set a Field of Recordset to be editable

ANC
hi,

i would like to ask how can i set a field of recordset to be editable?
thanks in advance.

ANC
Jul 19 '05 #1
7 2160
Do not use an adLockReadOnly locktype.

Cheers
Ken

"ANC" <an*******@hotm ail.com> wrote in message
news:eV******** ******@tk2msftn gp13.phx.gbl...
: hi,
:
: i would like to ask how can i set a field of recordset to be editable?
: thanks in advance.
:
: ANC
:
:
Jul 19 '05 #2
I'm surprised nobody else here has brought this up: You
shouldn't!

Assuming you are using SQL or Access, you should update
your data with an SQL UPDATE statement.
IE

UPDATE MYTable SET MyTextField = 'somevalue',
MyNumberField = somenumber
WHERE MyKey = SomeKeyValue

HTH,
John
-----Original Message-----
Do not use an adLockReadOnly locktype.

Cheers
Ken

"ANC" <an*******@hotm ail.com> wrote in message
news:eV******* *******@tk2msft ngp13.phx.gbl.. .
: hi,
:
: i would like to ask how can i set a field of recordset to be editable?: thanks in advance.
:
: ANC
:
:
.

Jul 19 '05 #3
A recordset could be, for example, disconnected from the database - using an
UPDATE statement in such a case is pointless.

I suppose we just don't know what the OP is trying to do!

Cheers
Ken

"John Beschler" <gi***@geewhiz. com> wrote in message
news:02******** *************** *****@phx.gbl.. .
: I'm surprised nobody else here has brought this up: You
: shouldn't!
:
: Assuming you are using SQL or Access, you should update
: your data with an SQL UPDATE statement.
:
:
: IE
:
: UPDATE MYTable SET MyTextField = 'somevalue',
: MyNumberField = somenumber
: WHERE MyKey = SomeKeyValue
:
: HTH,
: John
:
:
:
: >-----Original Message-----
: >Do not use an adLockReadOnly locktype.
: >
: >Cheers
: >Ken
: >
: >"ANC" <an*******@hotm ail.com> wrote in message
: >news:eV******* *******@tk2msft ngp13.phx.gbl.. .
: >: hi,
: >:
: >: i would like to ask how can i set a field of recordset
: to be editable?
: >: thanks in advance.
: >:
: >: ANC
Jul 19 '05 #4
ANC
ken, thanks for the advice.

Maybe i'm not making clear to my question, sorry about that.

I created a recordset and put it in a table. User can edit some of the field
on the table.

however, my table is all protected, i don't know how to make it editable by
user.

or is it possible to do this?!

John, please read the question carefully even u're trying to solve my
problem,

of coz i'm not asking how to write the update script with sql statement.

Thanks,

Anthea

"Ken Schaefer" <ke*******@THIS adOpenStatic.co m> ¦b¶l¥ó
news:uT******** ******@TK2MSFTN GP12.phx.gbl ¤¤¼¶¼g...
A recordset could be, for example, disconnected from the database - using an UPDATE statement in such a case is pointless.

I suppose we just don't know what the OP is trying to do!

Cheers
Ken

"John Beschler" <gi***@geewhiz. com> wrote in message
news:02******** *************** *****@phx.gbl.. .
: I'm surprised nobody else here has brought this up: You
: shouldn't!
:
: Assuming you are using SQL or Access, you should update
: your data with an SQL UPDATE statement.
:
:
: IE
:
: UPDATE MYTable SET MyTextField = 'somevalue',
: MyNumberField = somenumber
: WHERE MyKey = SomeKeyValue
:
: HTH,
: John
:
:
:
: >-----Original Message-----
: >Do not use an adLockReadOnly locktype.
: >
: >Cheers
: >Ken
: >
: >"ANC" <an*******@hotm ail.com> wrote in message
: >news:eV******* *******@tk2msft ngp13.phx.gbl.. .
: >: hi,
: >:
: >: i would like to ask how can i set a field of recordset
: to be editable?
: >: thanks in advance.
: >:
: >: ANC

Jul 19 '05 #5
OK, Now I'm really confused. When you say "I created a
recordset and put it in a table." Do you mean an HTML
table in your web page, or a table in your database?

If you mean an HTML table in your web page, then you would
have to replace the values in your table with input tags
and process the page accordingly.

If you mean a table in your database, then you need to let
us know which database you are using (MS-SQL, MS-Access,
mySql, Oracle, etc.)

HTH,
John
-----Original Message-----
ken, thanks for the advice.

Maybe i'm not making clear to my question, sorry about that.
I created a recordset and put it in a table. User can edit some of the fieldon the table.

however, my table is all protected, i don't know how to make it editable byuser.

or is it possible to do this?!

John, please read the question carefully even u're trying to solve myproblem,

of coz i'm not asking how to write the update script with sql statement.
Thanks,

Anthea

"Ken Schaefer" <ke*******@THIS adOpenStatic.co m> ¦b¶l¥ó
news:uT******* *******@TK2MSFT NGP12.phx.gbl ¤¤¼¶¼g...
A recordset could be, for example, disconnected from the database - using
an
UPDATE statement in such a case is pointless.

I suppose we just don't know what the OP is trying to

do!
Cheers
Ken

"John Beschler" <gi***@geewhiz. com> wrote in message
news:02******** *************** *****@phx.gbl.. .
: I'm surprised nobody else here has brought this up: You : shouldn't!
:
: Assuming you are using SQL or Access, you should update : your data with an SQL UPDATE statement.
:
:
: IE
:
: UPDATE MYTable SET MyTextField = 'somevalue',
: MyNumberField = somenumber
: WHERE MyKey = SomeKeyValue
:
: HTH,
: John
:
:
:
: >-----Original Message-----
: >Do not use an adLockReadOnly locktype.
: >
: >Cheers
: >Ken
: >
: >"ANC" <an*******@hotm ail.com> wrote in message
: >news:eV******* *******@tk2msft ngp13.phx.gbl.. .
: >: hi,
: >:
: >: i would like to ask how can i set a field of recordset : to be editable?
: >: thanks in advance.
: >:
: >: ANC

.

Jul 19 '05 #6
ANC
the recordset is put into an HTML table and user can edit some of the field
on the web, and they press submit button,
then i will update the data by script.
but now i can't make my HTML table to be editable.

Thanks for reading my problem.

Anthea

"John Beschler" <gi***@geewhiz. com> ???
news:07******** *************** *****@phx.gbl ???...
OK, Now I'm really confused. When you say "I created a
recordset and put it in a table." Do you mean an HTML
table in your web page, or a table in your database?

If you mean an HTML table in your web page, then you would
have to replace the values in your table with input tags
and process the page accordingly.

If you mean a table in your database, then you need to let
us know which database you are using (MS-SQL, MS-Access,
mySql, Oracle, etc.)

HTH,
John
-----Original Message-----
ken, thanks for the advice.

Maybe i'm not making clear to my question, sorry about that.
I created a recordset and put it in a table. User can edit some of the fieldon the table.

however, my table is all protected, i don't know how to make it editable byuser.

or is it possible to do this?!

John, please read the question carefully even u're trying to solve myproblem,

of coz i'm not asking how to write the update script with sql statement.
Thanks,

Anthea

"Ken Schaefer" <ke*******@THIS adOpenStatic.co m> ¦b¶l¥ó
news:uT******* *******@TK2MSFT NGP12.phx.gbl ¤¤¼¶¼g...
A recordset could be, for example, disconnected from the database - using
an
UPDATE statement in such a case is pointless.

I suppose we just don't know what the OP is trying to

do!
Cheers
Ken

"John Beschler" <gi***@geewhiz. com> wrote in message
news:02******** *************** *****@phx.gbl.. .
: I'm surprised nobody else here has brought this up: You : shouldn't!
:
: Assuming you are using SQL or Access, you should update : your data with an SQL UPDATE statement.
:
:
: IE
:
: UPDATE MYTable SET MyTextField = 'somevalue',
: MyNumberField = somenumber
: WHERE MyKey = SomeKeyValue
:
: HTH,
: John
:
:
:
: >-----Original Message-----
: >Do not use an adLockReadOnly locktype.
: >
: >Cheers
: >Ken
: >
: >"ANC" <an*******@hotm ail.com> wrote in message
: >news:eV******* *******@tk2msft ngp13.phx.gbl.. .
: >: hi,
: >:
: >: i would like to ask how can i set a field of recordset : to be editable?
: >: thanks in advance.
: >:
: >: ANC

.

Jul 19 '05 #7
So what you have is:
<table>
<tr>
<td>Data from my field 1</td>
</tr>
<tr>
<td>Data from my field 2</td>
</tr>
....
</table>

Is this correct? And you want to be able to edit that data?

Then you would need something like this:

<form name=myform action=update.a sp method=post>
<table>
<tr>
<td><input type=text name=txtfield1 value="Data from my
field 1"></td>
</tr>
<tr>
<td><input type=text name=txtfield2 value="Data from my
field 2"></td>
</tr>
<tr>
<td>
<input type=submit value="Submit">
</td>
</tr>
....
</table>
</form>

Then, you have to write the code for update.asp to process
the data when it gets back to the server.

-----Original Message-----
the recordset is put into an HTML table and user can edit some of the fieldon the web, and they press submit button,
then i will update the data by script.
but now i can't make my HTML table to be editable.

Thanks for reading my problem.

Anthea


Jul 19 '05 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

20
10160
by: | last post by:
If I need to check if a certain value does exist in a field, and return either "yes" or "not" which query would be the most effestive?
3
2890
by: WC Justice | last post by:
I need to build an UPDATE statement that copies the values of roughly 40 fields from a table that stores standard or default values into a table of specific contracts. There are 8 or so fields in the source table that are not in the destination table. The remaining field names are identical in both tables. How do I create a recordset of the field names I am interested in so that I can loop through it to build my UPDATE statement? ...
9
3337
by: William Wisnieski | last post by:
Hello Everyone, Access 2000 I have a main form with a continuous subform. On the main form I have a text field called . It gets populated based on what the user selects in a field on the sub form (code in the AfterUpdate Event). Here's the issue. If the user deletes a subform record. The field on the main form shows null even if there is a value in the preceding subform record. What I'd like it to do is immediately refresh to
4
2553
by: Javier Gomez | last post by:
I have a query field which is a non editable field because is a function's result. Due to I need to edit the information, Can you please suggest me any solution for this problem?? (No matter which one) I tryed to duplicate this field , (copying into a new temporally field) but no success....... continues non editable field :-(((
3
2789
by: shumaker | last post by:
This code from the subform works for getting the value of a field of the main form named "WorkSheet": MsgBox Form_WorkSheet.Recordset.Fields("Clerk").Value Each record in the mainform datasheet called "WorkSheet" has a subform. I am trying to get the controls on the subform to reference the fields in the main form, because I think that it will resolve some of my write conflict problems by not having a recordset for the subform, and...
7
10301
by: Benton | last post by:
Hi there, I have a text box which will receive its value from a pop-up date picker. The user should not be able to edit this field with the keyboard or mouse. I am using ASP.NET. If I set the readonly property of the textbox to true, it won't let the user change it and it can receive its value from the pop-op calendar, just what I need. Problem is, after a postback, value is lost. So I think Javascript may come to the rescue here. Is...
5
5887
by: Henrik | last post by:
The problem is (using MS Access 2003) I am unable to retrieve long strings (255 chars) from calculated fields through a recordset. The data takes the trip in three phases: 1. A custom public function returns a long string. This works. 2. A query has a calculated field based on the custom function above. This works when the query is run directly.
4
2726
by: Paul | last post by:
Hi all, I have a page that has a form on it which has a dropdown list on it. It connect to an sql database and populate the list. What I would like to do is make the list editable so that if the data returned doesnt contain what I want, I can type in the data I require which will then be updated to the database when the form is posted. Hope I've made sense, you may be able to tell I'm a bit of a newbie!
2
1239
by: jghouse | last post by:
Everyone, Hopefully you can help me with a little problem I am having. I have a need to limit the records shown in a form by a few different criteria. I also need these records to be editable. I am capable of building the query to show the records but when I include one query I need to get a limiting value from (orders greater than 1 per day, calculated value in that query) the records are no longer editable. I believe this is because...
0
8822
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9528
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9359
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9310
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8235
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6792
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4863
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
2774
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2206
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.