TweetFollow Us on Twitter

Extend Excel
Volume Number:6
Issue Number:1
Column Tag:Intermediate Mac'ing

Extending Excel

By Vincent Parsons, Austin, TX

Note: Source code files accompanying article are located on MacTech CD-ROM or source code disks.

Vincent Parsons is a junior in the Science Academy at LBJ High School in Austin, Texas. He has experience in MacApp, HyperCard, SuperCard, and C, and when he’s not in school or programming, he runs a Role Playing Game Bulletin Board System. He would appreciate feedback on this article and would like to hear from anyone having success implementing DLLs. He can be reached at AppleLink D1977.

A Little History

In November of 1988, an associate of mine attended the Microsoft Excel Developers Conference. He returned with news that users of Excel for Windows 2.1 (and Excel 2.2 for the Macintosh at its release) have the ability to extend Excel using Dynamic Link Libraries (DLLs). DLLs are dynamically linked external functions that can be called directly from Excel macros.

The introduction of DLLs on the Mac opens up new markets for Macintosh programmers, letting them use the Macintosh’s superior development environments, and then with very little effort bring the same products to the MSDOS environment. For this reason, I am discussing development of DLLs for Windows in conjunction with development of DLLs on the Macintosh.

Microsoft Blues

I began investigating how to implement DLLs using the documentation my associate had received at the conference. Soon I had written several very simple DLLs for Windows. To my surprise very few worked correctly (two even crashed Windows). After much correspondence with Microsoft Technical Support, who informed me that my problems were due to bugs internal to Excel, I concluded that much of Microsoft’s documentation on DLLs was incorrect.

I began using a trial subscription of Microsoft OnLine, Microsoft’s technical support service. While response turn-around was usually fast, all too often the answer was unacceptable. Answers were typically an acknowledgement that the problem was internal to Excel. In fact, I was unable get a definite commitment that the problems would be fixed within a reasonable time period (‘the next release’ is not satisfactory), nor did Microsoft provide any work-arounds for Excel’s problems. When asked about programming DLLs for Macintosh Excel 2.2 (in beta test at that time), they stated that technical support could not support unreleased products. My feeling is that, at least for this project, the $600 fee for one year of support would not have been justified. When compared to Apple’s excellent technical support provided through AppleLink (at a similar yearly rate), Microsoft’s technical support has a long way to go to reach the standards Macintosh programmers expect.

Since I was reporting bugs, sending corrections to their documentation, and getting little true support, I suggested that they send me an Excel T-Shirt as some compensation for my toil. After some ribbing, Technical Support finally responded telling me that since they currently didn’t have a T-Shirt program they would pass the suggestion on to a supervisor.

When Macintosh Excel 2.2 was released, I was appalled to discover that the documentation for it was incorrect also. In fact, the Macintosh version of the Functions and Macros manual refers to those arcane MSDOS far pointers!

Actually, most forms of DLLs do work, but not as documented in the published manuals. In this article, I will document how to implement DLLs in both the Macintosh and Windows environments using as much common source code as possible.

So What Are They Really?

DLLs on the Macintosh are very similar to HyperCard’s XFCNs. They are CODE resources in their own type of file. The main difference between DLLs and XFCNs is that Excel DLLs have no call-back routines -- the only data to which the DLL has access is what was passed to it. DLLs don’t have access to conversion routines such as those in HyperCard.

Nearly anything thing modal can be done using DLLs. Custom functions can be created giving Excel increased functionality. An example of this is complex arithmetic. DLLs also have full access to the Macintosh or Windows toolbox. The possibilities are endless.

The Excel Side

There are three macro functions that Excel uses to access DLLs -- Register, Call, and Unregister. For an example of a macro (SampAAA, discussed later), see figure 1. The Register function for the sample macro is contained in cell A2. The full macro and spread sheets are included on the source disk.

• Register

The Register function loads the DLL’s code into memory. The syntax of Register for Excel for the Macintosh is:

/* 1 */

Register(file_name, resource_name, argument_text)

or for Excel for Windows:

Register(file_name, function_name, argument_text)

The file_name is the name of the file containing the DLL code resources. On the Macintosh, resource_name is the name of the CODE resource of the DLL you wish to execute. Under Windows, however, function_name is the name of the exported function of the DLL. The argument_text specifies the number and data types of the arguments to the function and the data type of the return value. The argument_text is a series of letter codes A-K. The letters A-K specify different data types (see figures 2 and 3). The first letter of the argument_text determines the return value data type of the function. All following letters are argument data types to be passed to the DLL at execution. The Register function returns an ASCII representation of the address of the DLL code with the argument_text appended to the end. For example, the following Register function would open a file named “SampDLLs”, load the CODE resource named “SampAAA” into memory, and, when executed, would be passed two Booleans (type A) and return a Boolean:

`2
=Register(“SampDLLs”,“SampAAA”,“ AAA”)

• Call

The Call function executes the DLL code contained in the memory allocated by the Register function. The syntax of the Call function is:

`3
Call(register_return_value, argument1,  )

The register_return_value is a reference to the return-value of the Register function. Is is possible, though it is not recommended, to put the Register function inside the Call function instead of using a reference. There are several reasons not to use this technique: it makes execution slower if that DLL is to be executed more than once, it makes the Unregister function useless, and it is bad memory management. The arguments are the values to be passed to the DLL. For example, the following Call function calls the DLL defined in the previous Register example (contained in cell A2 of the macro sheet):

`4
=Call(A2, true, false)

or

`5
=Call(Register(“SampDLLs”,“SampAAA”,“AAA”),true,false)

• Unregister

The Unregister function releases the memory allocated by the Register function. The Unregister function is not a part of Excel for Window 2.1, so, if you’re developing DLLs on both platforms, don’t put Unregister in your macro sheets on the Windows version. The reason for using the Unregister function is for memory management. You should unregister any DLLs that you are done with -- it is a good idea to put the Unregister functions in an auto-close autoexecing macro. The syntax of Unregister is:

`6

Unregister(register_return_value)

The register_return_ value is the same as that for the Call function. For example, 
the following Unregister function releases the memory allocated by the previous Register 
example (contained in cell A2 of the macro sheet).

`7

=Unregister(A2) 

• Macro Sheet Tips

Since Excel documents have the same file format for both the Macintosh and Windows, creating multi-platform macro sheets is easy. Since the file formats are the same, if you make your macro sheets have the extension .XLM, your spread sheets the extension .XLS, and your workspace documents the extension of .XLW, conversion becomes as easy as copying your Excel documents to a PC disk. Remember, if your DLLs are to be used under Windows, be sure to omit the Unregister function from the macro sheet.

Programming DLLs

I will discuss developing DLLs using three development environments: MPW C 3.0 and THINK C 4.0 for the Macintosh, and Microsoft C 5.1 for MSDOS. Programming DLLs is done differently for each of these development systems. For the same source code to be used, conditional compiling becomes necessary. To implement the conditional compiles, I used the predefined preprocessor symbols THINK_C (for THINK C 4.0), applec (for MPW C 3.0), and MSDOS (for Microsoft C 5.1). I will discuss the required differences in the following sections.

• THINK C 4.0

THINK C 4.0 has advantages and disadvantages for creating DLLs. The biggest disadvantage is that each DLL requires its own project. One advantage, however, is that THINK C, unlike MPW C, allows the use of global variables (don’t forget to call RememberA0, SetUpA4, and RestoreA4). Unlike MPW and Microsoft C which define a 64-bit float to be a double, THINK C defines it as a short double. For portability reasons, it is necessary to define a double64 (see the header file DLL.h).

Another difference is that since THINK C automatically includes many standard precompiled headers, #include statements usually aren’t necessary. One inconvenience is that entry points must be named main. In MPW C, for example, the entry point can be set to any function. Also, the code resources created by THINK C are 1 1/2 to 2 times larger than those created by MPW C.

After creating your project, select Set Project Type from the Project menu, and THINK C will open a dialog (see figure 4). DLLs are code resources of type ‘CODE’, the file type and creator need to be set to ‘XLLB’ and ‘XCEL’ respectively, and Microsoft suggests that the purgeable attribute be set (20 hex). Finally set the name for the DLL and choose a unique resource ID.

Note to users of THINK C 3.1:

Since THINK C 3.1 doesn’t have the ability to put a newly created code resource into an existing file, combining DLLs into one file requires the use of ResEdit. Also, for compatibility reasons, the THINK C portions of the source code use old style function declarations since THINK C 3.1 does not support new style function declarations.

• MPW C 3.0

If you plan to develop a library of DLLs for the Macintosh, MPW C 3.0 is by far the best development environment for such a task. Although globals are not allowed when building code resources with the MPW linker, MPW has many advantages. First, using one make file, you can automatically build your entire library of DLLs and put them into the same file (or different files) in one step without using ResEdit. Also, due to MPW C’s ability to define the entry point of the CODE resource to be any function, the DLL functions don’t all need to be named main. Since MPW C doesn’t automatically include standard headers, Types.h at minimum must be included.

Certain compile and link options are very important when creating DLLs (see SampDLLs.make). When compiling, be sure to use the -b option if you use any string or floating-point constants. This is because MPW C normally stores string and floating-point constants in the global data area, and when compiling DLLs with MPW C, there isn’t a global data area. Use the -t and -c options to set the file type to ‘XLLB’ and the creator to ‘XCEL’. Though it is not required, it is a good idea to use the -ra option to set the resource’s purgeable attribute. The -sg option lets you name the resource (this name is used in the Register function), and the -rt option lets you set the resource type (CODE) and a unique resource ID. Also, when linking DLLs, the -m option must be used to set the entry point. Since DLLs are declared as pascal-style functions, remember to put the function name after the -m option in all capital letters. Finally, use the -o option to define the object file be used.

• Microsoft C 5.1

Microsoft C 5.1 is the DOS compiler I used to create DLLs. DLLs for Windows are executable files (.exe extension) that contain one or more entry points. In addition to a make file (See SAMPDLLS.MAK), Microsoft C requires a module definition file (See SAMPDLLS.DEF).

In the definition file, several module statements are required. The LIBRARY statement provides the name for the library of DLLs. The DESCRIPTION string is often useful for embedding source-control or copyright information, though any ASCII string is allowed. The STUB statement sets the program to be executed if the DLL is executed outside of Windows. WINSTUB.EXE simply displays the string “This program requires Microsoft Windows,” and then quits. Set the CODE statement to MOVEABLE. This allows Windows to perform memory management better. Set the DATA statement to FIXED SINGLE. Since many of the argument types are passed as pointers, moving the data segment would make the pointers invalid. DLLs require a single data segment. The HEAPSIZE module statement sets the local heap size. The maximum heap size is 65,536 bytes. For most simple DLLs, 4096 bytes is satisfactory. The STACKSIZE module statement sets the size of the local stack. Since DLLs use Excel’s stack, be sure to set this value to 0. After the Exports statement, list all the DLL functions by name.

The make file executes four programs: implib (the library importer), cl (the Microsoft C compiler/linker), lib (library manager), and link4 (the Windows linker). The backslash (\) is the Microsoft’s make file continuation character. Implib converts the definition file into an import library needed for link4.

Several options are used with the Microsoft C compiler/linker. The -c option tells the compiler to create only object files, and not do any linking. This is because link4 must be used to link DLLs. The /D option defines the THINK_C and applec preprocessor symbols to false. The -Gs option removes stack probes, and the -As and -An options tell the compiler to use the small memory model and to use near pointers. The options -Gw and -Aw are required for Windows.

Since MSDOS allows command lines to be only 128 characters, it was necessary to combine the object files into two libraries, and then to link those libraries. If only a few object files are being linked, building the libraries is not required.

It is necessary to use the /a:16 option with link4. This aligns the code on word boundaries. The /NOE option prevents link4 from searching the libraries extended dictionary. The files win87em, swindlibc, and slibw are library files that need to be linked with the DLL. The extra comma is a placeholder for a map file. Finally, in order to do any development of DLLs with Microsoft C, Microsoft C 5.1 and the latest Microsoft Windows Software Development Kit need to be obtained.

Sample DLLs

I have provided several sample DLLs demonstrating all of the argument data types and various techniques. All of the samples will compile under either MPW C 3.0 or THINK C 4.0, and nearly all will also compile under Microsoft C 5.1. Most of the samples’ names end with the argument_text used for the Register function.

• SampAAA

The SampAAA DLL demonstrates the use of Boolean arguments. Booleans in DLLs are unsigned shorts -- zero if false, any other number if true. The function of this DLL is to return the logical AND of the two Boolean values passed in.

• SampBBB

The SampBBB DLL demonstrates the use of type B (double64) arguments. On the Macintosh, type B is passed as a pointer to a double64, and returns a pointer to a double64. Under Windows, type B is passed as a double64 value, and returns a far pointer to a double64. The reason for the difference is that the pascal convention on the Macintosh is to pass a pointer for anything larger than four bytes. The function of this DLL is to return the double64 product of the two double64s passed in.

Under Windows, a static double64 variable (answer) is allocated on the stack and is available to Excel after the completion of the DLL. Since statics are not allowed on the Macintosh, the answer is put into the area pointed to by one of the input parameters. When the parameter is returned, the pointer is still valid, giving Excel access to the return value. For this reason, type B return values are only possible on the Macintosh if you have a type B input parameter.

• SampCC and SampDD

The SampCC and SampDD DLLs demonstrate the use of type C (zero-terminated string) and type D (byte-count string) arguments. On the Macintosh, type C and D are passed in and out as a char *. Under Windows, type C and D are passed in and out as a char far *. The function of these two DLLs is to switch the case of each character of the input string and return the modified string to Excel.

• SampEIIE

The SampEIIE DLL demonstrates the use of type E (64-bit floating-point number buffer) arguments. The type E data type is only useful for return values. For a return value of type E, it is required to have a input value of type E. The input type E is also used to allocate Excel memory to hold the output value -- whatever is passed in the Call function is ignored. On the Macintosh, type E is passed as a pointer to a double64, and returns a pointer to a double64. Under Windows, type E is passed as a pointer to a double64 value, and returns a double64. The function of the DLL is to return the quotient of the two shorts (type I, see below) passed in.

• SampFHF and SampGHG

The SampFHF and SampGHG DLLs demonstrate the use of type F (zero-terminated string) and type G (byte-count string) argument types. The type F and G data types are only useful for return values. For a return value of type F or G, it is required to have a input value of type F or G. The input types F and G are used to allocate Excel memory to hold the output value -- whatever is passed in the Call function is ignored. On the Macintosh, types F and G are passed to and from the DLL as a char *. Under Windows, types F and G are passed as a char far *. The function of the DLL is to return a hex representation of the unsigned short (type H, see below) passed in.

• SampHHH

The SampHHH DLL demonstrates the use of type H (unsigned short -- a 16-bit integer) argument type. Type H is passed to and returned on both the Macintosh and under Windows as an unsigned short. The function of the DLL is to return the product of the two unsigned shorts passed in.

• SampIII

The SampIII DLL demonstrates the use of type I (short -- a 16-bit integer) argument type. Type I is passed to and returned on both the Macintosh and under Windows as a short. The function of the DLL is to return the product of the two shorts passed in.

• SampJJ

The SampJJ DLL demonstrates the use of the type J (unsigned long -- a 32-bit integer) argument type. Type J is passed to and returned from the DLL on both the Macintosh and under Windows as an unsigned long. The function of the DLL is to return the lower 16 bits of the unsigned long passed in.

• SampKKK

The SampKKK DLL demonstrates the use of the type K (floating-point array) argument type. On the Macintosh, type K is passed to and from the DLL as a pointer to the following structure:

/* 8 */

typedef struct fp {
 unsigned short rows;
 unsigned short columns;
 double64 array[n];
} FP;

/* The first short contains number of rows,     */
/* the second short contains number of columns. */
/* These are followed by rows times columns of  */
/* IEEE double64s.                              */

Under Windows, type K is passed to and from the DLL as a far pointer to a structure (see above). The function of this DLL is to input two complex numbers (1x2 arrays) and return their product.

• Flash

My final sample that works both in the Macintosh and under Windows is a DLL version of our favorite sample XCMD, Flash. Flash demonstrates the use of using toolbox functions in both the Macintosh and Windows environments (Yes, Flash even works under Windows!!!). Since Flash doesn’t really require a return value, I chose to return a simple Boolean. Flash is passed a short (type I), and flashes the current GrafPort that many times.

• SampMem

SampMem is to be used only on a Macintosh. SampMem demonstrates a technique used by many HyperCard XCMDs. This technique allows the creation of a handle that can be used by any DLL simply by passing an unsigned long representation of that handle to each DLL that needs to use it. SampMem is passed two arguments: an opcode (short) and an unsigned long. If the opcode is 0, SampMem creates a handle, casts that handle to an unsigned long, and then returns the unsigned long. It initializes the handle to the unsigned long parameter. If the opcode is 1, SampMem casts the incoming unsigned long to a handle, increments an unsigned long stored in the handle, and returns the current value of the unsigned long in the handle. If the opcode is 3, SampMem casts the incoming unsigned long to a handle and disposes the handle. To prevent unwanted execution of this DLL, in the sample spreadsheet, a space has been put in front of the macro function call. To execute it, remove the space and click the check box. I would suggest that you put a call with opcode 0 in an auto-open macro, and a call with opcode 2 in an auto-close macro. This will make sure that the handle is created and disposed of at the correct time.

Closing Thoughts

DLLs have desperately needed correct documentation with useful examples for a long time. I hope that I have provided for that need in this article. I would like to thank Andrew Donoho for introducing me to DLLs and my father, Ron Parsons, for his help and support. One thing still bugs me though -- I still don’t have an Excel T-Shirt.

/************************************************/
/*                  Sample DLL’s                */
/*       Copyright © Vincent Parsons 1989.      */
/************************************************/
/*    DLL code for MPW C 3.0 or THINK C 4.0     */
/*       with Excel for the Macintosh 2.2       */
/*             and Microsoft C 5.1              */
/*          with Excel for Windows 2.1          */
/************************************************/

/*  File DLL.h  */

#ifndef _DLLDEF_

#define _DLLDEF_

#if THINK_C
#define double64 short double
#elif applec|MSDOS
#define double64 double
#endif

#endif

/************************************************/
/* SampAAA is an example of two data type A     */
/* inputs and one data type A output.  The      */
/* output is the logical AND of the two inputs. */
/************************************************/
/*   =REGISTER(“SampDLLs”,”SampAAA”,”AAA”)      */
/*   for both the Mac and the PC.               */
/************************************************/

#include “DLL.h”

#if applec
#include <Types.h>

#elif MSDOS
#include <windows.h>

#endif

#if THINK_C
pascal unsigned short main(unsigned short b1,
 unsigned short b2); /* prototype */

pascal unsigned short main(b1, b2)
unsigned short b1;
unsigned short b2;

#elif applec
pascal unsigned short SampAAA(unsigned short b1,
unsigned short b2)

#elif MSDOS
unsigned short far pascal SampAAA(
 unsigned short b1, unsigned short b2)
#endif
{
 /* Returned parameter is the logical AND of
 the two inputs */
 return (b1 & b2);
}
/************************************************/
/* SampBBB is an example of two data type B     */
/* inputs and one data type B output.  The      */
/* output is the product of the two inputs.     */
/************************************************/
/*   =REGISTER(“SampDLLs”,”SampBBB”,”BBB”)      */
/*   for both the Mac and the PC.               */
/************************************************/
/* 
   Note that the floating point numbers 
   are passed as double64 * on the Mac and 
   double64 on the PC.
   
   The function type is pascal double64 * on the 
   Mac and double64 far * far pascal on the PC.
   
   On the Mac the returned value is d1 (a pointer 
   to the double64 result) and the answer has been 
   stored in the Excel buffer used by the input 
   variable.
   
   On the PC the answer is stored in a static 
   variable and the returned value is a pointer 
   to that static value.
   
   This was done so the REGISTER command is the 
   same in the PC and the Mac.
*/
/************************************************/

#include “DLL.h”

#if applec
#include <Types.h>

#elif MSDOS
#include <windows.h>

#endif

#if THINK_C
pascal double64 * main(double64 * d1, double64 * d2);
 /* prototype */

pascal double64 * main(d1, d2)
double64 * d1;
double64 * d2;

#elif applec
pascal double64 * SampBBB(double64 * d1, double64 * d2)

#elif MSDOS
double64 far * far pascal SampBBB(double64 d1,
 double64 d2)
#endif
{
#if applec | THINK_C
 double64 answer;
 
 /* Returned parameter is the product of the two inputs */
 answer = *d1 * *d2;
 *d1 = answer; /* Store value in Excel data
 buffer since static */
 return ( d1 );  /* variables are not
 permitted in Mac code resources */

#elif MSDOS
 static double64 answer;
 
 /* Returned parameter is the product of the two inputs */
 answer = d1 * d2;
 return ( (double64 far *)&answer );

#endif
}

/************************************************/
/* SampCC is an example of one data type C      */
/* input and one data type C output.  The       */
/* output has all upper case letters converted  */
/* to lower case and vice versa.  The answer    */
/* has been stored in the Excel buffer used by  */
/* the input variable.                          */
/************************************************/
/*   =REGISTER(“SampDLLs”,”SampCC”,”CC”)        */
/*   for both the Mac and the PC.               */
/************************************************/

#include “DLL.h”

#if applec
#include <Types.h>

#elif MSDOS
#include <windows.h>

#endif

#if THINK_C
pascal char * main(char * c1);/* prototype */

pascal char * main(c1)
char * c1;

#elif applec
pascal char * SampCC(char * c1)

#elif MSDOS
char far * far pascal SampCC(char far * c1)
#endif
{
 short i = 0;
 
 while ( c1[i] != ‘\0’ ) {/* C String */
 if ((c1[i] >= ‘A’) && (c1[i] <= ‘Z’))
 c1[i] += 32;
 else if ((c1[i] >= ‘a’) && (c1[i] <= ‘z’))
 c1[i] -= 32;
 i++;
 }
 
 return (c1);
}

/************************************************/
/* SampDD is an example of one data type D      */
/* input and one data type D output.  The       */
/* output has all upper case letters converted  */
/* to lower case and vice versa.  The answer    */
/* has been stored in the Excel buffer used by  */
/* the input variable.                          */
/************************************************/
/*   =REGISTER(“SampDLLs”,”SampDD”,”DD”)        */
/*   for both the Mac and the PC.               */
/************************************************/

#include “DLL.h”

#if applec
#include <Types.h>

#elif MSDOS
#include <windows.h>

#endif

#if THINK_C
pascal char * main(char * c1);/* prototype */

pascal char * main(c1)
char * c1;

#elif applec
pascal char * SampDD(char * c1)

#elif MSDOS
char far * far pascal SampDD(char far * c1)
#endif
{
 short i = 1;
 
 while ( i <= c1[0] ) { /* P String */
 if ((c1[i] >= ‘A’) && (c1[i] <= ‘Z’))
 c1[i] += 32;
 else if ((c1[i] >= ‘a’) && (c1[i] <= ‘z’))
 c1[i] -= 32;
 i++;
 }
 
 return (c1);
}

/************************************************/
/* SampEIIE is an example of two data type I    */
/* inputs and one data type E output.  The      */
/* output is the quotient of the two inputs.    */
/* A type E parameter is used to reserve space  */
/* for the returned value.                      */
/************************************************/
/*   =REGISTER(“SampDLLs”,”SampEIIE”,”EIIE”)    */
/*   for both the Mac and the PC.               */
/************************************************/
/* 
   A type E parameter is used to reserve storage
   space in an Excel data buffer for use by the
   DLL.  No data is actually passed as type E.
   
   The function type is pascal double64 * on the 
   Mac and double64 far * far pascal on the PC.
   
   On the Mac the returned value is d1 (a pointer 
   to the double64 result) and the answer has 
   been stored in the Excel buffer reserved by 
   the input variable.
   
   On the PC the returned value is d1 (a double64
   result) and the answer has been stored in the 
   Excel buffer reserved by the input variable.
   
   This was done so the REGISTER command is the 
   same in the PC and the Mac.
*/
/************************************************/

#include “DLL.h”

#if applec
#include <Types.h>

#elif MSDOS
#include <windows.h>

#endif

#if THINK_C
pascal double64 * main(short i1, short i2, double64 * d1);
 /* prototype */

pascal double64 * main(i1, i2, d1)
short i1;
short i2;
double64 * d1;

#elif applec
pascal double64 * SampEIIE(short i1, short i2,
 double64 * d1)

#elif MSDOS
double64 far pascal SampEIIE(short i1, short i2,
 double64 * d1)
#endif
{
 double64 answer;
 
 /* Returned parameter is the quotient of the
 two inputs */
 answer = (double64)i1/(double64)i2;
 *d1 = answer; /* Store value in Excel data buffer */
 
#if applec | THINK_C
 return ( d1 );
#elif MSDOS
 return ( (double64) *d1 );
#endif
}

/************************************************/
/* SampFHF is an example of one data type H     */
/* input and one data type F output.  The       */
/* output is the ASCII hex representation of    */
/* the type H input.  The answer has been       */
/* stored in the Excel buffer reserved by the   */
/* type F input variable.                       */
/************************************************/
/*   =REGISTER(“SampDLLs”,”SampFHF”,”FHF”)      */
/*   for both the Mac and the PC.               */
/************************************************/

#include “DLL.h”

#if applec
#include <Types.h>

#elif MSDOS
#include <windows.h>

#endif

#if THINK_C
pascal char * main(unsigned short u1, char * c1);
 /* prototype */

pascal char * main(u1, c1)
unsigned short u1;
char * c1;

#elif applec
pascal char * SampFHF(unsigned short u1, char * c1)

#elif MSDOS
char far * far pascal SampFHF(unsigned short u1,
 char far * c1)
#endif
{
 short i;
 
 for (i = 3; i >= 0; i--) {/* C String */
 c1[i] = u1 & 0xF; /* Get nibble */
 if (c1[i] <= 9) c1[i] += ‘0’;
 else c1[i] += 55; /* Make ASCII hex */
 u1 = u1 >> 4;   /* Get next nibble */
 }
 c1[4] = 0;
 
 return (c1);
}

/************************************************/
/* SampGHG is an example of one data type H     */
/* input and one data type F output.  The       */
/* output is the ASCII hex representation of    */
/* the type H input.  The answer has been       */
/* stored in the Excel buffer reserved by the   */
/* type F input variable.                       */
/************************************************/
/*   =REGISTER(“SampDLLs”,”SampGHG”,”GHG”)      */
/*   for both the Mac and the PC.               */
/************************************************/

#include “DLL.h”

#if applec
#include <Types.h>

#elif MSDOS
#include <windows.h>

#endif

#if THINK_C
pascal char * main(unsigned short u1, char * c1);
 /* prototype */

pascal char * main(u1, c1)
unsigned short u1;
char * c1;

#elif applec
pascal char * SampGHG(unsigned short u1,
 char * c1)

#elif MSDOS
char far * far pascal SampGHG(unsigned short u1,
 char far * c1)
#endif
{
 short i;
 
 for (i = 4; i > 0; i--) {/* P String */
 c1[i] = u1 & 0xF; /* Get nibble */
 if (c1[i] <= 9) c1[i] += ‘0’;
 else c1[i] += 55; /* Make ASCII hex */
 u1 = u1 >> 4;   /* Get next nibble */
 }
 c1[0] = 4;
 
 return (c1);
}

/************************************************/
/* SampHHH is an example of two data type H     */
/* inputs and one data type H output.  The      */
/* output is the product of the two type H      */
/* inputs.                                      */
/************************************************/
/*   =REGISTER(“SampDLLs”,”SampHHH”,”HHH”)      */
/*   for both the Mac and the PC.               */
/************************************************/

#include “DLL.h”

#if applec
#include <Types.h>

#elif MSDOS
#include <windows.h>

#endif

#if THINK_C
pascal unsigned short main(unsigned short u1,
 unsigned short u2);
 /* prototype */

pascal unsigned short main(u1, u2)
unsigned short u1;
unsigned short u2;

#elif applec
pascal unsigned short SampHHH(unsigned short u1,
 unsigned short u2)

#elif MSDOS
unsigned short far pascal SampHHH(
 unsigned short u1, unsigned short u2)
#endif
{
 return ( u1 * u2 );
}

/************************************************/
/* SampIII is an example of two data type I     */
/* inputs and one data type I output.  The      */
/* output is the product of the two type I      */
/* inputs.                                      */
/************************************************/
/*   =REGISTER(“SampDLLs”,”SampIII”,”III”)      */
/*   for both the Mac and the PC.               */
/************************************************/

#include “DLL.h”

#if applec
#include <Types.h>

#elif MSDOS
#include <windows.h>
#endif

#if THINK_C
pascal short main(short u1, short u2);
 /* prototype */

pascal short main(u1, u2)
short u1;
short u2;

#elif applec
pascal short SampIII(short u1, short u2)

#elif MSDOS
short far pascal SampIII(short u1, short u2)
#endif
{
 return ( u1 * u2 );
}

/************************************************/
/* SampJJ is an example of one data type J      */
/* input and one data type J output.  The       */
/* output is the lower 16 bits of the type J    */
/* input.                                       */
/************************************************/
/*   =REGISTER(“SampDLLs”,”SampJJ”,”JJ”)        */
/*   for both the Mac and the PC.               */
/************************************************/

#include “DLL.h”

#if applec
#include <Types.h>

#elif MSDOS
#include <windows.h>

#endif

#if THINK_C
pascal unsigned long main(unsigned long u1);
 /* prototype */

pascal unsigned long main(u1)
unsigned long u1;

#elif applec
pascal unsigned long SampJJ(unsigned long u1)

#elif MSDOS
unsigned long far pascal SampJJ(unsigned long u1)
#endif
{
 return ( u1 & 0x0000FFFF );
}

/************************************************/
/* SampKKK is an example of two data type K     */
/* inputs and one data type K output.  The      */
/* output is the complex product of the         */
/* two type K inputs intrepreted as complex     */
/* numbers.                                     */
/************************************************/
/*   =REGISTER(“SampDLLs”,”SampKKK”,”KKK”)      */
/*   for both the Mac and the PC.               */
/************************************************/
/*
   Note that the complex number is passed
   as FP * c1 on the Mac and on the PC.

   The function type is pascal FP * on the Mac
   and FP far * far pascal on the PC.

   On the Mac the returned value is c1 (the
   pointer to the FP result) and the answer
   has been stored in the Excel buffer used
   by the input variable.

   On the PC the answer is stored in a static
   variable and the returned value is a pointer
   to that static value.

   This was done so the REGISTER command was
   the same in the PC and the Mac.
*/
/************************************************/

#include “DLL.h”

typedef struct fp {
 unsigned short rows;
 unsigned short columns;
 double64 array[2];
} FP;

#if applec
#include <Types.h>

#elif MSDOS
#include <windows.h>

#endif

#if THINK_C
pascal FP * main(FP * k1, FP * k2);
 /* prototype */

pascal FP * main(k1, k2)
FP * k1;
FP * k2;

#elif applec
pascal FP * SampKKK(FP * k1, FP * k2)

#elif MSDOS
FP far * far pascal SampKKK(FP far * k1, FP far * k2)
#endif
{
#if applec | THINK_C
 FP answer; /* Automatic variable */
#elif MSDOS
 static FP answer;
#endif

 answer.array[0] =
 (k1->array[0] * k2->array[0]) -
 (k1->array[1] * k2->array[1]);
 answer.array[1] =
 (k1->array[0] * k2->array[1]) +
 (k1->array[1] * k2->array[0]);
 answer.rows = k1->rows;
 answer.columns = k1->columns;

#if applec | THINK_C
 * k1 = answer;
/*Store value in Excel data buffer since static*/
/*variables not permitted in MPW code resources*/
 return ( k1 );
#elif MSDOS
 return( (FP far *)&answer );
#endif
}

/************************************************/
/* Flash is an example of direct manipulation   */
/* of the screen from a DLL. The DLL inverts    */
/* the window rectangle twice the input         */
/* parameter times.                             */
/************************************************/
/*   =REGISTER(“SampDLLs”,”Flash”,”AI”)         */
/*   for both the Mac and the PC.               */
/************************************************/

#ifdef applec

#include <Types.h>
#include <Memory.h>
#include <OSUtils.h>
#include <QuickDraw.h>

#elif MSDOS
#include <windows.h>

#endif

#ifdef THINK_C
pascal unsigned short main(short flashCount);
 /* prototype */

pascal unsigned short main(flashCount)
short flashCount;

#elif applec
pascal unsigned short Flash(short flashCount)

#elif MSDOS
unsigned short far pascal Flash(short flashCount)
#endif
{
 short  again;
#if THINK_C | applec
 GrafPtrport;
 
 GetPort(&port);
 for (again = 1; again <= flashCount; again++)
 {
 InvertRect(&port->portRect);
 InvertRect(&port->portRect);
 }
#elif MSDOS 
 HWND myWindowHandle;
 HDC  myDisplayContext;
 RECT myRect;
 
 myWindowHandle = GetActiveWindow();
 myDisplayContext =
 GetWindowDC(myWindowHandle);
 GetWindowRect(myWindowHandle, (LPRECT)&myRect);
 for (again = 1; again <= flashCount; again++)
 {
 InvertRect(myDisplayContext, (LPRECT)&myRect);
 InvertRect(myDisplayContext, (LPRECT)&myRect);
 }
 ReleaseDC(myWindowHandle,myDisplayContext);
#endif  
 return(again);
}

/************************************************/
/* SampMem is an example of using memory        */
/* management to save a value from one          */
/* execution of a DLL to the next               */
/************************************************/
/*   =REGISTER(“SampDLLs”,”SampMem”,”JIJ”)      */
/*   Macintosh only.                            */
/************************************************/

#include “DLL.h”

typedef long * LongPtr;

#if applec
#include <Types.h>
#include <Memory.h>

#endif

#if THINK_C
pascal unsigned long main(short opcode, unsigned long u1);
 /* prototype */

pascal unsigned long main(opcode, u1)
short opcode;
unsigned long u1;

#elif applec
pascal unsigned long SampMem(short opcode, unsigned long u1)

#endif
{
 unsigned long tempLong;
 unsigned long result;

 switch (opcode) {
 case 0:
 result = (unsigned long)NewHandle(4);
 *((LongPtr)(*((Handle)result))) = u1;
 break;
 case 1:
 tempLong = *((LongPtr)(*((Handle)u1)));
 tempLong++;
 *((LongPtr)(*((Handle)u1))) = tempLong;
 result = tempLong;
 break;
 case 2:
 DisposHandle((Handle)u1);
 result = 0;
 break;
 default: 
 result = 0;
 break;
 }
 return ( result );
}

/************************************************/
#************************************************/
#*        MPW C 3.0 Sample DLL Makefile         */
#************************************************/

SampAAA.c.o ƒ SampAAA.c SampDLLs.make DLL.h
 C -b SampAAA.c

SampAAA ƒ SampAAA.c.o
 Link -c “XCEL” -t “XLLB” -sg SampAAA -rt CODE=1 
  -ra SampAAA=resPurgeable -m SAMPAAA 
  SampAAA.c.o -o SampDLLs

SampBBB.c.o ƒ SampBBB.c SampDLLs.make DLL.h
 C -b SampBBB.c

SampBBB ƒ SampBBB.c.o
 Link -c “XCEL” -t “XLLB” -sg SampBBB -rt CODE=2 
  -ra SampBBB=resPurgeable -m SAMPBBB 
  SampBBB.c.o -o SampDLLs

SampCC.c.o ƒ SampCC.c SampDLLs.make DLL.h
 C -b SampCC.c

SampCC ƒ SampCC.c.o
 Link -c “XCEL” -t “XLLB” -sg SampCC -rt CODE=3 
  -ra SampCC=resPurgeable -m SAMPCC 
  SampCC.c.o -o SampDLLs

SampDD.c.o ƒ SampDD.c SampDLLs.make DLL.h
 C -b SampDD.c

SampDD ƒ SampDD.c.o
 Link -c “XCEL” -t “XLLB” -sg SampDD -rt CODE=4 
  -ra SampDD=resPurgeable -m SAMPDD 
  SampDD.c.o -o SampDLLs

SampEIIE.c.o ƒ SampEIIE.c SampDLLs.make DLL.h
 C -b SampEIIE.c

SampEIIE ƒ SampEIIE.c.o
 Link -c “XCEL” -t “XLLB” -sg SampEIIE -rt CODE=5
  -ra SampEIIE=resPurgeable -m SAMPEIIE 
  SampEIIE.c.o -o SampDLLs

SampFHF.c.o ƒ SampFHF.c SampDLLs.make DLL.h
 C -b SampFHF.c

SampFHF ƒ SampFHF.c.o
 Link -c “XCEL” -t “XLLB” -sg SampFHF -rt CODE=6 
  -ra SampFHF=resPurgeable -m SAMPFHF 
  SampFHF.c.o -o SampDLLs

SampGHG.c.o ƒ SampGHG.c SampDLLs.make DLL.h
 C -b SampGHG.c

SampGHG ƒ SampGHG.c.o
 Link -c “XCEL” -t “XLLB” -sg SampGHG -rt CODE=7 
  -ra SampGHG=resPurgeable -m SAMPGHG 
  SampGHG.c.o -o SampDLLs

SampHHH.c.o ƒ SampHHH.c SampDLLs.make DLL.h
 C -b SampHHH.c

SampHHH ƒ SampHHH.c.o
 Link -c “XCEL” -t “XLLB” -sg SampHHH -rt CODE=8 
  -ra SampHHH=resPurgeable -m SAMPHHH 
  SampHHH.c.o -o SampDLLs

SampIII.c.o ƒ SampIII.c SampDLLs.make DLL.h
 C -b SampIII.c

SampIII ƒ SampIII.c.o
 Link -c “XCEL” -t “XLLB” -sg SampIII -rt CODE=9 
  -ra SampIII=resPurgeable -m SAMPIII 
  SampIII.c.o -o SampDLLs

SampJJ.c.o ƒ SampJJ.c SampDLLs.make DLL.h
 C -b SampJJ.c

SampJJ ƒ SampJJ.c.o
 Link -c “XCEL” -t “XLLB” -sg SampJJ -rt CODE=10 
  -ra SampJJ=resPurgeable -m SAMPJJ 
  SampJJ.c.o -o SampDLLs

SampKKK.c.o ƒ SampKKK.c SampDLLs.make DLL.h
 C -b SampKKK.c

SampKKK ƒ SampKKK.c.o
 Link -c “XCEL” -t “XLLB” -sg SampKKK -rt CODE=11
  -ra SampKKK=resPurgeable -m SAMPKKK 
  SampKKK.c.o -o SampDLLs

SampMem.c.o ƒ SampMem.c SampDLLs.make DLL.h
 C -b SampMem.c

SampMem ƒ SampMem.c.o
 Link -c “XCEL” -t “XLLB” -sg SampMem -rt CODE=12
  -ra SampMem=resPurgeable -m SAMPMEM 
  SampMem.c.o 
  {Libraries}Interface.o 
  -o SampDLLs

Flash.c.o ƒ Flash.c SampDLLs.make DLL.h
 C -b Flash.c

Flash ƒ Flash.c.o
 Link -c “XCEL” -t “XLLB” -sg Flash -rt CODE=13 
  -ra Flash=resPurgeable -m FLASH 
  Flash.c.o -o SampDLLs

SampDLLs ƒ 
  SampAAA SampBBB SampCC 
  SampDD SampEIIE SampFHF SampGHG 
  SampHHH SampIII SampJJ SampKKK 
  SampMem Flash 
  SampDLLs.make DLL.h

#************************************************#
#* Microsoft C 5.1 Definition file SAMPDLLS.DEF *#
#************************************************#

LIBRARY SampDLLs

DESCRIPTION ‘Sample DLLs, Copyright 1989 Vincent Parsons’

STUB    ‘WINSTUB.EXE’

CODE    MOVEABLE
DATA    FIXED SINGLE

HEAPSIZE  4096
STACKSIZE 0

EXPORTS

        SampAAA
        SampBBB
        SampCC
        SampDD
        SampEIIE
        SampFHF
        SampGHG
        SampHHH
        SampIII
        SampJJ
        SampKKK
        Flash

#************************************************#
#*    Microsoft C 5.1 Makefile  SAMPDLLS.MAK    *#
#************************************************#

SampDLLs.lib : SampDLLs.def SampDLLs.mak
 implib SampDLLs.lib SampDLLs.def

SampAAA.obj : SampAAA.c SampDLLs.mak
 cl -c /D THINK_C=0 /D applec=0 \
    -Gsw -Asnw SampAAA.c

SampBBB.obj : SampBBB.c SampDLLs.mak
 cl -c -Gsw -Asnw SampBBB.c

SampCC.obj : SampCC.c SampDLLs.mak
 cl -c -Gsw -Asnw SampCC.c

SampDD.obj : SampDD.c SampDLLs.mak
 cl -c -Gsw -Asnw SampDD.c

SampEIIE.obj : SampEIIE.c SampDLLs.mak
 cl -c -Gsw -Asnw SampEIIE.c

SampFHF.obj : SampFHF.c SampDLLs.mak
 cl -c -Gsw -Asnw SampFHF.c

SampGHG.obj : SampGHG.c SampDLLs.mak
 cl -c -Gsw -Asnw SampGHG.c

SampHHH.obj : SampHHH.c SampDLLs.mak
 cl -c -Gsw -Asnw SampHHH.c

SampIII.obj : SampIII.c SampDLLs.mak
 cl -c -Gsw -Asnw SampIII.c

SampJJ.obj : SampJJ.c SampDLLs.mak
 cl -c -Gsw -Asnw SampJJ.c

SampKKK.obj : SampKKK.c SampDLLs.mak
 cl -c -Gsw -Asnw SampKKK.c

Flash.obj : Flash.c SampDLLs.mak
 cl -c -Gsw -Asnw Flash.c

SampDLLs.exe : SampAAA.obj SampBBB.obj \
               SampCC.obj SampDD.obj \
               SampEIIE.obj SampFHF.obj \
               SampGHG.obj SampHHH.obj \
               SampIII.obj SampJJ.obj \
               SampKKK.obj Flash.obj \
               SampDLLs.lib
 lib Samp1.lib -+SampAAA.obj -+SampBBB.obj \
    -+SampCC.obj -+SampDD.obj -+SampEIIE.obj \
    -+SampFHF.obj -+SampGHG.obj;
 lib Samp2.lib -+SampHHH.obj -+SampIII.obj \
    -+SampJJ.obj -+SampKKK.obj;
 link4 /al:16 /NOE  Flash.obj, SampDLLs.exe,,\
    Samp1.lib Samp2.lib win87em swinlibc slibw,\
    SampDLLs.def

 
AAPL
$100.87
Apple Inc.
+0.34
MSFT
$44.96
Microsoft Corpora
-0.37
GOOG
$584.46
Google Inc.
-2.40

MacTech Search:
Community Search:

Software Updates via MacUpdate

Tidy Up 3.0.15.0 - Find duplicate files...
Tidy Up is a complete duplicate finder and disk-tidiness utility. With Tidy Up you can search for duplicate files and packages by the owner application, content, type, creator, extension, time... Read more
Parallels Desktop 10.0 - Run Windows app...
Parallels Desktop is simply the world's bestselling, top-rated, and most trusted solution for running Windows applications on your Mac. With Parallels Desktop for Mac, you can seamlessly run both... Read more
Apple Final Cut Pro X 10.1.3 - Professio...
Apple Final Cut Pro X is a professional video editing solution.Completely redesigned from the ground up, Final Cut Pro adds extraordinary speed, quality, and flexibility to every part of the post-... Read more
Apple Compressor 4.1.3 - Adds power and...
Compressor adds power and flexibility to Final Cut Pro X export. Customize output settings, work faster with distributed encoding, and tap into a comprehensive set of delivery features. Powerful... Read more
Chromium 36.0.1985.143 - Fast and stable...
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all Internet users to experience the web. FreeSMUG-Free OpenSource Mac User Group build is... Read more
Macgo Blu-ray Player 2.10.6.1691 - Blu-r...
Macgo Mac Blu-ray Player can bring you the most unforgettable Blu-ray experience on your Mac. Overview Macgo Mac Blu-ray Player can satisfy just about every need you could possibly have in a Blu-ray... Read more
Apple Motion 5.1.2 - Create and customiz...
Apple Motion is designed for video editors, Motion 5 lets you customize Final Cut Pro titles, transitions, and effects. Or create your own dazzling animations in 2D or 3D space, with real-time... Read more
A Better Finder Rename 9.39 - File, phot...
A Better Finder Rename is the most complete renaming solution available on the market today. That's why, since 1996, tens of thousands of hobbyists, professionals and businesses depend on A Better... Read more
PopChar X 6.6 - Floating window shows av...
PopChar X helps you get the most out of your font collection. With its crystal-clear interface, PopChar X provides a frustration-free way to access any font's special characters. Expanded... Read more
MacUpdate Desktop 6.0.2 - Install Mac ap...
MacUpdate Desktop 6 brings seamless 1-click installs and version updates to your Mac. With a free MacUpdate account and MacUpdate Desktop 6, Mac users can now install almost any Mac app on macupdate.... Read more

Latest Forum Discussions

See All

Cubic Castles Review
Cubic Castles Review By Rob Thomas on August 20th, 2014 Our Rating: :: CASTLE CRAFTINGiPad Only App - Designed for the iPad Some ridiculously frustrating camera issues aside, Cubic Castles is a pretty neat, voxel-based crafting... | Read more »
Space Colors – Tips, Tricks, Strategies,...
Hello Cadets: Want to know what we thought about this hectic space combat/roguelike? Check out our Space Colors review! Space Colors is a cool shooter/roguelike from Team Chaos. You travel from planet to planet across a huge galaxy and complete a... | Read more »
Tap Sports Baseball – Tips, Tricks, and...
Tap Sports Baseball is a pretty simple game to learn, but that doesn’t mean it’s an easy game to master, by any means. To start your batting career off well, we thought we’d give you the heads up on some handy tips and tricks. Hey Batter-Batter:... | Read more »
Tap Sports Baseball Review
Tap Sports Baseball Review By Jennifer Allen on August 20th, 2014 Our Rating: :: LET'S PLAY BALLUniversal App - Designed for iPhone and iPad Tap Sports Baseball is briefly fun but lacks some important features.   | Read more »
Earn to Die 2 Set to Drive in to the App...
Earn to Die 2 Set to Drive in to the App Store Later This Year Posted by Ellis Spice on August 20th, 2014 [ permalink ] Not Doppler has announced that Earn to Die 2, a sequel to their successful game | Read more »
Frontier Heroes Review
Frontier Heroes Review By Andrew Fisher on August 20th, 2014 Our Rating: :: BLAZES NO TRAILSUniversal App - Designed for iPhone and iPad Despite awesome visuals and great music, Frontier Heroes just doesn’t quite deliver enough fun... | Read more »
Echo Prime is Now on Sale for $0.99
Echo Prime is Now on Sale for $0.99 Posted by Jessica Fisher on August 20th, 2014 [ permalink ] Universal App - Designed for iPhone and iPad | Read more »
Star Realms Review
Star Realms Review By Andrew Fisher on August 20th, 2014 Our Rating: :: A STAR IS BORNUniversal App - Designed for iPhone and iPad Star Realms is an excellent adaptation of an outstanding deck-builder. With great visuals and an... | Read more »
This. Is. SPRINGFIELD! War comes to The...
This. Is. SPRINGFIELD! | Read more »
One Tap RPG Review
One Tap RPG Review By Campbell Bird on August 20th, 2014 Our Rating: :: DUNGEON SLIDERUniversal App - Designed for iPhone and iPad This casual arcade game introduces some very light rpg elements into its fantasy-themed pachinko... | Read more »

Price Scanner via MacPrices.net

Apple now offering certified refurbished 2014...
 The Apple Store is now offering Apple Certified Refurbished 2014 MacBook Airs for up to $180 off the cost of new models. An Apple one-year warranty is included with each MacBook, and shipping is... Read more
Best Buy’s College Student Deals: $100 off Ma...
Take an additional $100 off all MacBooks and iMacs, $50 off iPad Airs and iPad minis, at Best Buy Online with their College Students Deals Savings, valid through September 6th. Anyone with a valid .... Read more
MacBook Airs on sale for $100 off MSRP, free...
B&H Photo has three 2014 MacBook Airs on sale for $100 off MSRP. Shipping is free, and B&H charges NY sales tax only. They also include free copies of Parallels Desktop and LoJack for Laptops... Read more
Razer Taipan Mouse For Gamers And Non-Gamers...
If you’re a serious gamer on either Mac or Windows PCs, a serious gaming mouse is a necessity for first-tier performance. However, even if like me you’re not much of a gamer, there’s still a strong... Read more
15-inch 2.2GHz MacBook Pro on sale for $1899,...
Adorama has the new 15″ 2.2GHz Retina MacBook Pro on sale for $1899 including free shipping plus NY & NJ sales tax only. Their price is $100 off MSRP, and it’s the lowest price available for this... Read more
Mid-Size Tablet Shootout Posted: iPad mini wi...
I ‘m curious about how many iPads Apple is actually selling these days. It’s been widely rumored and anticipated that new models with A8 SoCs, 2 GB of RAM, 8 megapixel cameras, and fingerprint... Read more
The 15 Biggest iPad Air Problems And How To A...
What’s this? Fifteen “biggest” problems with the iPad Air? Does that mean there are a lot of smaller problems as well? Say it isn’t so! My old iPad 2 has manifested no hardware problems in three... Read more
TYLT Syncable-Duo, 2-in-1 USB Cable With Appl...
TYLT has introduced the Syncable-Duo, a universal cable solution for charging and syncing data to smartphones and tablets. The Syncable-Duo eliminates the need for multiple cables by incorporating... Read more
Save up to $140 off MSRP with Apple refurbish...
Apple is offering Certified Refurbished iPad Airs for up to $140 off MSRP. Apple’s one-year warranty is included with each model, and shipping is free. Stock tends to come and go with some of these... Read more
2.5GHz Mac mini on sale for $549, save $50
B&H Photo has the 2.5GHz Mac mini on sale for $549.99 including free shipping. That’s $50 off MSRP, and B&H will also include a free copy of Parallels Desktop software. NY sales tax only. Read more

Jobs Board

Senior Event Manager, *Apple* Retail Market...
…This senior level position is responsible for leading and imagining the Apple Retail Team's global event strategy. Delivering an overarching brand story; in-store, Read more
*Apple* Solutions Consultant - Apple (United...
**Job Summary** The ASC is an Apple employee who serves as an Apple brand ambassador and influencer in a Reseller's store. The ASC's role is to grow Apple Read more
Position Opening at *Apple* - Apple (United...
**Job Summary** Being a Business Manager at an Apple Store means you're the catalyst for businesses to discover and leverage the power, ease, and flexibility of Apple Read more
Position Opening at *Apple* - Apple (United...
**Job Summary** At the Apple Store, you connect business professionals and entrepreneurs with the tools they need in order to put Apple solutions to work in their Read more
Project Manager / Business Analyst, WW *Appl...
…a senior project manager / business analyst to work within our Worldwide Apple Fulfillment Operations and the Business Process Re-engineering team. This role will work Read more
All contents are Copyright 1984-2011 by Xplain Corporation. All rights reserved. Theme designed by Icreon.