Alpha Video Training
Results 1 to 3 of 3

Thread: Connection Strings

  1. #1
    Member
    Real Name
    Antonio Alexander Castro
    Join Date
    May 2009
    Posts
    5

    Default Connection Strings

    Is there a function that I can use to change the connection string on runtime? Specifically, I'm referring to Active-Link tables.

    Thank you very much in advance.

  2. #2
    "Certified" Alphaholic
    Real Name
    David Kates
    Join Date
    Apr 2008
    Location
    Unionville, ON
    Posts
    7,764

    Default Re: Connection Strings

    Not that I've seen... so I created one. It's really simplistic... not sure if it's what you want but it will point you in the right direction. The attached database has one function and one form. The button on the form calls the function. You need to change the code in the button to your situation.

    I created this to change the database an Active-Link table is pointing to. An Active-Link connection string for an Access database has 4 main parts, one of which is the database file. This function lets you supply a new database file and then it writes the new connection string back out to the named connection - overwriting it. It's an AlphaDAO named connection.

    There's lots more that can be done... add the other parts of the connection string to the function...or create other functions to replace the other parts.

    This works with Access databases so other work needs to be done to talk to other back ends... but again... it's a start.

  3. #3
    Member
    Real Name
    Antonio Alexander Castro
    Join Date
    May 2009
    Posts
    5

    Default Re: Connection Strings

    Thank you David for the tip. It will help me a lot in my problem.

Similar Threads

  1. Changing Connection Strings during Runtime
    By audrummer15 in forum Alpha Five Version 9 - Desktop Applications
    Replies: 1
    Last Post: 08-04-2009, 01:13 AM
  2. Record_Add() Function and strings
    By jkletrovets in forum Alpha Five Version 9 - Desktop Applications
    Replies: 7
    Last Post: 12-16-2008, 11:16 AM
  3. Cannot Enter Certain Strings
    By Steve Andrews in forum Forum Usage
    Replies: 2
    Last Post: 09-27-2005, 11:44 AM
  4. Strings in A5 null terminated?
    By Marcel Kollenaar in forum Alpha Five Version 6
    Replies: 6
    Last Post: 07-26-2004, 12:48 PM
  5. Zero Length Strings?
    By Bill Walker in forum Alpha Five Version 5
    Replies: 18
    Last Post: 01-30-2004, 04:36 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •