If and hyperlinks....

I have a hyperlink in a cell, which i need to delete based on another event....

I was hoping to do this using an IF function, or maybe conditional 
formatting, but cannot work it out....

Ill show what i mean because this can be confusing


In say, cell A1, i have a hyperlink, called abc. It actually links to a 
webpage say, http://www.abc.co.uk. In cell B1 i have a number, which changes 
between 0 and 1

when the number 0 appears, i want the hyperlink to stay, but when it changes 
to a 1 i want the hyperlink to disappear. This is because of a macro I am 
trying to run...


The problem is, because the actual web page is not in the cell, when i try 
to do an IF function,in cell A1, i may do =IF(B1=0, abc). I leave the false 
part blank so it returns a 0. This doesnt work though, as the abc part 
remains the same hyperlink, but when a 0 is returned when false, this too 
stays as a hyperlink to exactly the same web page.....but i need it to be 
gone completely, or at least not a hyperlink.

I have tried ways to get around this, but i cannot change the format of the 
link, ie. change it to www.abc.co.uk, rather than just abc, as the macro I am 
using relies heavily on this.


Thnx in advance for the help,
frazer

Can anyone help?
0
Frazer1 (18)
8/18/2005 8:19:05 AM
excel.misc 78881 articles. 5 followers. Follow

4 Replies
775 Views

Similar Articles

[PageSpeed] 41

Frazer,

I think this is what you're after:

if you have the URLs in A1 going down, and the 0/1 value in b1 going
down, in c1 for your result, type: =IF(b1=0,a1,"")

so that is just saying if b1=0 then display the contents of a1, if its
anything else display nothing, which is the "". you coould put anything
in between the "" to be displayed, such as "not here"

hope that's what you needed...


-- 
saybut
------------------------------------------------------------------------
saybut's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=5949
View this thread: http://www.excelforum.com/showthread.php?threadid=396766

0
8/18/2005 10:20:33 AM
Hmm yea i tried that but there are several problems:

Firstly, if you have in cell c1 =if(b1=0, a1, ""), then when the value is 0, 
it copies the hyperlink, but only the text part of the hyperlink, i.e. if the 
cell says abc which is a hyperlink to www.abc.com or whatever, then when the 
cell is copied across via the formula then the cell just says abc, and isnt 
hyperlinked....

I can do in cell d1 then =hyperlink(c1), but this is also uselss as it just 
makes the abc hyperlinked, but to nothing.....

"saybut" wrote:

> 
> Frazer,
> 
> I think this is what you're after:
> 
> if you have the URLs in A1 going down, and the 0/1 value in b1 going
> down, in c1 for your result, type: =IF(b1=0,a1,"")
> 
> so that is just saying if b1=0 then display the contents of a1, if its
> anything else display nothing, which is the "". you coould put anything
> in between the "" to be displayed, such as "not here"
> 
> hope that's what you needed...
> 
> 
> -- 
> saybut
> ------------------------------------------------------------------------
> saybut's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=5949
> View this thread: http://www.excelforum.com/showthread.php?threadid=396766
> 
> 
0
Frazer1 (18)
8/18/2005 11:27:02 AM
Ah right, I've just tried it then with the =hyperlink, it seems to work,
just you need to have the http://, not just www., I tried a couple
http://news.bbc.co.uk etc and http://www.abc.co.uk and they seem to
work fine.


-- 
saybut
------------------------------------------------------------------------
saybut's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=5949
View this thread: http://www.excelforum.com/showthread.php?threadid=396766

0
8/18/2005 12:11:33 PM
How about this in A1:

=HYPERLINK(IF(b1=1,"http://www.microsoft.com","#"&CELL("address",A1)),
                 "click me")

(One cell)

If b1=1, then you get to go to the site.  If b1=0, then you link to that same
cell (A1).



Frazer wrote:
> 
> I have a hyperlink in a cell, which i need to delete based on another event....
> 
> I was hoping to do this using an IF function, or maybe conditional
> formatting, but cannot work it out....
> 
> Ill show what i mean because this can be confusing
> 
> In say, cell A1, i have a hyperlink, called abc. It actually links to a
> webpage say, http://www.abc.co.uk. In cell B1 i have a number, which changes
> between 0 and 1
> 
> when the number 0 appears, i want the hyperlink to stay, but when it changes
> to a 1 i want the hyperlink to disappear. This is because of a macro I am
> trying to run...
> 
> The problem is, because the actual web page is not in the cell, when i try
> to do an IF function,in cell A1, i may do =IF(B1=0, abc). I leave the false
> part blank so it returns a 0. This doesnt work though, as the abc part
> remains the same hyperlink, but when a 0 is returned when false, this too
> stays as a hyperlink to exactly the same web page.....but i need it to be
> gone completely, or at least not a hyperlink.
> 
> I have tried ways to get around this, but i cannot change the format of the
> link, ie. change it to www.abc.co.uk, rather than just abc, as the macro I am
> using relies heavily on this.
> 
> Thnx in advance for the help,
> frazer
> 
> Can anyone help?

-- 

Dave Peterson
0
petersod (12004)
8/18/2005 12:56:13 PM
Reply:

Similar Artilces:

hyperlink #4
Hello, I have. a spreadsheet with 300+ records. One column has website addresses. How can I format those cells so that when I click on the web address, it will go to the websites? I know Excel explains it but I'm not understanding it. if someone could help me with this, I would really appreciate it. Thanks, Mindy Mindy Select the cells, hit F2 and ENTER as many times as needed to roll through the range and change to hyperlinks. Whole column at a time use this macro from David McRitchie. Sub MakeHyperlinks() Dim cell As Range For Each cell In Intersect(Selection, _ ...

Hyperlinks
I have a spreadsheet that is 3604 rows & 6 columns. Column E has only hyperlinks to URL's. I have filtered my data via column B. I tried to A-Z Column A. When I do, the hyperlinks do not stay with the data. The mask looks correct but when you scroll over the hyperlink you see a completely different URL.????? Can anyone tell me how to make sure the Hyperlink keeps the correct URL when filtering and sorting the data. Try using the =HYPERLINK() worksheet function Tim "LeisaA" <LeisaA@discussions.microsoft.com> wrote in message news:3362C55C-FBA2-43...

Excel 2000 Hyperlinks
Probably a silly question, but how do you turn off hyperlinks? I know how to remove them, but I want the entire feature turned off so that when I type an email address it doesn't turn it into an active hyperlink. In XP, you can go to Tools, Autocorrect options, but I can't seem to find the option in 2000. >>but I can't seem to find the option in 2000. Me either. You could precede the entry with an apostrophe. -- Jim Rech Excel MVP .... or hit CTRL-Z right after it converts. Rgds, Andy ...

Hyperlinks and e-mail
I want to be able to send an e-mail as a result of a vlookup. so if I have the name in Col A,the email address in Col B,the case number in Col C and the Vlookup formula on a different page I want to be able to lookup the name and also get the email hyperlink, with the case number included in the subject field. Then I need to automate that process with a Macro.......... Ade Hi not quite sure this is what you want but for mailing macros have a look at Ron's site: http://www.rondebruin.nl/sendmail.htm -- Regards Frank Kabel Frankfurt, Germany Ade wrote: > I want to be able to send a...

Can you hyperlink to a hyperlink?
I'm am having trouble linking/referencing a cell that contains another hyperlink. There is a master list on one tab, that has hyperlinks to all documents listed. Our other tabs (within the same spreadsheet) contain the same information that is stored in the master list tab, but specific to a group. (i.e. a training tab, lists only the training documents) The idea is to maintain only the hyperlink on the master list page, but allow others to click of the hyperlink to a document on their specific group tab, and it would open the document. Originally, I just used the &q...

Hyperlinks not hyperlinked in long messages
I am receiving a regular mail which contains many hyperlinks. It seems that, when the message exceeds a certain size, only the first hyperlinks work (colored blue and underlined), but they stop working somewhere in the last third of the message. I see this happening with messages with sizes of 129, 185, 210 KB. But on another message with 43KB all the hyperlinks work. (I can send the mentioned messages to someone willing to suggest a solution) I don't know if the problem has to do with the size of the message or the number of hyperlinks within. But if I break one of these messages i...

Hyperlinking images
I have a worksheet with several columns. One of the columns is entitled image which I've hyperlinked to image files. I thought that if I were to email this worksheet to someone else that my images would go along with it. Not happening. How do I set it up, so that the images are embedded on each row as a file name and if I email it to someone, all of the images are transferred also. I know it's a simple solution, but I'm not finding it. Thanks. You must either send all the image files along with the workbook or insert the images into the workbook. Sending ...

Hyperlink?
I have been trying to put a hyperlink to a bank in an Excel cell. After difficulty I tried very carefully to follow instructions. When I click on the link, I get a message that starts with "Unable to open <address>" and ends with "Cannot download the information you requested." I do not know if the following is a clue. The address in the cell starts with http://. If I manually copy the address and paste it into the browser it works. But the address that finally appears starts with https://. The rest of the address is modified as well. I am using a relatively...

create a hyperlink field for a tamplate?
I have a template with various fields, when I make use of it, all fields are displayed correctly. One of this fields is a text string that holds pathname and file name of a document related to the record. I would like to have this string come in as a hyperlink, and not have to go and manually change each cell in the column with the Insert - Hyperlink commands. Does anyone knows how to do this? NEW If using Excel 2002 or 2003 you can set this up under Tools>Autocorrect Options>Autoformat as you type. For existing strings a formula in an adjacent cell....... =HYPERLINK(cellref) ...

Insert hyperlink off and on ?
Why does the insert hyperlink drop down appear grayed out sometimes but at other times it works just fine. This is when I am doing a regular e-mail and want to highlight a term and insert a hyperlink. Outlook 2000. Just seems to have a mind of its own. ...

Hyperlink
I have successfully hyperlinked from a cell in Excel to a Visio file. Does anyone know how to link to a specific shape within the Visio file? The hyperlink can include page, shape, and zoom percent. Ex: http: //MyServer/MyDrawing.vsd#Page-2/Sheet.1?zoom=100 Visio will display the page, center the shape, and zoom to the given percent (but will not select the shape). Hope this helps, -- Bill K. Microsoft Corporation This posting is provided "AS IS" with no warranties, and confers no rights. "JD" <jd@tivo.com> wrote in message news:068301c350a0$badcfc60$a101280...

hyperlink problem
i have three columns that make up my pdf file names i.e. example: columnA=2010, columnB=03, columnC=33 (my file name is 20100333.pdf). i want to have a column that opens corresponding pdf files. moreover i would like the function to look up for the files in the same drive that my excel files relies on. i have all these in usb and i change many computers so each computer may give a different drive letter name to my usb. can i achieve something like that? p.s. i want to open the pdf file directly, not through the internet explorer. ...

Delete all Hyperlinks and Actions
Hi, Is there anyway to see and delete all Hyperlinks and Actions in one go? Thanks Only with vba code AFAIK -- john ATSIGN PPTAlchemy.co.uk Free PPT Hints, Tips and Tutorials http://www.pptalchemy.co.uk/powerpoint_hints_and_tips_tutorials.html "Cazzy123" wrote: > Hi, > > Is there anyway to see and delete all Hyperlinks and Actions in one go? > > Thanks ...

Associate Macros to a Hyperlink
I would like to associate a simple macro to a hyperlink so when click on the hyperlink, excel would go to a certain sheet and change its zoom. Can anyone help me on how to do it? Thank you MJO Hi you can use the worksheet_followhyperlink event to achieve this. E.g. put the following code in your worksheet module Private Sub Worksheet_FollowHyperlink(ByVal Target As Hyperlink) If Target.Range.Address = "$A$1" Then 'insert your code here End If End Sub The above will process your code if the hyperlink in cell A1 is invoked. HTH Frank Maria João Oliveira wrote: > I...

Blocked hyperlinks
After Ctrl-Click on hyperlinks in Office programs i get a message that the computer is blocked for this operation and that i should contact the admin (thats me). I am using Windows 7, Office 07, IE8 and Live Mail 09 (all with available updates). (I reinstalled Chrome but that didn't help. Saw a suggestion about that.) Got one suggestion to reinstall Office but have not tried that. Any easier suggestions? -- Peter L I had the same problem a few days ago. Try this procedure founded on the web: "Restore registry settings in the User Profile 1. Click Start, click Run...

A click or control click on a hyperlink in an e-mail goes nowhere
Why can't I folow a hyperlink with a click or a control-click? version of outlook? Which folder is the message in? -- Diane Poremsky [MVP - Outlook] Author, Teach Yourself Outlook 2003 in 24 Hours Need Help with Common Tasks? http://www.outlook-tips.net/beginner/ Outlook 2007: http://www.slipstick.com/outlook/ol2007/ Outlook Tips by email: dailytips-subscribe-request@lists.outlooktips.net Outlook Tips: http://www.outlook-tips.net/ Outlook & Exchange Solutions Center: http://www.slipstick.com Subscribe to Exchange Messaging Outlook newsletter: EMO-NEWSLETTER-SUBSCRIBE-REQUEST@PEACH...

Filtering Hyperlinks
Good day, I've linked excel data to a map. When I click the hyperlink (state) on the map it will highlight the cells I referenced. I would also like this data to filter. So, my question is - is there a way to setup auto filters to links. Example: If I have data in cells 1 - throught 1000, and I have a hyperlink on a map to hightlight cells 3, 6 9, 100, 1000 - is there a way I can develop a formula where only the data shows related to that hyperlink ...

Hyperlink
Is it possible to password a hyperlink? The main form hyperlinks to another form, but we need to have a password so that only selected users can hyperlink to this 2nd form. Thanks in advance for you help. -Marty ...

Pub 2003
After having just upgraded to 2003 from 2000, I attempted to upload a website I created (index_files and index), but it is also not uploading the hyperlinked files as it did in 2000. When viewed on the web, the hyperlinks have the URL of my documents file on my computer. What am I missing here? Gary The hyperlink should read something like; http://www.domainename.com/additionalpath etc. -- Don Vancouver, USA "Dr. Gary" <geedc@adelphia.net> wrote in message news:3aednV_0H5IUpY_cRVn-rw@adelphia.com... > After having just upgraded to 2003 from 2000, I attempted to up...

Dereferencing hyperlinks
I have a spreadsheet with a column FILLED with names. Each name has an attached mailto: hyperlink that contains the email address of the person named. I am trying to create two new columns - one with the person's name only, and the second with their email address only. I can not find a method of copying ONLY the hyperlink to a new cell. Can this be done? Thanks! Please cc responses to usenetq at yahoo dot com Hi see: http://www.mvps.org/dmcritchie/excel/buildtoc.htm -- Regards Frank Kabel Frankfurt, Germany "Usenet User" <usenetq@yahoo.com> schrieb im Newsbeitrag ...

Validating hyperlinks and text for hyperlink
I have an issue where I have hyperlinks that do not match the text that's shown for them. I think what happened is that someone copied the cells down and just changed the text, but not the hyperlink. Here is an example of the problem. Hyperlink displayed: www.microsoft.com Link coded: www.yahoo.com How can we validate which hyperlinks match and which ones don't? Thanks in advance. Barb Reinhardt Barb, The following code will put the each hyperlink's address next to the cell. And some other stuff which you can rem out. Insert four columns after your column of hyp...

HYPERLINK PROBLEM #2
I have set up several hyperlinks in a workbook to other workbooks on our work network When I press these links they put me in the correct workbooks but close the book that the links were in - I want it to stay open. Anyone any ideas? Jason Try changing something in that workbook before you click on the link. If excel thinks the file is dirty (changed since last save), then it won't close. jason wrote: > > I have set up several hyperlinks in a workbook to other workbooks on > our work network > When I press these links they put me in the correct workbooks but > close ...

Hyperlink removal
How to remove a hyperlink from an email message (to be sent) Right-click and select Remove Hyperlink. In Outlook 2002(XP) there's also the AutoCorrect Option that's a little square that floats nearby the link. Undo Hyperlink is on the pull down menu. -j >-----Original Message----- >How to remove a hyperlink from an email message (to be >sent) >. > Thanks J, I should have stated I am using Outlook 98 and it doesn't have a remove option that I can find. >-----Original Message----- >Right-click and select Remove Hyperlink. In Outlook >2002(XP) there&...

Hyperlinks stopped working in Outlook 2007
I am using Outlook 2007 with Windows 7. Recently, hyperlinks in emails will no longer open - I have to copy and paste into a browser. I remember reading a fix for this, but now I can't find it. see http://www.slipstick.com/problems/link_restrict.htm -- Peter Please Reply to Newsgroup for the benefit of others Requests for assistance by email can not and will not be acknowledged. "Ariel" <Ariel@discussions.microsoft.com> wrote in message news:8A8ACA2E-DB89-4D20-BE34-A7DFDC9FE7D1@microsoft.com... >I am using Outlook 2007 with Windows 7. Recently, ...

Multiple hyperlinks
I have multiple files that i want to put a hyperlink to. Rather than doing it one by one, is there a quick way to just automatically add a hyperlink to all files? To make it easier for someone to help you a few examples of what you want to link to would be helpful, fortunately you can probably find your an answer on one of my pages. http://www.mvps.org/dmcritchie/excel/sheets.htm#hyperlink and perhaps a solution something like: =HYPERLINK("file://x:/mywebsite/dmcritchie/excel/" & A6 & ".htm",A6) or something like http://www.mvps.org/dmcritc...