CodeCharge Studio
search Register Login  

Visual PHP Web Development

Visually Create Internationalized Web Applications, Web Reports, Calendars, and more.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> .NET

 Displaying a record based on the selection on a list

Print topic Send  topic

Author Message
Abe Jimenez
Posted: 04/21/2006, 4:09 PM

Hi,

I'm new to Code Charge. This is my first project, so please forgive me if I
sound stupid. This is what I'm trying to do.

I have a table in my database with product information. Each product has a
text field with the product name and a long memo description (there are
other columns, but they are not relevant right now). I want to create a
grid showing the product names as links. When the user clicks on a product
name I want to display the memo field that corresponds to the product in a
record form underneath.

So far I created my grid with the product names and my record underneath. I
converted the product name in the grid to a link so the users can click on
the products. What I don't know how to do is to reload the record when a
new product is selected.

This is a VB.NET project.

Thanks in advance for your help.
--

Regards,
Abe Jimenez


Diesel

Posts: 43
Posted: 04/26/2006, 4:13 AM

If you say that you made the productname a link then it should be simple!

Just make sure that you have done the following:

Click on the Link you created. Now go to the Properties tab to the right and make the following changes to the properties

Href Type: Page
Href Source: The current page - so if you are currently on "Index.ccp" then that is what you would select as the source. To open the properties for the source click on the little button with the ... (dots). There you can give the display value for your link and select the page you are going to return which should be the current one as explained.
Now go to the Parameter tab at the top and open. Click on the + sign to the right.

Specify the record id parameter you are going to return.

in your case:

Source Type: Database Column
Parameter Source: {Your record primary key (id)}
Parameter Name: The same as your Parameter Source

Now click on your record form and go to the properties to the right
Click on the Data Source on the ...(dots) button. This will open your record datasource.

On the left you will find a WHERE clause (Your SQL query). Now click on the + sign in the bottom right frame and complete the detail as follows:

Condition Type: Parameter

Field
-Name: {Your record primary key (id)}
-NameType:Integer
-Codition: equals(=)
-Parameter: {The name of the parameter - this should be {Your record primary key (id)}}
-ParameterType:URL

Compile and run. Now when you click on a productname link the record form should refresh with the values in that record

Hope it helps. Shout if you need help....
Zack

View profile  Send private message
Abe Jimenez
Posted: 04/26/2006, 7:40 AM

Thanks. I had done pretty much what you suggested, except I had named the
parameter Selected_Product instead of Product_id (shouldnt make a
difference). The problem I was having was that somehow I had enabled
caching and that made it not work. Problem solved.

--

Regards,
Abe Jimenez


"Diesel" <Diesel@forum.codecharge> wrote in message
news:8444f55d34dc08@news.codecharge.com...
> If you say that you made the productname a link then it should be simple!
>
> Just make sure that you have done the following:
>
> Click on the Link you created. Now go to the Properties tab to the right
> and
> make the following changes to the properties
>
> Href Type: Page
> Href Source: The current page - so if you are currently on "Index.ccp"
> then
> that is what you would select as the source. To open the properties for
> the
> source click on the little button with the ... (dots). There you can give
> the
> display value for your link and select the page you are going to return
> which
> should be the current one as explained.
> Now go to the Parameter tab at the top and open. Click on the + sign to
> the
> right.
>
> Specify the record id parameter you are going to return.
>
> in your case:
>
> Source Type: Database Column
> Parameter Source: {Your record primary key (id)}
> Parameter Name: The same as your Parameter Source
>
> Now click on your record form and go to the properties to the right
> Click on the Data Source on the ...(dots) button. This will open your
> record
> datasource.
>
> On the left you will find a WHERE clause (Your SQL query). Now click on
> the +
> sign in the bottom right frame and complete the detail as follows:
>
> Condition Type: Parameter
>
> Field
> -Name: {Your record primary key (id)}
> -NameType:Integer
> -Codition: equals(=)
> -Parameter: {The name of the parameter - this should be {Your record
> primary
> key (id)}}
> -ParameterType:URL
>
> Compile and run. Now when you click on a productname link the record form
> should refresh with the values in that record
>
> Hope it helps. Shout if you need help....
> Zack
>
>
> ---------------------------------------
> Sent from YesSoftware forum
> http://forums.codecharge.com/
>


Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

MS Access to Web

Convert MS Access to Web.
Join thousands of Web developers who build Web applications with minimal coding.

CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.