Search Unity

  1. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice
  2. Unity is excited to announce that we will be collaborating with TheXPlace for a summer game jam from June 13 - June 19. Learn more.
    Dismiss Notice

Data will be removed if I rebuild app to Hololens.

Discussion in 'VR' started by StupidWizard, Mar 30, 2017.

  1. StupidWizard

    StupidWizard

    Joined:
    Mar 30, 2017
    Posts:
    4
    I saved my data by PlayerPrefs of Unity. But when I rebuild app to Hololens, this data was removed. WorldAnchor datas were also removed.

    I build app by Visual Studio 2015.
    when Build Debug, x86, to Device -> datas were removed.
    when Build Release, x86, to Device -> datas were still removed.

    so now, What should I do to fix it?
    Thank you!
     
  2. Unity_Wesley

    Unity_Wesley

    Unity Technologies

    Joined:
    Sep 17, 2015
    Posts:
    558
    When you deploy from Visual Studio you are installing a new version/ fresh build of the app, the old version gets removed during this process.
     
    StupidWizard likes this.
  3. StupidWizard

    StupidWizard

    Joined:
    Mar 30, 2017
    Posts:
    4
    thank you!
    So can we build app without Visual Studio?
    At Unity Build Setting, 'Build_and_Run_on', there are only Local Machine, Windows Phone (cannot build), Local Machine and Windows Phone (cannot build). If I select Local Machine, app will run on Hololens Emulator :(
     
  4. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,718
    Visual Studio has a setting on whether it should wipe all data. It's in project properties under "debugging", and is called something like "Uninstall application package on every deploy" or something like that.
     
    StupidWizard likes this.
  5. StupidWizard

    StupidWizard

    Joined:
    Mar 30, 2017
    Posts:
    4
    Thank you.
    On Debug Properties, I unchecked "Uninstall and then re-install my package...." .
    with target is Hololens Emulator, this bug was fixed.
    But with target is Device (real Hololens), when I deployed to Device, application was removed, then re-installed, and datas were deleted.
    I checked Device setting (for developers), but It has no build setting (or data setting) :(
     
  6. cschmaler

    cschmaler

    Joined:
    Sep 5, 2017
    Posts:
    2
    Is there anything new on this issue? I have been looking for a solution for this problem for a long time.