473,386 Members | 1,820 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Trouble setting hyperlink string with code

If I type
www.microsoft.com
into the control txtSearchString which is bound to a hyperlink field, I
can click it and automatically zoom off to the web page.
But if I try to set the field with this snippet of code
Me.txtSearchString = "www.microsoft.com"
DoCmd.RunCommand acCmdSaveRecord
clicking on the field does nothing.

Well, not quite nothing. A tiny little square appears under the pointy
hand.

Any ideas?

pemigh

Nov 13 '05 #1
2 1998
I answered my own question. This works:
Me.txtSearchString = "www.microsoft.com#http://www.microsoft.com#"

Apparently Access does this concatenation when you type in the text,
but not when you set it with code. (I figure this out by using
SendKeys to mimic actually typing the text.)

pemigh


pemigh wrote:
If I type
www.microsoft.com
into the control txtSearchString which is bound to a hyperlink field, I
can click it and automatically zoom off to the web page.
But if I try to set the field with this snippet of code
Me.txtSearchString = "www.microsoft.com"
DoCmd.RunCommand acCmdSaveRecord
clicking on the field does nothing.

Well, not quite nothing. A tiny little square appears under the pointy
hand.

Any ideas?

pemigh


Nov 13 '05 #2
I answered my own question. This works:
Me.txtSearchString = "www.microsoft.com#http://www.microsoft.com#"

Apparently Access does this concatenation when you type in the text,
but not when you set it with code. (I figure this out by using
SendKeys to mimic actually typing the text.)

pemigh


pemigh wrote:
If I type
www.microsoft.com
into the control txtSearchString which is bound to a hyperlink field, I
can click it and automatically zoom off to the web page.
But if I try to set the field with this snippet of code
Me.txtSearchString = "www.microsoft.com"
DoCmd.RunCommand acCmdSaveRecord
clicking on the field does nothing.

Well, not quite nothing. A tiny little square appears under the pointy
hand.

Any ideas?

pemigh


Nov 13 '05 #3

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

Similar topics

9
by: Penn Markham | last post by:
Hello all, I am writing a script where I need to use the system() function to call htpasswd. I can do this just fine on the command line...works great (see attached file, test.php). When my...
0
by: pemigh | last post by:
If I type www.microsoft.com into the control txtSearchString which is bound to a hyperlink field, I can click it and automatically zoom off to the web page. But if I try to set the field with...
18
by: Dixie | last post by:
Can I set the Format property in a date/time field in code? Can I set the Input Mask in a date/time field in code? Can I set the Format of a Yes/No field to Checkbox in code? I am working on...
0
by: Ryan Harvey | last post by:
Hi all, I have written a web user control that contains a repeater control. the ItemTemplate for this control is basically 6 Hyperlinks in a row, that are dynamically allocated one of 7 gif...
5
by: Martin Dew | last post by:
Having some problems getting a hyperlink object to work in my repeater control, It displays the text I have asked it to for the hyperlink, but it does not act as a link. My repeater code is below...
2
by: junlia | last post by:
Hi All, I am working on a project that acts as a bridge. It does some checking with post xml data, and then redirects the request to an appropriate page. However, we find that depends on the...
6
by: Daniel Walzenbach | last post by:
Hi, I have a web application which sometimes throws an “out of memory” exception. To get an idea what happens I traced some values using performance monitor and got the following values (for...
8
by: Jeff | last post by:
ASP.NET 2.0 I'm wondering how to set the color of a visited HyperLinkField (the link text) in a GridView?? Here is the markup of the HyperLinkField I have problems with: <asp:HyperLinkField...
4
by: Jeff | last post by:
hi asp.net 2.0 I have created a custom web control, here is it's header: <%@ Control Language="C#" AutoEventWireup="true" CodeFile="EditUserBox.ascx.cs" Inherits="Controls_EditUserBox" %> ...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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...
0
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,...
0
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...

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.