Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Tony,
I found the worksheet functions you mentioned, but I'm creating a user form and I can't find anything like that in the VBA help files Is there away to send the text from a text box to the worksheet, do the conversion and then retrieve the answer back to the user form, Something like cell A1 = txtInput and then lblAnswer = A1 after excel calculates the answer Julie "acw" wrote in message ... Julie Excel has a builtin function for this: HEX2BIN. There is also HEX2DEC and HEX2OCT. Tony -----Original Message----- Does anyone know where I might find a VBA routine that would convert Hex to Binary. I'm trying to build a userform that has several different conversions and I can do most of the temperature, distance and these kinds of things, but when it comes to the conversions I have been at it for almost a week and I have a huge macro that is really clunky and I'm not finished yet. Any help please Thanks Julie . |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Julie,
There is no need to use a worksheet cell to evaluate Hex2Bin. Hex2Bin is part of the Analysis ToolPak and can be referenced directly in VBA if you create a reference to the ToolPak. In the VB Editor, use Tools|References and check the item named atpvbaen.xls. -- John Green - Excel MVP Sydney Australia "JulieJulie" wrote in message ink.net... Tony, I found the worksheet functions you mentioned, but I'm creating a user form and I can't find anything like that in the VBA help files Is there away to send the text from a text box to the worksheet, do the conversion and then retrieve the answer back to the user form, Something like cell A1 = txtInput and then lblAnswer = A1 after excel calculates the answer Julie "acw" wrote in message ... Julie Excel has a builtin function for this: HEX2BIN. There is also HEX2DEC and HEX2OCT. Tony -----Original Message----- Does anyone know where I might find a VBA routine that would convert Hex to Binary. I'm trying to build a userform that has several different conversions and I can do most of the temperature, distance and these kinds of things, but when it comes to the conversions I have been at it for almost a week and I have a huge macro that is really clunky and I'm not finished yet. Any help please Thanks Julie . |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Just to add to John's answer, unlike worksheet functions, since this is an
addin, after creating the reference, you would call it just like a vba function - no Application.Hex2Bin or worksheetFunction.Hex2Bin You can also not create the reference and use ? Application.run("ATPVBAEN.XLA!Hex2Bin","FB") 11111011 As an example from the immediate window. and with the reference set: ? Hex2Bin("FB") 11111011 -- Regards, Tom Ogilvy "John Green" wrote in message ... Julie, There is no need to use a worksheet cell to evaluate Hex2Bin. Hex2Bin is part of the Analysis ToolPak and can be referenced directly in VBA if you create a reference to the ToolPak. In the VB Editor, use Tools|References and check the item named atpvbaen.xls. -- John Green - Excel MVP Sydney Australia "JulieJulie" wrote in message ink.net... Tony, I found the worksheet functions you mentioned, but I'm creating a user form and I can't find anything like that in the VBA help files Is there away to send the text from a text box to the worksheet, do the conversion and then retrieve the answer back to the user form, Something like cell A1 = txtInput and then lblAnswer = A1 after excel calculates the answer Julie "acw" wrote in message ... Julie Excel has a builtin function for this: HEX2BIN. There is also HEX2DEC and HEX2OCT. Tony -----Original Message----- Does anyone know where I might find a VBA routine that would convert Hex to Binary. I'm trying to build a userform that has several different conversions and I can do most of the temperature, distance and these kinds of things, but when it comes to the conversions I have been at it for almost a week and I have a huge macro that is really clunky and I'm not finished yet. Any help please Thanks Julie . |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
BIN2DEC conversion for large binary numbers | Excel Worksheet Functions | |||
decimal to binary conversion | Excel Worksheet Functions | |||
Binary NOT? | Excel Worksheet Functions | |||
decimal to 16 bits binary conversion in Excel? | Excel Worksheet Functions | |||
Solver returns non binary answer in binary constrained cells | Excel Worksheet Functions |